Befehl funktioniert nicht

Wichtiger Hinweis: Bitte ändert nicht manuell die Schriftfarbe auf schwarz sondern belasst es bei der Standardeinstellung. Somit tragt ihr dazu bei dass euer Text auch bei Verwendung unseren dunklen Forenstils noch lesbar ist!

Tipp: Ihr wollt längere Codeausschnitte oder Logfiles bereitstellen? Benutzt unseren eigenen PasteBin-Dienst Link
  • Hi,
    mein /warn Befehl funktioniert nicht und crasht meinen Server... Wenn ich ihn eingebe kriege ich die Nachricht im Chat aber dann schließt sich meine samp-server.exe.


    In der server_log:

    [19:59:03] [debug] Server crashed while executing 1hk.amx
    [19:59:03] [debug] AMX backtrace:
    [19:59:03] [debug] #0 00000000 in public cmd_warn ()
    [19:59:03] [debug] #1 native CallLocalFunction () from samp-server.exe
    [19:59:03] [debug] #2 00000000 in public OnPlayerCommandText ()
    [19:59:03] [debug] Native backtrace:
    [19:59:03] [debug] #0 0f87396e in ?? () from plugins\crashdetect.dll
    [19:59:03] [debug] #1 0f86a767 in ?? () from plugins\crashdetect.dll
    [19:59:03] [debug] #2 0f86d65a in ?? () from plugins\crashdetect.dll
    [19:59:03] [debug] #3 0f104509 in ?? () from plugins\streamer.dll
    [19:59:03] [debug] #4 004746be in ?? () from samp-server.exe
    [19:59:03] [debug] #5 004010b6 in ?? () from samp-server.exe
    [19:59:03] [debug] #6 0f86d60a in ?? () from plugins\crashdetect.dll
    [19:59:03] [debug] #7 0f874078 in ?? () from plugins\crashdetect.dll
    [19:59:03] [debug] #8 0f86a767 in ?? () from plugins\crashdetect.dll
    [19:59:03] [debug] #9 0f86d65a in ?? () from plugins\crashdetect.dll
    [19:59:03] [debug] #10 0f104509 in ?? () from plugins\streamer.dll
    [19:59:03] [debug] #11 0046dd10 in ?? () from samp-server.exe
    [19:59:03] [debug] #12 00452270 in ?? () from samp-server.exe
    [19:59:03] [debug] #13 770892e9 in ?? () from C:\WINDOWS\SYSTEM32\ntdll.dll
    [19:59:03] [debug] #14 0049eef9 in ?? () from samp-server.exe
    [19:59:03] [debug] #15 0045ad2a in ?? () from samp-server.exe
    [19:59:03] [debug] #16 0f8744c3 in ?? () from plugins\crashdetect.dll
    [19:59:03] [debug] #17 770ce5fc in ?? () from C:\WINDOWS\SYSTEM32\ntdll.dll
    [19:59:03] [debug] #18 743dadf9 in ?? () from C:\WINDOWS\System32\KERNELBASE.dll
    [19:59:03] [debug] #19 743dae16 in ?? () from C:\WINDOWS\System32\KERNELBASE.dll
    [19:59:03] [debug] Registers:
    [19:59:03] [debug] EAX: 00b9aa90 EBX: 00000000 ECX: 055f2ec8 EDX: 00000000
    [19:59:03] [debug] ESI: 027e2ce8 EDI: 055833b8 EBP: 00000000 ESP: 0019fdac
    [19:59:03] [debug] EIP: 743dae16 EFLAGS: 00010283
    [19:59:03] [debug] Stack:
    [19:59:03] [debug] ESP+00000000: 770ce91c 743e2c6a 00000000 743e2c7f
    [19:59:03] [debug] ESP+00000020: 00000024 00000001 00000000 00000000
    [19:59:03] [debug] ESP+00000040: 00000000 02339ec8 76e99850 0044ea22
    [19:59:03] [debug] ESP+00000060: ffffffff 0049104c 76e99850 02339ec8
    [19:59:03] [debug] ESP+00000080: 0048d4db 00000000 000023f0 0019ff80
    [19:59:03] [debug] ESP+000000a0: 00000539 000001ec 000036f4 02339ec8
    [19:59:03] [debug] ESP+000000c0: 004c401c 00247000 004ab4a0 0019fe68
    [19:59:03] [debug] ESP+000000e0: ffffffff 0049b4a1 0049b4b1 004ab4a0
    [19:59:03] [debug] ESP+00000100: 00000001 023315e8 02331650 00000094
    [19:59:03] [debug] ESP+00000120: 00000000 00000000 00000000 00000000
    [19:59:03] [debug] ESP+00000140: 00000000 00000000 00000000 00000000
    [19:59:03] [debug] ESP+00000160: 00000000 00000000 00000000 00000000
    [19:59:03] [debug] ESP+00000180: 00000000 00000000 00000000 00000000
    [19:59:03] [debug] ESP+000001a0: 0049cb3a 0049cb3a 00247000 00000000
    [19:59:03] [debug] ESP+000001c0: 0019eb94 0019ffcc 0049d208 004ba530
    [19:59:03] [debug] ESP+000001e0: 76e862a0 4b2b0b20 0019ffdc 770c0fd9
    [19:59:03] [debug] ESP+00000200: 00247000 00000000 00000000 00000000
    [19:59:03] [debug] ESP+00000220: 0019ffe4 770d67b0 3dc22108 00000000
    [19:59:03] [debug] ESP+00000240: 00000000 00000000 0049cb3a 00247000
    [19:59:03] [debug] ESP+00000260: 000032f8 000000dc 00000000 00000020
    [19:59:03] [debug] ESP+00000280: 00000034 0000017c 00000001 00000000
    [19:59:03] [debug] ESP+000002a0: 00000002 1a26ef4e 00000298 00000044
    [19:59:03] [debug] ESP+000002c0: 00000534 0000004a 00000580 00000336
    [19:59:03] [debug] ESP+000002e0: 000008ec 000002fa 00000000 32ceeacd
    [19:59:03] [debug] ESP+00000300: 00000000 38505fc8 00000f5c 0000005e
    [19:59:03] [debug] ESP+00000320: 00001314 00000056 0000136c 00000392
    [19:59:03] [debug] ESP+00000340: 00000001 0000017c 000015bc 00000001
    [19:59:03] [debug] ESP+00000360: 00000003 00001ed8 00000e8c 00000001
    [19:59:03] [debug] ESP+00000380: 00000005 00003078 00000098 00000002
    [19:59:03] [debug] ESP+000003a0: 00000007 000031dc 000000f0 00000001
    [19:59:03] [debug] ESP+000003c0: 0000000b 000032f4 00000004 00000001
    [19:59:03] [debug] ESP+000003e0: 00000001 00000006 0000008c 00000001
    [19:59:03] [debug] Loaded modules:
    [19:59:03] [debug] 00400000 - 00519000 samp-server.exe
    [19:59:03] [debug] 77060000 - 771e3000 ntdll.dll
    [19:59:03] [debug] 76e70000 - 76f50000 KERNEL32.DLL
    [19:59:03] [debug] 74310000 - 744b1000 KERNELBASE.dll
    [19:59:03] [debug] 754f0000 - 768c9000 SHELL32.dll
    [19:59:03] [debug] 74240000 - 742fe000 msvcrt.dll
    [19:59:03] [debug] 768d0000 - 76906000 cfgmgr32.dll
    [19:59:03] [debug] 73cd0000 - 7423e000 windows.storage.dll
    [19:59:03] [debug] 74e70000 - 75081000 combase.dll
    [19:59:03] [debug] 769e0000 - 76ac0000 ucrtbase.dll
    [19:59:03] [debug] 74a50000 - 74b11000 RPCRT4.dll
    [19:59:03] [debug] 73b20000 - 73b3e000 SspiCli.dll
    [19:59:03] [debug] 73b10000 - 73b1a000 CRYPTBASE.dll
    [19:59:03] [debug] 74960000 - 749ba000 bcryptPrimitives.dll
    [19:59:03] [debug] 76bb0000 - 76bf1000 sechost.dll
    [19:59:03] [debug] 749c0000 - 74a05000 powrprof.dll
    [19:59:03] [debug] 76c90000 - 76d07000 advapi32.dll
    [19:59:03] [debug] 75090000 - 750d6000 shlwapi.dll
    [19:59:03] [debug] 74a20000 - 74a4b000 GDI32.dll
    [19:59:03] [debug] 76d10000 - 76e6b000 gdi32full.dll
    [19:59:03] [debug] 73b70000 - 73ccf000 USER32.dll
    [19:59:03] [debug] 74b20000 - 74b35000 win32u.dll
    [19:59:03] [debug] 74300000 - 7430d000 kernel.appcore.dll
    [19:59:03] [debug] 74d40000 - 74dc8000 shcore.dll
    [19:59:03] [debug] 74a10000 - 74a1f000 profapi.dll
    [19:59:03] [debug] 73850000 - 73858000 WSOCK32.dll
    [19:59:03] [debug] 6fd40000 - 6fd64000 WINMM.dll
    [19:59:03] [debug] 76910000 - 76973000 WS2_32.dll
    [19:59:03] [debug] 6fb90000 - 6fbb3000 WINMMBASE.dll
    [19:59:03] [debug] 73b40000 - 73b65000 IMM32.DLL
    [19:59:03] [debug] 0f850000 - 0f8a0000 crashdetect.dll
    [19:59:03] [debug] 5b530000 - 5b599000 MSVCP100.dll
    [19:59:03] [debug] 5b5a0000 - 5b65f000 MSVCR100.dll
    [19:59:03] [debug] 10000000 - 1000f000 sscanf.dll
    [19:59:03] [debug] 0f390000 - 0f3a5000 VCRUNTIME140.dll
    [19:59:03] [debug] 022a0000 - 0230c000 teamspeak-connector.dll
    [19:59:03] [debug] 71200000 - 712ee000 MSVCR120.dll
    [19:59:03] [debug] 71420000 - 71491000 MSVCP120.dll
    [19:59:03] [debug] 0f100000 - 0f14c000 streamer.dll
    [19:59:03] [debug] 0f440000 - 0f4ad000 MSVCP140.dll
    [19:59:03] [debug] 6bfa0000 - 6bfee000 mswsock.dll
    [19:59:03] [debug] 6a400000 - 6a412000 napinsp.dll
    [19:59:03] [debug] 6a3e0000 - 6a3f6000 pnrpnsp.dll
    [19:59:03] [debug] 6a3c0000 - 6a3d4000 NLAapi.dll
    [19:59:03] [debug] 733e0000 - 7345c000 DNSAPI.dll
    [19:59:03] [debug] 76f50000 - 76f57000 NSI.dll
    [19:59:03] [debug] 736a0000 - 736cf000 IPHLPAPI.DLL
    [19:59:03] [debug] 6a3b0000 - 6a3bc000 winrnr.dll
    [19:59:03] [debug] 6bce0000 - 6bd29000 fwpuclnt.dll
    [19:59:03] [debug] 73030000 - 7304b000 bcrypt.dll
    [19:59:03] [debug] 6a460000 - 6a468000 rasadhlp.dll


    Mein /warn Befehl:

    CMD:warn(playerid,params[])
    {
    new target,reason,iString[128];
    if(Player[playerid][Level] < 1) return SendErrorMessage(playerid, "Du musst ein Supporter sein um diesen Befehl zu benutzen.");
    if(sscanf(params, "ds", target, reason)) return SendUsageMessage(playerid,"/warn [ID] [Grund]");

    Player[target][Warns]++;
    format(iString,sizeof(iString),"WARN: %s hat %s verwarnt. [Grund: %s] [%d/5 Verwarnungen]",GetName(playerid),GetName(target),reason,Player[target][Warns]);
    SendClientMessageToAll(COLOR_YELLOW, iString);
    format(iString,sizeof(iString),"WARN: Du wurdest von %s verwarnt! [Grund: %s] [%d/5 Verwarnungen]",GetName(playerid),reason,Player[target][Warns]);
    SendClientMessage(target,COLOR_RED,iString);
    format(iString,sizeof(iString),"%s hat %s verwarnt. (Grund: %s)",GetName(playerid),GetName(target),reason);
    WarnLog(iString);
    return 1;
    }

  • Das ist nicht ZCMD, sondern iZCMD..und wie man sieht, ist es instabil, was mich nicht wundert, wenn ich mal so über den Code schaue xD


    Benutz einfach den normalen ZCMD...xD

    ast2ufdyxkb1.png


    Leute, lernt scripten und versucht mal lieber etwas selber zu schreiben, als es aus einem GF zu kopieren. :S