SuperHuman Code - 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: SuperHuman Code (
/showthread.php?tid=439170)
SuperHuman Code -
pimentgabriel - 24.05.2013
Is there any code that gives a certain playerid more movement speed and a super jump, a punch that does more damage and a more resistent guy with double of the normal HP, for example? i tried those before but it just bugged the server and the playerid died. Maybe i was doing it wrong. Can anyone give me help on those?
Re: SuperHuman Code -
AIped - 24.05.2013
you could play a bit with this
https://sampwiki.blast.hk/wiki/SetPlayerVelocity
and put them under OnPlayerKeyStateChange.
Also superpunch can be done with the onplayertakedamage callback.
the playerid who hits the other player, should have a variable that says he has superpowers
Re: SuperHuman Code -
pimentgabriel - 24.05.2013
Well... this SetPlayerVelocity one just moves the playerid to a determined direction. It does not changes the movement speed. But nice idea on the super punch one, i will try it out. Thanks.
Re: SuperHuman Code -
AIped - 26.05.2013
with a little math you can use velocity for direction heres an example;
pawn Код:
if(GetPlayerState(playerid) == PLAYER_STATE_ONFOOT)
{
GetPlayerVelocity(playerid,xh,yh,zh);
SetPlayerVelocity(playerid,xh*1.2,yh*1.2,zh*1.2);
}