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
How To Make An Object Fly Once I Trigger It?
theDARKW0LF Offline
Member

Posts: 150
Threads: 17
Joined: Sep 2010
Reputation: 0
#16
RE: How To Make An Object Fly Once I Trigger It?

(09-18-2010, 12:40 AM)Alroc Wrote: For me it does not work at all. The debugMessage dont show up and the vase is not flying Sad

here is my script:

My prop is named "Vase_01" and my area is "AreaFly01"

OnStart{
AddEntityCollideCallback("Player", "AreaFly01", "CollideAreaFly01", true, 1);
}

void CollideAreaFly01(string &in asParent, string &in asChild, int alState)
{
AddDebugMessage("Test 1-2 1-2 Flying object and ... action", false);
AddPropImpulse("Vase_01", 100.0f, 3.0f, 100.0f, "world");
}

As far as I can see, your OnStart is not correctly labeled, it should look like:
void OnStart()
{
not
OnStart{

Also, this part below needs to be under void OnEnter() as shown in the second box below
void CollideAreaFly01(string &in asParent, string &in asChild, int alState)
{
AddDebugMessage("Test 1-2 1-2 Flying object and ... action", false);
AddPropImpulse("Vase_01", 100.0f, 3.0f, 100.0f, "world");
}
to
void OnEnter()
{
}

void CollideAreaFly01(string &in asParent, string &in asChild, int alState)
{
AddDebugMessage("Test 1-2 1-2 Flying object and ... action", false);
AddPropImpulse("Vase_01", 100.0f, 3.0f, 100.0f, "world");
}

Let me know if there's anything else that you need help with.

Check out my custom stories(1)(2)!
09-18-2010, 01:27 AM
Find


Messages In This Thread
RE: How To Make An Object Fly Once I Trigger It? - by theDARKW0LF - 09-18-2010, 01:27 AM



Users browsing this thread: 1 Guest(s)