Player gets rollbacked
#1

So when someone left my server they need to see the tutorial and register again? This is what i get when a player Disconneting.

Код:
[19:13:04] [debug] Run time error 4: "Array index out of bounds"
[19:13:04] [debug]  Accessing element at negative index -1
[19:13:04] [debug] AMX backtrace:
[19:13:04] [debug] #0 0005bf84 in public Itter_OnPlayerDisconnect () from myscript.amx
[19:13:04] [debug] #1 native CallLocalFunction () [00471e90] from samp-server.exe
[19:13:04] [debug] #2 00008378 in public SSCANF_OnPlayerDisconnect () from myscript.amx
[19:13:04] [debug] #3 native CallLocalFunction () [00471e90] from samp-server.exe
[19:13:04] [debug] #4 000017dc in public Streamer_OnPlayerDisconnect () from myscript.amx
[19:13:04] [debug] #5 native CallLocalFunction () [00471e90] from samp-server.exe
[19:13:04] [debug] #6 00000cec in public OnPlayerDisconnect () from myscript.amx
Reply
#2

Arrays have as a valid index from 0 to (size of the array - 1). Somewhere in OnPlayerDisconnect, it passed -1 which is not a valid index.

Update crashdetect to the version 4.12 (if the version you use is not the latest one): https://github.com/Zeex/samp-plugin-...ases/tag/v4.12
And re-compile your scripts with debug info (-d3): https://github.com/Zeex/samp-plugin-...ith-debug-info

Start the server, connect and disconnect. Post what it printed.
Reply
#3

Код:
[19:41:28] Kevin DeSantos has logged in.
[19:41:36] [debug] Run time error 4: "Array index out of bounds"
[19:41:36] [debug]  Accessing element at negative index -1
[19:41:36] [debug] AMX backtrace:
[19:41:36] [debug] #0 0005bf84 in public Itter_OnPlayerDisconnect (0x00000000, 0x00000001) from myscript.amx
[19:41:36] [debug] #1 native CallLocalFunction () [00471e90] from samp-server.exe
[19:41:36] [debug] #2 00008378 in public SSCANF_OnPlayerDisconnect (0x00000000, 0x00000001) from myscript.amx
[19:41:36] [debug] #3 native CallLocalFunction () [00471e90] from samp-server.exe
[19:41:36] [debug] #4 000017dc in public Streamer_OnPlayerDisconnect (0x00000000, 0x00000001) from myscript.amx
[19:41:36] [debug] #5 native CallLocalFunction () [00471e90] from samp-server.exe
[19:41:36] [debug] #6 00000cec in public OnPlayerDisconnect (0x00000000, 0x00000001) from myscript.amx
[19:41:36] [part] Kevin_DeSantos has left the server (0:1)
Reply
#4

Are you sure that you've created the correct file pawn.cfg into pawno folder? Most of the times, it prints the lines caused it.

Post OnPlayerDisconnect callback.
Reply
#5

Now this happend when i started the server.
Код:
[19:52:13] [debug] Server crashed due to an unknown error
[19:52:14] [debug] Native backtrace:
[19:52:14] [debug] #0 5eca8cb0 in ?? () from C:\Users\Kevin\Desktop\new ngrp\plugins\crashdetect.DLL
[19:52:14] [debug] #1 5ec866e4 in ?? () from C:\Users\Kevin\Desktop\new ngrp\plugins\crashdetect.DLL
[19:52:14] [debug] #2 5eca0b09 in ?? () from C:\Users\Kevin\Desktop\new ngrp\plugins\crashdetect.DLL
[19:52:14] [debug] #3 5eca612f in ?? () from C:\Users\Kevin\Desktop\new ngrp\plugins\crashdetect.DLL
[19:52:14] [debug] #4 00469095 in ?? () from C:\Users\Kevin\Desktop\new ngrp\samp-server.exe
[19:52:14] [debug] #5 65646f6d in ?? () from C:\Users\Kevin\Desktop\new ngrp\samp-server.exe
[19:52:14] [debug] #6 6e692f73 in ?? () from C:\Users\Kevin\Desktop\new ngrp\samp-server.exe
[19:52:14] [debug] #7 696e6173 in ?? () from C:\Users\Kevin\Desktop\new ngrp\samp-server.exe
[19:52:14] [debug] #8 70727974 in ?? () from C:\Users\Kevin\Desktop\new ngrp\samp-server.exe
[19:52:14] [debug] #9 6d612e33 in ?? () from C:\Users\Kevin\Desktop\new ngrp\samp-server.exe
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)