hp/ap/speed/grav wont set
I am making my first actual plugin, but I a having a bit trouble with it.
What is wrong with this is that nothing of the stuff I want to set is being set. At firs I thought it was the way I picked the player index randomly, but the client_print is working. I do get the message "Health added", and my name changes as i want it to change. It has to be the natives, or the way I am using the natives which is wrong. The plugin isn't finished, so I do indeed know that my name wont change back. PHP Code:
Code:
Dropped [Super] [RD] Jelle from server |
Re: hp/ap/speed/grav wont set
IMO, that's a very inefficient way to set all that. I mean with the 'RandomNum' thing you have going on.
Try this stock I have sitting around. Code:
Other than that, check is_user_alive and it shouldn't give you run time 10. |
Re: hp/ap/speed/grav wont set
It may be an ineffective way of doing it, but shouldn't it work anyway? As it changes my name, it should be working.
I will try it now though. I also make an alive check. |
Re: hp/ap/speed/grav wont set
The alive check will definitely get rid of the run time error. It's happened to me before.
|
Re: hp/ap/speed/grav wont set
It did get rid of the error. But after using the stock you provided me nothing happens at all. My name doesn't change, nor do I get anything printed in my chat. And now there is no error at all.
EDIT: I removed the alive check again and now I get a new error. This is by using the stock you provided: Code:
L 01/13/2011 - 00:24:19: [FUN] Player out of range (0) |
Re: hp/ap/speed/grav wont set
You also have to check if if get_random_player() doesn't return 0.
If it does, there is no alive player. |
Re: hp/ap/speed/grav wont set
Quote:
ps. If you have been selected as super player twice you will have two tags. So you should reset old super players name before selecting new. |
Re: hp/ap/speed/grav wont set
Quote:
I do indeed know that it doesn't reset the name. I also wrote that in the start of the topic. Then it must be my server which wont work properly. Also strange that I get no errors or anything. |
Re: hp/ap/speed/grav wont set
Quote:
|
Re: hp/ap/speed/grav wont set
I don't think it matters, but why do you have ham included when you don't use it.
|
| All times are GMT -4. The time now is 01:56. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.