First off, since this is my first post, I would just like to say how amazing this engine is. I am looking to create a commercial game and have recently been glancing over 6-7 different game engines (including Leadwerks, Torque, C4, SHiVa, Unity, and Visual3D) and, even though I have only been messing around with this one for a little over a week, I have to say this is engine is by far the best! It is so incredibly easy to do incredibly difficult tasks using this engine. This is definitely the easiest and most advanced engine I have ever used (even compared with UDK which the editors are way too complex for my tastes). Congrats! It is very hard to believe there is only one developer.
Okay, now on with my question. I know you can get a certain waypoint using Game::World.getWaypoint() and I am currently using this method. The problem is that I need to be able to get multiple waypoints without knowing the full name. For instance, I am using waypoints to replicate ladders. I need to be able to call a function, such as Game::World.getWaypoints("Ladder*"), and be able to return the waypoints for Ladder01, Ladder02, Ladder03, etc.
I saw
this post which I thought was going to work, but, as far as I can tell, Game::Waypoints is only a cache of the previously loaded waypoint using Game::World.getWaypoint(). I currently have the following code, but Ladders only ever has a length of 1, even with 3 waypoints in the world (and even if I remove the if(Contains()) statement).
Code:
Memb<Game::Waypoint *> Ladders;
...
Game::Waypoints.lock();
REPA(Game::Waypoints) {
if (Contains(Game::Waypoints.lockedElm(i).file, S + "Ladder")) {
Ladders.add(&Game::Waypoints.lockedElm(i).data);
}
}
Game::Waypoints.unlock();
I have a few ideas of my own but I am not entirely sure how to implement them yet. Any suggestions?