[FilterScript] JakAdmin (RomAdmin) - Cool Features/Anti-Jetpack
#21

Topic updated! /setskin and /setallskin is not working because skins.txt is not included in the scriptfiles that i give to you. Sorry about that

Never will gonna happen.
Package updated. For all JakAdmin users download the new package and extract the scriptfiles of JakAdmin to your current one. Click Yes to all.

Link:

http://www.solidfiles.com/d/152570bdd8/
Reply
#22

Quote:
Originally Posted by Uberanwar
View Post
Suggestion:

/countdown cmd.

Event system (Hide \'n seek for example)

Vehicle Mod System (Admins can tune their car through admin menu/console.)

3D text label on admin\'s head (Server Staff) - This feature can be turned off/on

Auto Weather System - Can be turned on/off.

Admin Private Vehicles - (/apv [vehicle id] - Will spawn a vehicle with a 3D Text Label) - Admin\'s Vehicle .. Players can\'t steal


Cool idea and the last one idea the DAdmin by Dar[K]Lord has that.+rep for the ideas
Reply
#23

^
you mean the admin vehicle?
RomAdmin has that feature first i remove that in the v2.0.
Reply
#24

Romel this one looks good. You did a good work with this man.
Reply
#25

^^
Thank you men.
I\'ve finally fixed some big issues from the previous version.
Reply
#26

Your Scripts is very amazing ^_^ thx and

Ahh ... Im load sfunc

and use this

if(IsPlayerJAdminLvl(playerid, 1)) //if player is JAdmin lvl 1 or more than 1

{

//code

}

its not work for me T_T
Reply
#27

^^

Works fine for me.
Reply
#28

Can i pm u ? T_T
Reply
#29

JakAdmin updated to v2.1!!
Reply
#30

Good work bruh.... Nice FilterScript
Reply
#31

thanks..
Reply
#32

Nice one
Reply
#33

I\'ve reviewed your script and have some suggestions.


1.)

DisplayConfig()


This is a pretty ugly way to set this up recently I\'ve found that using the conditional operator "?" is actually really useful in these circumstances try modifying your code in this manner.

Code:
new Enable[7] = "Enable";
new Disable[8] = "Disable";

printf("AutoLogin: [ %s ] - ConnectMsgs: [ %s ]
ReadPMs: [ %s ] - ReadCmds: [ %s ]
AntiAd: [ %s ] - SpamTime: [ %i ]",
	sInfo[AutoLogin] ? Enable : Disable,
	sInfo[ConnectMsgs] ? Enable : Disable,
	sInfo[ReadPMs] ? Enable : Disable,
	sInfo[AntiAd] ? Enable : Disable,
	sInfo[SaveCash] ? Enable : Disable,
 	sInfo[SpamTime]);
That looks a lot cleaner and easier to update don\'t you think ?


2.) Get rid of DINI it\'s old and slow and really has no place anymore.

3.) Avoid using un-need returns this creates convoluted code which is difficult to read as a simple example look at this.

Code:
CMD:resetwarn(playerid, params[])
{
	new id, str[150];
	CL(playerid);
	if(pInfo[playerid][Admin] >= 5 || IsPlayerAdmin(playerid))
	{
	    if(sscanf(params, "u", id))
	    {
	        SendClientMessage(playerid, COLOR_RED, "USAGE: /resetwarn [playerid]");
	        SendClientMessage(playerid, COLOR_ORANGE, "Function: Resets specified player\'s warning!");
	    }
	    else
	    {
		    if(id == INVALID_PLAYER_ID) Error(playerid, 0);
		    else
		    {
				pInfo[id][Warn] = 0;
				format(str, sizeof(str), "You\'ve reset %s(ID:%d) warning", GetName(id), id);
				SendClientMessage(playerid, COLOR_YELLOW, str);
				format(str, sizeof(str), "Administrator %s(ID:%d) has reset your warning", GetName(playerid), playerid);
				SendClientMessage(id, COLOR_YELLOW, str);
			}
		}
	}
	else Error(playerid, 7);
	return 1;
}
That looks a lot better I think it has a nice clean easy to follow flow.


4.) If you look at this command
Code:
CMD:spam(playerid, params[])
You\'ll notice a series of elseif\'s this is kind of minor but if you have more than 5 elseif\'s your should use a switch if possible.


5.) Replace all your loops like this
Code:
for(new i = 0; i < MAX_PLAYERS; i++)
with foreach()


6.) OnDialogReponse() should use a switch(dialogid) then call seperate functions outside of the callback it\'s bad practice to let a function go on and on for thousands of lines ( Starts at 1582 goes to line 6568 ) not good.


7.) Condense your code if you do the step above it would eliminate the need for having a register dialog and register command that do the exact same thing with the exact same code when you update these in the current state you need to update both sections of code calling a common function will save a lot of time and maintain consistency.


Anyways those are the main things I\'m seeing it\'s no where near as ugly as J.L Admin but if you take the time to do some the optimizations I\'ve listed it will reduce your lines and make your script a lot easier to update.


5/10 not horrible but also not that great.
Reply
#34

C:\DOCUME~1\Marko\Desktop\MINI-M~1\pawno\include\mSelection.inc(192) : error 017: undefined symbol "TEXT_DRAW_FONT_MODEL_PREVIEW"

C:\DOCUME~1\Marko\Desktop\MINI-M~1\pawno\include\mSelection.inc(196) : error 017: undefined symbol "PlayerTextDrawSetPreviewModel"

C:\DOCUME~1\Marko\Desktop\MINI-M~1\pawno\include\mSelection.inc(197) : error 017: undefined symbol "PlayerTextDrawSetPreviewRot"

C:\DOCUME~1\Marko\Desktop\MINI-M~1\pawno\include\mSelection.inc(189) : warning 203: symbol is never used: "mZoom"

C:\DOCUME~1\Marko\Desktop\MINI-M~1\pawno\include\mSelection.inc(189) : warning 203: symbol is never used: "Zrot"

C:\DOCUME~1\Marko\Desktop\MINI-M~1\pawno\include\mSelection.inc(189) : warning 203: symbol is never used: "Yrot"

C:\DOCUME~1\Marko\Desktop\MINI-M~1\pawno\include\mSelection.inc(189) : warning 203: symbol is never used: "Xrot"

C:\DOCUME~1\Marko\Desktop\MINI-M~1\pawno\include\mSelection.inc(189) : warning 203: symbol is never used: "modelindex"

Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
Reply
#35

Nice admin system. Good job +REP
Reply
#36

Romel, /armourall and /healall is not working. I\'m not sure why..
Reply
#37

Quote:
Originally Posted by [uL]Pottus
View Post
I\'ve reviewed your script and have some suggestions.


1.)

DisplayConfig()


This is a pretty ugly way to set this up recently I\'ve found that using the conditional operator "?" is actually really useful in these circumstances try modifying your code in this manner.

Code:
new Enable[7] = "Enable";
new Disable[8] = "Disable";

printf("AutoLogin: [ %s ] - ConnectMsgs: [ %s ]
ReadPMs: [ %s ] - ReadCmds: [ %s ]
AntiAd: [ %s ] - SpamTime: [ %i ]",
	sInfo[AutoLogin] ? Enable : Disable,
	sInfo[ConnectMsgs] ? Enable : Disable,
	sInfo[ReadPMs] ? Enable : Disable,
	sInfo[AntiAd] ? Enable : Disable,
	sInfo[SaveCash] ? Enable : Disable,
 	sInfo[SpamTime]);
That looks a lot cleaner and easier to update don\'t you think ?


2.) Get rid of DINI it\'s old and slow and really has no place anymore.

3.) Avoid using un-need returns this creates convoluted code which is difficult to read as a simple example look at this.

Code:
CMD:resetwarn(playerid, params[])
{
	new id, str[150];
	CL(playerid);
	if(pInfo[playerid][Admin] >= 5 || IsPlayerAdmin(playerid))
	{
	    if(sscanf(params, "u", id))
	    {
	        SendClientMessage(playerid, COLOR_RED, "USAGE: /resetwarn [playerid]");
	        SendClientMessage(playerid, COLOR_ORANGE, "Function: Resets specified player\'s warning!");
	    }
	    else
	    {
		    if(id == INVALID_PLAYER_ID) Error(playerid, 0);
		    else
		    {
				pInfo[id][Warn] = 0;
				format(str, sizeof(str), "You\'ve reset %s(ID:%d) warning", GetName(id), id);
				SendClientMessage(playerid, COLOR_YELLOW, str);
				format(str, sizeof(str), "Administrator %s(ID:%d) has reset your warning", GetName(playerid), playerid);
				SendClientMessage(id, COLOR_YELLOW, str);
			}
		}
	}
	else Error(playerid, 7);
	return 1;
}
That looks a lot better I think it has a nice clean easy to follow flow.


4.) If you look at this command
Code:
CMD:spam(playerid, params[])
You\'ll notice a series of elseif\'s this is kind of minor but if you have more than 5 elseif\'s your should use a switch if possible.


5.) Replace all your loops like this
Code:
for(new i = 0; i < MAX_PLAYERS; i++)
with foreach()


6.) OnDialogReponse() should use a switch(dialogid) then call seperate functions outside of the callback it\'s bad practice to let a function go on and on for thousands of lines ( Starts at 1582 goes to line 6568 ) not good.


7.) Condense your code if you do the step above it would eliminate the need for having a register dialog and register command that do the exact same thing with the exact same code when you update these in the current state you need to update both sections of code calling a common function will save a lot of time and maintain consistency.


Anyways those are the main things I\'m seeing it\'s no where near as ugly as J.L Admin but if you take the time to do some the optimizations I\'ve listed it will reduce your lines and make your script a lot easier to update.


5/10 not horrible but also not that great.
well you see sir.

I\'ve used YINI in the previous version of JakAdmin which is RomAdmin v1.0.

After some problems occuring of all of the users who has it. I decided to convert it back for a while.

About the dialogresponse. It will take alot of time to make them OnDialogResponse. Tune System has alot of dialogids. For the looping. Yes i will try to make it foreach. For the 1.) and 2.) i\'m thinking about it..
Reply
#38

I do like it, so I\'m going to use it on my server.
Reply
#39

Nice one!
Reply
#40

LOL, this is so good. I like your /setskin and /setskin all. Nice, more updates dude )
Reply


Forum Jump:


Users browsing this thread: 12 Guest(s)