help - create a adrenaline pickup
#1

Hello, i want to create adrenaline pill pickup.
but i want it to give the player adrenaline, how can i do this?
Reply
#2

Quote:
Originally Posted by tomsalmon
Посмотреть сообщение
Hello, i want to create adrenaline pill pickup.
but i want it to give the player adrenaline, how can i do this?
What do you mean by give the player adrenaline? Like health or armor?
Reply
#3

yes, but i don't need it to give health or armor.. i need it to give the player "walk fast".. 1241 this is the pickup id - adrenaline pill.. but when i create it the player can't take it.


PHP код:
CreatePickup(1241,1,x,y,z,0); 
Reply
#4

Quote:
Originally Posted by tomsalmon
Посмотреть сообщение
yes, but i don't need it to give health or armor.. i need it to give the player "walk fast".. 1241 this is the pickup id - adrenaline pill.. but when i create it the player can't take it.


PHP код:
CreatePickup(1241,1,x,y,z,0); 
Lol you just created the pickup, you didn't give it any function, to your question;
It's impossible to make a player walk fast by picking up the pill. It's only possible to give him stuff like weapons, pos, hp, armor etc etc etc...

If you want me to help ya further PM me and I'd love to create a pickup for ya which will be functional.
Reply
#5

I'm sure the thing you want can be found in Lethal's admin script, check it out.
Reply
#6

It is not impossible, I made that for drug "Speed", look at these sections GetPlayerVelocity and SetPlayerVelocity . Little help, in function OnPlayerUpdate you check is player on adrenaline, if so, than, getplayervelocity, and setplayervelocity + e.g 0.3, but you need to be careful, and check for max velocity and if it reached limit than dont setplayervelocity + 0.3, because if you run too fast player will die.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)