Give access to menu, Small problem :)
Hello there!
So I made a menu from which you can give any player some flags with just aiming at him and a text is shown but the small problem I have is when I aim at the air (not a player) and try to give these flags it says the server name and that the it must be alive to get these flags :D These are the things I check: PHP Code:
|
Re: Give access to menu, Small problem :)
Check if the targeted entity is a connected player.
|
Re: Give access to menu, Small problem :)
Well, is_user_connected(id) does that, doesn't it?
|
Re: Give access to menu, Small problem :)
You check "id" (yourself), not the targeted player, which is "player" in this case. Basically you only need is_user_connected(player) and the flag check. You can't possibly aim a dead player, so you don't need is_user_alive and there's definitely no need to check if you are connected.
|
Re: Give access to menu, Small problem :)
I corrected that error, but still the message is displayed.
Also I give access this way: PHP Code:
but when I give acces and the player doesnt reconnect and just stays in the server he has access for random time from 2 to 10 minutes and then it dissappears (the access). How can I make it only when he leaves the server to take his given access? EDIT: I tried removing the is user alive, and now It says that it gives ME access to the menu and I already got access at the same time |
Re: Give access to menu, Small problem :)
PHP Code:
|
Re: Give access to menu, Small problem :)
Why are you checking the flags 3 times?!
PHP Code:
|
Re: Give access to menu, Small problem :)
I don't really understand your error. Code does exactly what you tell it to, so the problem that it would print both messages is impossible. Unless you're sending the command twice.
I don't know of anything that would strip the flags unless you have conflicting plugins. Code:
|
Re: Give access to menu, Small problem :)
Quote:
|
| All times are GMT -4. The time now is 21:01. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.