Facebook Twitter YouTube Frictional Games | Forum | Privacy Policy | Dev Blog | Dev Wiki | Support | Gametee


Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Request Checkpoints - asName? Please help. :]
LowKeeee Offline
Junior Member

Posts: 16
Threads: 4
Joined: Feb 2013
Reputation: 0
#1
Checkpoints - asName? Please help. :]

Hey guys, I'm having a really big problem with my checkpoints. It's something simple I am sure but I need to figure out what the asName... or internal name is. The part of the code in bold below is what I need to know how to name. I have tried putting in the start area name but to no avail, so I'm not really sure. I would greatly appreciate any help!

void CheckPoint (string& asName, string& asStartPos, string& asCallback, string& asDeathHintCat, string& asDeathHintEntry);

Thanks guys!
02-02-2013, 08:53 AM
Find
NaxEla Offline
Senior Member

Posts: 415
Threads: 5
Joined: Dec 2012
Reputation: 28
#2
RE: Checkpoints - asName? Please help. :]

asName is the internal name for the checkpoint. You can make it anything you want and it is stored in the asName variable in the callback:
PHP Code: (Select All)
void MyFunc(string &in asNameint alCount

For example, if you had two checkpoints calling the same function, one with the internal name "check01" and the other "check02", you could do something like this:
PHP Code: (Select All)
void CheckPointFunc(string &in asNameint alCount)
{
    if(
asName == "check01") {
        
// do stuff
    
}

    if(
asName == "check02") {
        
// do different stuff
    
}


In Ruins [WIP]
02-02-2013, 09:37 AM
Find
No Author Offline
Posting Freak

Posts: 962
Threads: 10
Joined: Jun 2012
Reputation: 13
#3
RE: Checkpoints - asName? Please help. :]

Um.. Isn't this thread suppose to be in development support section ?

[Image: the-cabin-in-the-woods-masked-people.jpg]
02-02-2013, 09:46 AM
Find
TheGreatCthulhu Offline
Member

Posts: 213
Threads: 10
Joined: Oct 2010
Reputation: 32
#4
RE: Checkpoints - asName? Please help. :]

Yeah - all callback parameters are passed in by the game when the appropriate event happens, so that you can make use of them, if you want - it's engine's way of providing you with additional information for the event. In the checkpoint callback function above asName identifies the checkpoint, while alCount tels you how many times the callback was called for that checkpoint (note that the count starts from 0).

(02-02-2013, 09:46 AM)No Author Wrote: Um.. Isn't this thread suppose to be in development support section ?
Yes it is, one of the moderators will probably move it.
(This post was last modified: 02-02-2013, 09:49 AM by TheGreatCthulhu.)
02-02-2013, 09:47 AM
Find
LowKeeee Offline
Junior Member

Posts: 16
Threads: 4
Joined: Feb 2013
Reputation: 0
#5
RE: Checkpoints - asName? Please help. :]

Awesome, thanks for the help. My problem is finally fixed after way too long. Sorry for posting in the wrong section, first post you see.

Thanks again!
02-02-2013, 10:19 AM
Find




Users browsing this thread: 2 Guest(s)