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

Author Topic: State Machine and Engine problem  (Read 9897 times)

0 Members and 1 Guest are viewing this topic.

The Terminator

  • Full Member
  • ***
  • Posts: 224
  • Windows and Mac C++ Developer
    • View Profile
Re: State Machine and Engine problem
« Reply #15 on: August 10, 2012, 09:03:12 pm »
Heres the full error, sorry about that:

"sf::Texture::loadFromFile(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, sf::Rect<int> const&)", referenced from:

ShockEngine::SplashScreenState::SplashScreenState(bool) in SplashScreenState.o

"sf::Window::create(sf::VideoMode, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, unsigned int, sf::ContextSettings const&)", referenced from: ShockEngine::GameEngine::GameEngine(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, unsigned int, unsigned int, unsigned int, bool) in Engine.o

That's all it gives me. And yes, the original examples work.
Current Projects:
Technoport

eXpl0it3r

  • SFML Team
  • Hero Member
  • *****
  • Posts: 11034
    • View Profile
    • development blog
    • Email
Re: State Machine and Engine problem
« Reply #16 on: August 10, 2012, 09:12:28 pm »
Wouldn't there be written somewhere too: Undefined symbols: [...] ld: symbol(s) not found ?

Anways I've no knowledge of XCode and as I've already stated you should call the clean function from the build section in the menu (so something like that) and someone also suggested a few things you'll have to keep in mind:

Quote
That has happened to me a lot of times. That error is caused when the compiler can't find a class or function. Besides the obvious reasons for that to happen, you should also do something like this:

On the left of the Xcode window go to the targets, and find your application. Open it. You should see a build phase named "Compile Sources". Make sure that your implementation file is included inside that build phase. If not, drag and drop it onto that build phase.

Also, make sure that you have all frameworks included and linked to your application! To make that sure, go into your application target again, and see the "Link Binary With Libraries" build phase. See if all necessary .framework files are in there. If not, add them using drag and drop.
Source: http://forums.macrumors.com/showthread.php?t=515369
Official FAQ: https://www.sfml-dev.org/faq.php
Official Discord Server: https://discord.gg/nr4X7Fh
——————————————————————
Dev Blog: https://duerrenberger.dev/blog/

The Terminator

  • Full Member
  • ***
  • Posts: 224
  • Windows and Mac C++ Developer
    • View Profile
Re: State Machine and Engine problem
« Reply #17 on: August 10, 2012, 10:49:37 pm »
I found out the problem. SFML 2 does not support Xcode's C++11 so, I will have to manually compile my code.
Current Projects:
Technoport

mateandmetal

  • Full Member
  • ***
  • Posts: 171
  • The bird is the word
    • View Profile
    • my blog
Re: State Machine and Engine problem
« Reply #18 on: August 14, 2012, 06:39:33 am »
I´m not taking this any further, just because I don´t have much free time

I don´t hate std::stack
I don´t think SFML has a bad design. In fact, I love the SFML interface


Sorry for the offense, Mr. "Great Programmer"
- Mate (beverage) addict
- Heavy metal addict _lml
- SFML 2 addict
- My first (and free) game: BichingISH!