Command
#1

Hi, I just made /givekeys command, but when I try it in-game it says unknown command. I can't find the problem, the code seems to be good.
Code (updated fixed one):
Код:
removed, i don't want to release the code :P
Reply
#2

Install crashdetect and post what it prints out in the console.

Also, the command isn't written correctly.
You're never setting targetid to something, which means it'll always be id 0.
Reply
#3

Okay, yes I fixed the targetid thing.
This is what crashdetect prints:

Код:
[07:30:26] [debug] AMX backtrace:
[07:30:26] [debug] #0 0005cbd0 in ?? (0, -1) from LSLRP.amx
[07:30:26] [debug] #1 0017b958 in public cmd_givekeys (0, 7269420) from LSLRP.amx
[07:30:26] [debug] #2 native CallLocalFunction () from samp03svr
[07:30:26] [debug] #3 00017ca8 in public OnPlayerCommandText (0, 7269380) from LSLRP.amx
Reply
#4

Crashdetect has reported more, hasn't it? The mistake is in Car_IsOwner function and Car_GetID returns -1.

To make it easier, debug info: https://github.com/Zeex/samp-plugin-...ith-debug-info
Reply
#5

Thank you, solved.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)