Report tokens bug
#1

I have the issues with the accept report command, when i typed cmd /ar the server crashed. What should i do to fix this issues? im using NGRP script sorry im newbie im use this script only for learn scripting.
Reply
#2

give the command code.

OFFT: Don't use NGRP.
Reply
#3

If you want to learn scripting, then please don't use a script like that, use a simple gamemode (not roleplay).
And start editing it.
Reply
#4

Quote:
Originally Posted by Romel
Посмотреть сообщение
give the command code.

OFFT: Don't use NGRP.
I use this only learn for scripting man, can you help me to fix it?
Reply
#5

Quote:
Originally Posted by Jassey
Посмотреть сообщение
I use this only learn for scripting man, can you help me to fix it?
No, we can't until you give us a code of this command.
Reply
#6

No one can help you without see that isuus you sould post it.
Use
Код:
 [pawn][/ pawn]
. Remove the space after /.
Reply
#7

Quote:
Originally Posted by Riddick94
Посмотреть сообщение
No, we can't until you give us a code of this command.
This is the code
Код:
CMD:ar(playerid, params[])
{
	if(PlayerInfo[playerid][pAdmin] >= 2)
	{
		new string[128], reportid;
		if(sscanf(params, "d", reportid)) return SendClientMessageEx(playerid, COLOR_WHITE, "Gunakan: /ar [reportid]");

		if(reportid < 0 || reportid > 999) { SendClientMessageEx(playerid, COLOR_GREY, "   Report ID tidak dapat kurang dari 0 juga tidak dapat lebih dari 999!"); return 1; }
		if(Reports[reportid][BeingUsed] == 0)
		{
			SendClientMessageEx(playerid, COLOR_GREY, "   ID Report itu tidak digunakan, atau ID Report itu telah diterima/tolak oleh admin lain!");
			return 1;
		}
		if(!IsPlayerConnected(Reports[reportid][ReportFrom]))
		{
			SendClientMessageEx(playerid, COLOR_GREY, "   Pengirim report telah tidak ada!");
			Reports[reportid][ReportFrom] = 999;
			Reports[reportid][BeingUsed] = 0;
			return 1;
		}
		format(string, sizeof(string), "[REPORT] %s telah menerima report dari %s (ID: %i, RID: %i).", GetPlayerNameEx(playerid), GetPlayerNameEx(Reports[reportid][ReportFrom]),Reports[reportid][ReportFrom],reportid);
		ABroadCast(COLOR_ORANGE, string, 2);
		AddReportToken(playerid); // Report Tokens
		format(string, sizeof(string), "Report yang kamu kirim telah diterima oleh %s, harap tunggu jangan lakukan report lagi.", GetPlayerNameEx(playerid));
		SendClientMessageEx(Reports[reportid][ReportFrom], COLOR_WHITE, string);
		PlayerInfo[playerid][pAcceptReport]++;
		Reports[reportid][ReportFrom] = 999;
		Reports[reportid][ReplyTimerr] = SetTimerEx("ReplyTimer", 30000, 0, "d", reportid);
		Reports[reportid][CheckingReport] = playerid;
		Reports[reportid][BeingUsed] = 0;
		Reports[reportid][TimeToExpire] = 0;
		strmid(Reports[reportid][Report], "None", 0, 4, 4);
	}
	return 1;
}
Reply
#8

comment out the "AddReportToken(playerid);".
I remember NGRP script having issues with tokens

by comment out i mean
pawn Код:
// AddReportToken(playerid);
PS:
using an old NGRP script like that will lead you and your server nowhere, the gamemode itself is a huge bug.
Reply
#9

Quote:
Originally Posted by CmZxC
Посмотреть сообщение
comment out the "AddReportToken(playerid);".
I remember NGRP script having issues with tokens

by comment out i mean
pawn Код:
// AddReportToken(playerid);
PS:
using an old NGRP script like that will lead you and your server nowhere, the gamemode itself is a huge bug.
But if i delete the "AddReportToken(playerid);" /reply cmd cannot working after admins accept the report, how can i fix it?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)