Author |
Message |
nubbles
Joined: Tue Dec 04, 2012 1:31 am Posts: 45
|
 Jetpack to Jump?
Hello, I'm attempting to make an actor with a jetpack that is possible to shoot off, and have explode. The problem I face as of yet is that my actor, when the jetpack is removed, is completely unable to even simply jump, and as such can't really get around any more. I was wondering if it would be possible to have a "jump" (jetpack) replace the normal one when the normal one is destroyed.
|
Tue Mar 12, 2013 2:00 am |
|
 |
Foa
Data Realms Elite
Joined: Wed Sep 05, 2007 4:14 am Posts: 3966 Location: Canadida
|
 Re: Jetpack to Jump?
YOu'd have to do some sort of magic involving Lua to get them to jump after that sort of ordeal.
|
Tue Mar 12, 2013 4:28 am |
|
 |
nubbles
Joined: Tue Dec 04, 2012 1:31 am Posts: 45
|
 Re: Jetpack to Jump?
That shouldn't be so hard, I just need to attach a script to the jetpack to find and then set the sharpness of the Actor wearing it, 1 sharpness for jetpack attached, 2 for not attached, and then attach a script to the actor to switch between the two... I just can't figure out specifics. Is it even possible to set jetpacks with Lua?
|
Thu Mar 14, 2013 4:14 am |
|
 |
CaveCricket48
Joined: Tue Jun 12, 2007 11:52 pm Posts: 13144 Location: Here
|
 Re: Jetpack to Jump?
Have a script on the actor that checks the actor's attached parts. If the jetpack is not found, make the actor do a jump via velocity change in the script whenever the jump key is pressed.
|
Thu Mar 14, 2013 5:18 am |
|
 |
nubbles
Joined: Tue Dec 04, 2012 1:31 am Posts: 45
|
 Re: Jetpack to Jump?
That would work, and on a completely unrelated note, is it also possible to check for the sharpness of an object, say the head, of an actor?
|
Fri Mar 22, 2013 7:02 am |
|
 |
CaveCricket48
Joined: Tue Jun 12, 2007 11:52 pm Posts: 13144 Location: Here
|
 Re: Jetpack to Jump?
Yes, it is. Just have the pointer to the actor and then the Sharpness variable.
thisIsAHead.Sharpness
|
Sun Mar 24, 2013 1:45 pm |
|
 |
|