Оффтопвх себе прописать хочешь :D
Под OrangeBox Lua скрипты вроде не работают. Это только под 34 можно побаловаться.Можно lua скриптами побаловаться.
/* Plugin Template generated by Pawn Studio */
#include <sourcemod>
public Plugin:myinfo =
{
name = "sv_cheats",
author = "Impulse",
description = "sv_cheats for person",
version = "1.0",
url = ""
}
public OnPluginStart()
{
RegAdminCmd("setcheats", set, ADMFLAG_ROOT);
}
public Action:set(client, args)
{
ShowMenu(client);
}
ShowMenu(client)
{
new Handle:men = CreateMenu(Select);
SetMenuTitle(men, "");
for (new i = 1; i<= GetClientCount(true); i++)
{
decl String:name[30];
GetClientName(i, name, 30);
decl String:info[2];
IntToString(i, info, 3);
AddMenuItem(men, info, name);
}
DisplayMenu(men, client, 0);
}
public Select(Handle:menu, MenuAction:action, client, option)
{
if (action == MenuAction_Select)
{
decl String:i[3];
GetMenuItem(menu, option, i, 3);
new playerid = StringToInt(i);
new Handle:cvar = FindConVar("sv_cheats");
SendConVarValue(playerid, cvar, "1");
CloseHandle(menu);
}
}
Но ведь сервер его забанит?Пишешь setcheats и... (Команда для админов с рутом.)
C-подобный:/* Plugin Template generated by Pawn Studio */ #include <sourcemod> public Plugin:myinfo = { name = "sv_cheats", author = "Impulse", description = "sv_cheats for person", version = "1.0", url = "" } public OnPluginStart() { RegAdminCmd("setcheats", set, ADMFLAG_ROOT); } public Action:set(client, args) { ShowMenu(client); } ShowMenu(client) { new Handle:men = CreateMenu(Select); SetMenuTitle(men, ""); for (new i = 1; i<= GetClientCount(true); i++) { decl String:name[30]; GetClientName(i, name, 30); decl String:info[2]; IntToString(i, info, 3); AddMenuItem(men, info, name); } DisplayMenu(men, client, 0); } public Select(Handle:menu, MenuAction:action, client, option) { if (action == MenuAction_Select) { decl String:i[3]; GetMenuItem(menu, option, i, 3); new playerid = StringToInt(i); new Handle:cvar = FindConVar("sv_cheats"); SendConVarValue(playerid, cvar, "1"); CloseHandle(menu); } }
Но ведь сервер его забанит?
Тааак, надо бы иммунитет, по руту, к античиту залепить. :-D
Пишешь setcheats и... (Команда для админов с рутом.)
C-подобный:/* Plugin Template generated by Pawn Studio */ #include <sourcemod> public Plugin:myinfo = { name = "sv_cheats", author = "Impulse", description = "sv_cheats for person", version = "1.0", url = "" } public OnPluginStart() { RegAdminCmd("setcheats", set, ADMFLAG_ROOT); } public Action:set(client, args) { ShowMenu(client); } ShowMenu(client) { new Handle:men = CreateMenu(Select); SetMenuTitle(men, ""); for (new i = 1; i<= GetClientCount(true); i++) { decl String:name[30]; GetClientName(i, name, 30); decl String:info[2]; IntToString(i, info, 3); AddMenuItem(men, info, name); } DisplayMenu(men, client, 0); } public Select(Handle:menu, MenuAction:action, client, option) { if (action == MenuAction_Select) { decl String:i[3]; GetMenuItem(menu, option, i, 3); new playerid = StringToInt(i); new Handle:cvar = FindConVar("sv_cheats"); SendConVarValue(playerid, cvar, "1"); CloseHandle(menu); } }
] setcheats
Unknown command: setcheats
] setcheats EPacker2
Unknown command: setcheats
] rcon setcheats EPacker2
L 01/15/2013 - 17:49:44: [SM] Native "GetClientName" reported: Client 2 is not connected
L 01/15/2013 - 17:49:44: [SM] Displaying call stack trace for plugin "sv_cheats.smx":
L 01/15/2013 - 17:49:44: [SM] [0] Line 31, sv_cheats.sp::ShowMenu()
L 01/15/2013 - 17:49:44: [SM] [1] Line 21, sv_cheats.sp::set()
] rcon setcheats 666
L 01/15/2013 - 17:49:57: [SM] Native "GetClientName" reported: Client 2 is not connected
L 01/15/2013 - 17:49:57: [SM] Displaying call stack trace for plugin "sv_cheats.smx":
L 01/15/2013 - 17:49:57: [SM] [0] Line 31, sv_cheats.sp::ShowMenu()
L 01/15/2013 - 17:49:57: [SM] [1] Line 21, sv_cheats.sp::set()
public Action:set(client, args)
{
[COLOR="Red"]if (client > 0)[/COLOR] ShowMenu(client);
}
Как бэ...Попроб
C-подобный:public Action:set(client, args) { [COLOR=Red]if (client > 0)[/COLOR] ShowMenu(client); }
Переменная sv_cheats меняется на 1, но чит команды не работают :sad:Пишешь setcheats и... (Команда для админов с рутом.)
C-подобный:/* Plugin Template generated by Pawn Studio */ #include <sourcemod> public Plugin:myinfo = { name = "sv_cheats", author = "Impulse", description = "sv_cheats for person", version = "1.0", url = "" } public OnPluginStart() { RegAdminCmd("setcheats", set, ADMFLAG_ROOT); } public Action:set(client, args) { ShowMenu(client); } ShowMenu(client) { new Handle:men = CreateMenu(Select); SetMenuTitle(men, ""); for (new i = 1; i<= GetClientCount(true); i++) { decl String:name[30]; GetClientName(i, name, 30); decl String:info[2]; IntToString(i, info, 3); AddMenuItem(men, info, name); } DisplayMenu(men, client, 0); } public Select(Handle:menu, MenuAction:action, client, option) { if (action == MenuAction_Select) { decl String:i[3]; GetMenuItem(menu, option, i, 3); new playerid = StringToInt(i); new Handle:cvar = FindConVar("sv_cheats"); SendConVarValue(playerid, cvar, "1"); CloseHandle(menu); } }
#include <sourcemod>
public OnPluginStart()
{
RegAdminCmd("setcheats", set, ADMFLAG_ROOT);
}
public Action:set(client, args)
{
SendConVarValue(client, FindConVar("sv_cheats"), "1");
return Plugin_Handled;
}
Так исходников на него же нету...
ОффтопГде нашли?