Hi and Hello Guyz I am Back to VCMP i was gone for some work And i am back with usefull snipets
Evaluation system is like if u make any admin in your server then use /addadmin full name then admin name will add it will show that admin has how much kicks and bans you have to type /einfo admin full name if exist then its will show
admin name:
kicks:
bans:
then it will be easy for owner to promote admin or demote
Commands
/einfo, /addadmin, /removeadmin.
Just Add this on Functions.nut
function SetBan( player, amount )
{
QuerySQL(db, "UPDATE Evaluation SET Ban='" + amount.tointeger() + "' WHERE Name='" + player.Name + "'");
}
function GetBan( player )
{
local Ban = GetSQLColumnData( QuerySQL( db, "SELECT Ban FROM Evaluation WHERE Name='" + player.Name+"'" ), 0 );
if ( Ban ) return Ban;
else return 0;
}
function SetKick( player, amount )
{
QuerySQL(db, "UPDATE Evaluation SET Kick='" + amount.tointeger() + "' WHERE Name='" + player.Name + "'");
}
function GetKick( player )
{
local Kick = GetSQLColumnData( QuerySQL( db, "SELECT Kick FROM Evaluation WHERE Name='" + player.Name+"'" ), 0 );
if ( Kick ) return Kick;
else return 0;
}
Add this on CreateTables();
QuerySQL( db, "CREATE TABLE IF NOT EXISTS Evaluation ( Name VARCHAR(25), Ban INT(18),Kick INT(18))" );
Add these Commands on Commands.nut
else if ( cmd == "einfo" )
{
if ( !text ) Message( "Error - Syntax: " + cmd + " <FullNick> ");
local q = QuerySQL( db, "SELECT * FROM Evaluation WHERE Name='" + text + "' COLLATE NOCASE" );
if ( !GetSQLColumnData( q, 0 ) )Message( "Error "+text+" -is not An Admin ");
else
{
Message( "Evaluation of : " + GetSQLColumnData( q, 0 ) );
Message( "Evaluation:Bans : " + GetSQLColumnData( q, 1 ) );
Message( "Evaluation:Kicks : " + GetSQLColumnData( q, 2 ) );
}
}
else if ( cmd == "addadmin" )
{
if ( stats[ player.ID ].Logged == false ) MessagePlayer( "[Error] - You're Not login!", player );
else if ( !text ) MessagePlayer( "Syntax, / " + cmd + " <Name>", player );
else
{
ClientMessage( "Admin added.", player,255,255,0);
QuerySQL( db, "INSERT INTO Evaluation (Name, Ban, Kick) values ( '" + text + "', '0', '0' )");
}
}
else if ( cmd == "removeadmin" )
{
if ( stats[ player.ID ].Logged == false ) MessagePlayer( "[Error] - You're Not login!", player );
else if ( !text ) MessagePlayer( "Syntax, / " + cmd + " <Name>", player );
else
{
QuerySQL( db, "DELETE FROM Evalutation WHERE Name LIKE '%" + text + "%'" );
ClientMessage( "Admin deleted.", player,255,255,0);
}
}
Add this on Kick Function
SetKick(admin,GetKick(admin)+1);
Add this on Ban Function
SetBan(admin,GetBan(admin)+1);
Sorry for my disturbence last time on Forum
UPDATED
any player who is not admin can use this command.
Edit:
Nice work.
(only if this wasn't copy pasted from any place).
Quote from: Sk on Apr 01, 2015, 11:26 AMany player who is not admin can use this command.
There is no such function as player.IsAdmin in 0.4.
(like we used to have in 0.3, for rcon)So these permissions are left to be added by users.
Btw, the idea sounds good. If I would have a (more serious) server then I would use this idea. :)
Quote from: sseebbyy on Apr 01, 2015, 11:44 AMQuote from: Sk on Apr 01, 2015, 11:26 AMany player who is not admin can use this command.
There is no such function as player.IsAdmin in 0.4. (like we used to have in 0.3, for rcon)
So these permissions are left to be added by users.
ye i know that but he could have left some space for (// Your admin function here) etc. that would have help.
i didnt not add admin function because many servers has different function of level so they need to have a sense to add their own level function
Thnx Seby
Just another copy and paste of 0.3 VCCnR script(made by farisdon). Seriously can't you script something by yourself?
wth what are u saying i make it my self and i work on it for 1 week everyone is not like u soulshaker just giving money of hosting and become patner
Change wPrivMessage to MessagePlayer
Next Time Watch every line before posting this could occurs Error
Quote from: Sk on Apr 01, 2015, 11:26 AMany player who is not admin can use this command.
Edit:
Nice work.
(only if this wasn't copy pasted from any place).
Ok Beztone I will check
Crystal Thanks And its make by my self
Quote from: soulshaker on Apr 01, 2015, 01:02 PMJust another copy and paste of 0.3 VCCnR script(made by farisdon). Seriously can't you script something by yourself?
[OFF] umm, That script was not developed by Faris Don, As far as I know it was an edit of the original script by me and Flockshot but that's very old, Just for knowledge.
Quote from: Honey on Apr 07, 2015, 07:13 AMQuote from: soulshaker on Apr 01, 2015, 01:02 PMJust another copy and paste of 0.3 VCCnR script(made by farisdon). Seriously can't you script something by yourself?
[OFF] umm, That script was not developed by Faris Don, As far as I know it was an edit of the original script by me and Flockshot but that's very old, Just for knowledge.
I saw this system in vccnr of farisdon before so I mentioned his name. Actually my point is how he released this without giving any credits to the original scripter
Yeah, When I was a new VCMP scripter I used to do the same, people used to call me copy cat and completely ignore me, eventually I understood that copying things is not good, Some people copy scripts because they consider it much easier instead of making that themselves but there are no shortcuts in scripting, I prefer Finch to use his mind's creativity and make something good, If he encounters problems I'm sure I'll be able to help.
Quote from: Honey on Apr 07, 2015, 12:12 PMFinch to use his mind's creativity...
I never thought you are the optimistic type ;D
Well Honey Its Not Copy Paste as i know That the evaluation system that was make by FarisDonb was bugged and i didnt use his system i have proof that his system was bug coz he say me on call i have call him so soulshaker dont think badly because i also say to doom_killer that i work on it for 1 week so this is Proof that i make this or else what u think
Let's stop accusing each other, What I wrote was a suggestion for ur future
Lol Every One will laugh on it they think i am stupid + bull ****
Quote from: Finch on Apr 07, 2015, 02:11 PMWell Honey Its Not Copy Paste as i know That the evaluation system that was make by FarisDonb was bugged and i didnt use his system i have proof that his system was bug coz he say me on call i have call him so soulshaker dont think badly because i also say to doom_killer that i work on it for 1 week so this is Proof that i make this or else what u think
lol -_- my function that i made in VCCNR has been now even copied! just wow! amazing, and pasted even if you are copying my things kindly post my codes correctly,And guys for your information their was nothing that my function was bugged even he had gotted my server's copy of vccnr and he didn't even used it correctly my function was far better and was fixed,finch did you wanted to be ban on this forum? guys don't listen him nothing was happened like that he is totally a lier why i would give my
precious system to him(he is totally mad) to fix even i could do it my ownself?finch better to make another lie.In these 3-4 years i am able to do it my ownself i had learned more then you(
SO THATS BETTER TO GIVE CREDITS TO ME THEN TO HIM BECAUSE HE HAD COPIED MY WORK! That I DIDN'T TO WANTED SHARE! AND BY HIS OWN HE HAD COMMITTED MISTAKES )
.So now if the real scripter is here so their is no need to believe that he made this script actually him=lier for him.Sorry for this mass anyway nice reason to manipulate the situation lier.Yes Honey Vccnr was not made by me actually the credits goes to them who made that ; i am not a real owner of that but i moved it from 0.1 to 2.7 beta(After Taking) so many players say that i had made vccnr actually i had just updates this script so i have credits.
Locked.