Identifying a player problem. -
Denying - 01.03.2013
When I use a command such as let's say /pm ( private message ) [playerid] [text] and try using the full name or just a random letter/word it sends the private message to me, even if my name is "Mark" and I use "g".
I have tried to ****** it, but I did not even know what to ******.
What may be the problem?
Thank you in advance.
Re: Identifying a player problem. -
[MG]Dimi - 01.03.2013
Post code
Re: Identifying a player problem. -
Denying - 01.03.2013
All of it? Alright.
Re: Identifying a player problem. -
Vince - 01.03.2013
Man, your code is a mess. How could anyone possibly debug this ...
Re: Identifying a player problem. -
Denying - 01.03.2013
I just started scripting a week ago. :/
Any advices on how to make it a bit more clear or anything like that?
Re: Identifying a player problem. -
Jstylezzz - 01.03.2013
If you post just the /pm command here, between pawn tags, we can see if it's a problem in the command, or maybe your sscanf being outdated.
EDIT: before posting the code, you might want to indent it properly using the tutorial in [MG]Dimi's link below my post.
This way it will be alot easier to find eventual problems
Re: Identifying a player problem. -
[MG]Dimi - 01.03.2013
https://sampforum.blast.hk/showthread.php?tid=251335
Re: Identifying a player problem. -
Denying - 01.03.2013
Alright, thank you for all the help.
You deserve a reputation point.
Re: Identifying a player problem. -
Denying - 01.03.2013
By the way, it is not the actual command.
It is the same in every command that requiers a player's name/ID.
It uses the ID perfectly, but when I try using a name, part of a name it just chooses a random player. I will update my gamemode and make it as readable as possible and make an other thread or just post a new link to the new one.
Thank you all.
Re: Identifying a player problem. -
Denying - 02.03.2013
I've made everything in the script alot more clear. ( which was a bit annoying 2000 lines :/ )
And now all I have to say is thank you and..
I still have the same problem.
Here's just the /pm part ( even though it happens with every command which requiers a player's ID )
http://pastebin.com/kxrNFPNx
The problem is when I put an ID ( e.g 1 ) it will work perfectly, but when I try using a player name ( e.g. Mario_Casso ) it will do as the command should do but for a random player. And not to "Mario_Casso"