Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - AlanGrid

Pages: [1]
1
Greate, Jonny!

Could you share how exactly include source file (main.cpp) correctly using ExporteTemplate, because I didn't find any option of it in Export Template Wizard?

This is my steps:

First of all, I created the solution SFMLTest:

1) File/New/Project/Visual C++/Win32ConsoleAplication/SFMLTest

Next:

2) SFMLTest/Add/NewItem/C++File(.cpp)/main.cpp

Next:
3)SFMLTest/Properties/Configuration Properties/C/C++/General/AdditionalIncludedeDerictories/$(SolutionDir)/SFML/include

Next:

4)SFMLTest/Properties/Configuration Properties/Linker/General/AdditionalLibraryDerictories/$(SolutionDir)/SFML/lib

Next:
5)SFMLTest/Properties/Configuration Properties/Linker/Input/AdditionalDependencies/

sfml-main-d.lib
sfml-graphics-d.lib
sfml-window-d.lib
sfml-system-d.lib
sfml-audio-d.lib
sfml-network-d.lib

Next:
6)The simple code in the main.cpp:

#include "SFML/Graphics.hpp"
#include <iostream>
using namespace std;

int main() {

sf::RenderWindow window(sf::VideoMode(800, 600), "SFML Game!");

sf::CircleShape circle(50);
circle.setFillColor(sf::Color::Yellow);




while (window.isOpen()) {
sf::Event event;
while (window.pollEvent(event)) {
switch (event.type) {
case sf::Event::Closed:
window.close();
break;
}
}

window.clear();
window.draw(circle);
window.display();
}
}

The final step to create a template:

7)File/ExportTemplate/ProjectTemplate/Template name/Finish


That's all my steps to create a template from my SFMLproject file.

After that, I wasn't able to open main.cpp file from SourceFiles folder, my guess for this problem is that Template Exporter  not include the source file correctly when  created the template.

Could you point to my misstep I'll really appreciate your help?

2
I do not agree!

Probably someone encountered the similar issues creating his own SFML template in VS 2015. So this stage will become right please at once if the solution will be found.

3

Yes. correct, all SFML templates I created in VS 2015 had the same issue, it didn't let me open the main.cpp file.

So I'm looking for the solution to this problem. If someone encountered the similar issues creating his own SFML template in VS 2015, please share the solution how to fix that.

4
I created an SFML template and encountered the issue to open main.cpp from the Source Files folder, I got the error message - "The document cannot be opened. It has been renamed, deleted or moved." The next attempt to build the other one gave me the same result. And even after upgrade  Version 14.25420.01 Update3 I wasn't capable create my own template, just because of this weird issue, which didn't allow me to open main.cpp.  I tried to delete .suo file, but it was useless because all my settings ('include' & 'lib') was wiped out.

So till now  I didn't get perfect SFML template without manual work.



I didn't find any useful and similar cases with web search, so, I hope someone will share the idea how to solve it


I'll be very grateful for any suggestion.

Pages: [1]
anything