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


Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Why is my custom story not working!?!?!?
Adrianis Offline
Senior Member

Posts: 620
Threads: 6
Joined: Feb 2012
Reputation: 27
#11
RE: Why is my custom story not working!?!?!?

See here...

AddEntityCollideCallback("Player", "PlayerCollide", "MonsterFunction", true, 1);
AddEntityCollideCallback("Player", "MonsterEnd", true, 1);

You've called 2 of the same function, but on the second one you've missed out one of the things that function requires, which is the call to another function.

AddEntityCollideCallback(string& asParentName, string& asChildName, string& asFunction, bool abDeleteOnCollide, int alStates);

asParentName - internal name of main object
asChildName - internal name of object that collides with main object (asterix (*) NOT supported!)
asFunction - function to call
abDeleteOnCollide - determines whether the callback after it was called
alStates - 1 = only enter, -1 = only leave, 0 = both

That third parameter on the list tells the function AddEntityCollideCallback which function to call. Your first call to that function used "MonsterFunction", so when the 'parent' and 'child' collide, MonsterFunction is called.

The reason it says 'no matching signature' is because its talking about the 'signature' of the function you are calling, AddEntityCollideCallback requires all 5 parameters to be given a value, you did it the first time but not the second. There is no AddEntityCollideCallback function that takes only 4 parameters, so there is no matching signature to that function
(This post was last modified: 12-03-2012, 03:25 AM by Adrianis.)
12-03-2012, 03:24 AM
Find


Messages In This Thread
RE: Why is my custom story not working!?!?!? - by Adrianis - 12-03-2012, 03:24 AM



Users browsing this thread: 4 Guest(s)