Data Realms Fan Forums http://45.55.195.193/ |
|
Some lua scripts. http://45.55.195.193/viewtopic.php?f=1&t=30662 |
Page 1 of 1 |
Author: | Dex98 [ Sun Mar 11, 2012 11:39 am ] |
Post subject: | Some lua scripts. |
This time i'm looking for two lua scripts. First is probaply a simple one. A Script that is attached to a bullet, and makes the bullet instantly kill the victim. (a.k.a. Insta-kill) The second one might be a bit more complicated. a Script that, when attached to a bullet, will make the victim slowly lose health overtime. (also known as poison) Edit: probaply should have posted in reguests... |
Author: | Pantera1993 [ Sun Mar 11, 2012 4:21 pm ] |
Post subject: | Re: Some lua scripts. |
For the first script, you could just look at the round for the Heavy Sniper Rifle the coalition uses. There's some lua in there as well as .ini code. And for the second script, isn't that what wounds do already? |
Author: | Dex98 [ Sun Mar 11, 2012 4:41 pm ] |
Post subject: | Re: Some lua scripts. |
Pantera1993 wrote: And for the second script, isn't that what wounds do already? Yes, but to cause a wound, you would need to deal damage to the victim. I'm looking for a way to `poison´ the victim without dealing any other kind of damage to him. and doesn't the Heavy Sniper lua only add the effects and spawn the particle? |
Author: | Miggles [ Sun Mar 11, 2012 5:57 pm ] |
Post subject: | Re: Some lua scripts. |
Take a look at the dart gun from Weegee's Citadel scene/mod. It slowly poisons its target, and I'm sure it can be tweaked to poison them faster or quicker. Make sure you get permission first, though. |
Author: | Dex98 [ Mon Mar 12, 2012 5:15 pm ] |
Post subject: | Re: Some lua scripts. |
Miggles wrote: Take a look at the dart gun from Weegee's Citadel scene/mod. It slowly poisons its target, and I'm sure it can be tweaked to poison them faster or quicker. Make sure you get permission first, though. It Didn't work. The darts just dissapeared when they hit an actor. No poison. Well, enough about that. I have been trying to learn lua, and i believe that in a few weeks, ill be able to fix it myself. Does anybody know the insta-kill lua script? |
Author: | Mehman [ Mon Mar 12, 2012 7:40 pm ] |
Post subject: | Re: Some lua scripts. |
Dex98 wrote: Does anybody know the insta-kill lua script? That should work, although I didn't test it: Code: function Update(self) local ray = SceneMan:CastMORay(self.Pos , self.Vel*1.25*TimerMan.DeltaTimeSecs*FrameMan.PPM , self.ID , 0, false , 0); if ray ~= 255 then local mo = MovableMan:GetMOFromID(ray); mo:GetRootParent:GibThis(); self.ToDelete = true; end end Tell me if you get any errors. |
Author: | Pantera1993 [ Wed Mar 14, 2012 2:24 am ] |
Post subject: | Re: Some lua scripts. |
Dex98 wrote: Pantera1993 wrote: ...and doesn't the Heavy Sniper lua only add the effects and spawn the particle? Well, I meant just looking at the mechanics of the round in general. It works by firing an emitter which shoots the "round" right after being created. It's a better way to create a powerful round than editing the parameters in the code for a regular round (prevents pushing the actor around caused by heavier rounds). |
Page 1 of 1 | All times are UTC [ DST ] |
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group http://www.phpbb.com/ |