SA-MP Forums Archive
[DUDA] Poderes (?) - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: Non-English (https://sampforum.blast.hk/forumdisplay.php?fid=9)
+--- Forum: Languages (https://sampforum.blast.hk/forumdisplay.php?fid=33)
+---- Forum: Español/Spanish (https://sampforum.blast.hk/forumdisplay.php?fid=29)
+---- Thread: [DUDA] Poderes (?) (/showthread.php?tid=635362)



[DUDA] Poderes (?) - Matyaas - 05.06.2017

Algъn cуdigo que juege con la gravedad nose que al recibir un golpe de "X" mutante lo mande a la mrd y le quite cierto porcentaje de vida?
El otro que necesito es aumentar la velocidad al correr xD gracias


Re: [DUDA] Poderes (?) - Toroi - 05.06.2017

Para lo del golpe puedes usar : https://sampwiki.blast.hk/wiki/SetPlayerVelocity

Para correr mбs rбpido igual, pero no sй como funciona ya que la velocidad al estar en el suelo se reinicia dependiendo de la acciуn que estйs haciendo por default del San Andreas.


Respuesta: [DUDA] Poderes (?) - Matyaas - 07.06.2017

Alguien puede ayudarme?


Re: [DUDA] Poderes (?) - Blackaslan - 07.06.2017

Код:
		GetPlayerFacingAngle(i, angle);
								angle+=180;
								sx = floatsin(-angle, degrees);
								sy = floatcos(-angle, degrees);
								SetPlayerVelocity(i, floatmul(0.7, sx), floatmul(0.7, sy), 0.8);
ese lo ocupo en mi servidor para hacer lo que quieres , es cosa de jugar con el setplayervelocity como mencionaban arriba y con esto:

https://sampwiki.blast.hk/wiki/SetPlayerFacingAngle

https://sampwiki.blast.hk/wiki/GetPlayerFacingAngle

https://sampwiki.blast.hk/wiki/Floatcos

https://sampwiki.blast.hk/wiki/Floatmul