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
AddPlayerBodyForce not work
Lake Offline
Member

Posts: 58
Threads: 20
Joined: Jul 2012
Reputation: 0
#1
AddPlayerBodyForce not work

this is the script:

void OnStart()
{
AddEntityCollideCallback("Player", "ScriptArea_1", "spinta", true, 1);
}

void spinta(string &in asParent, string &in asChild, int alState)
{
PlaySoundAtEntity("", "react_pant.snt", "spinta", 0, false);
AddPlayerBodyForce(2.26, 2.25, 9.5, false);
}

because it does not work?
(This post was last modified: 08-10-2012, 05:29 PM by Lake.)
08-10-2012, 10:39 AM
Find
The Shanus Offline
Member

Posts: 134
Threads: 15
Joined: Jun 2012
Reputation: 3
#2
RE: AddPlayerBodyForce not work

(08-10-2012, 10:39 AM)Lake Wrote: this is the script:

void OnStart()
{
AddEntityCollideCallback("Player", "ScriptArea_1", "spinta", true, 1);
}

void spinta(string &in asParent, string &in asChild, int alState)
{
PlaySoundAtEntity("", "react_pant.snt", "spinta", 0, false);
AddPlayerBodyForce(2.26f, 2.25f, 9.5f, false);
}

because it does not work?
Need to put "f"s on the numbers because they're floats, try that.

[Image: theshanusyoutube.jpg]
08-10-2012, 11:42 AM
Find
Lake Offline
Member

Posts: 58
Threads: 20
Joined: Jul 2012
Reputation: 0
#3
RE: AddPlayerBodyForce not work

I tryed but don't work.
08-10-2012, 12:12 PM
Find
The Shanus Offline
Member

Posts: 134
Threads: 15
Joined: Jun 2012
Reputation: 3
#4
RE: AddPlayerBodyForce not work

(08-10-2012, 12:12 PM)Lake Wrote: I tryed but don't work.
Maybe just increase the numbers :p I have a door explosion in one map and it knocks the player back 27000,0,0 and that's only like 5 metres

[Image: theshanusyoutube.jpg]
08-10-2012, 12:20 PM
Find
Lizard Offline
Member

Posts: 174
Threads: 23
Joined: Jul 2012
Reputation: 5
#5
RE: AddPlayerBodyForce not work

to move the player, you need at least 2000, to make a visible chance

CURRENT PROJECT:
A Fathers Secret == Just started
(This post was last modified: 08-10-2012, 12:51 PM by Lizard.)
08-10-2012, 12:49 PM
Find
Lake Offline
Member

Posts: 58
Threads: 20
Joined: Jul 2012
Reputation: 0
#6
RE: AddPlayerBodyForce not work

ok problem solved Wink
08-10-2012, 05:29 PM
Find




Users browsing this thread: 3 Guest(s)