SA-MP Forums Archive
Can this be done? - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Can this be done? (/showthread.php?tid=635137)



Can this be done? - Dragonic - 02.06.2017

At the moment I have a /Godmode command in my server. It tunrs g_God[playerid] to true and on a infinite loop that is called every .5s if g_God[playerid] == 1; it sets the player and vehicle hp to 10000.

Everything works perfectly, the player becomes imortal unless I go ram with an Airplane into a building/floor.

Is there a way to do a /Godmode command that even if I crash with a plane it wont explode and kill the player?


Re: Can this be done? - saffierr - 02.06.2017

You will always 'die' when crashing onto a building, it's GTA by default.
But, perhaps you could script to spawn the player immediately where he was before he died.


Re: Can this be done? - Dragonic - 02.06.2017

Quote:
Originally Posted by saffierr
Посмотреть сообщение
You will always 'die' when crashing onto a building, it's GTA by default.
But, perhaps you could script to spawn the player immediately where he was before he died.
Hm... Thats on GTA side, not SAMP...
Well guess I'll have to live with it.

Thanks anyway.


Re: Can this be done? - NaS - 02.06.2017

You can use a small object with collision, set its material to be invisible and attach it to the front of the plane. That way it can but not always will survive a crash to the front at high speed. Still RepairVehicle will be neccessary to remove the rotor smoke etc but it is way less likely to explode instantly.
It's not a solution but maybe a little workaround that could help.


Re: Can this be done? - CheezIt - 03.06.2017

There is definitely a way or more than one way to counter this issue, you just need to think out of the box and move your tush.