13.06.2014, 14:04
(
Последний раз редактировалось VladimirMark; 13.06.2014 в 15:16.
)
Ok, so I got a gamemode from a friend and he wants me to help him with his server and gamemode but he has many warning/errors in the script and I want to help him with it, can you please help me fix them? Please.
Admin PWN:
Line 635:
Line 771-779:
Line 4123-4142:
Account PWN:
Line 969-1001:
Line 1492:
Line 1502-1514:
rp PWN:
Line 253-273:
Line 1466-1471:
Vehicles PWN:
Line 4075-4077:
Interiors PWN:
Line 255-278:
Jobs PWN:
Line 2190-2203:
That's all I need for now please I really need a fix
Код:
tkgaming\admin.pwn(635) : warning 213: tag mismatch tkgaming\admin.pwn(772) : warning 217: loose indentation tkgaming\admin.pwn(788) : warning 217: loose indentation tkgaming\admin.pwn(1759) : warning 217: loose indentation tkgaming\admin.pwn(2101) : warning 217: loose indentation tkgaming\admin.pwn(2686) : warning 216: nested comment tkgaming\admin.pwn(2852) : warning 217: loose indentation tkgaming\admin.pwn(4123) : warning 213: tag mismatch tkgaming\admin.pwn(4126) : warning 213: tag mismatch tkgaming\admin.pwn(4137) : warning 213: tag mismatch tkgaming\admin.pwn(4138) : warning 213: tag mismatch tkgaming\admin.pwn(4139) : warning 213: tag mismatch tkgaming\admin.pwn(4141) : warning 213: tag mismatch tkgaming\admin.pwn(5911) : warning 203: symbol is never used: "playerid" tkgaming\account.pwn(969) : warning 202: number of arguments does not match definition tkgaming\account.pwn(1503) : warning 217: loose indentation tkgaming\account.pwn(1492) : warning 204: symbol is assigned a value that is never used: "costlevel" tkgaming\rp.pwn(273) : warning 209: function "UpDateContactList" should return a value tkgaming\rp.pwn(1470) : warning 204: symbol is assigned a value that is never used: "isajail" tkgaming\vehicles.pwn(2524) : warning 217: loose indentation tkgaming\vehicles.pwn(2525) : warning 217: loose indentation tkgaming\vehicles.pwn(2575) : warning 217: loose indentation tkgaming\vehicles.pwn(2582) : warning 217: loose indentation tkgaming\vehicles.pwn(2583) : warning 217: loose indentation tkgaming\vehicles.pwn(3678) : warning 216: nested comment tkgaming\vehicles.pwn(4075) : warning 204: symbol is assigned a value that is never used: "driver" tkgaming\business.pwn(870) : warning 217: loose indentation tkgaming\business.pwn(2083) : warning 217: loose indentation tkgaming\business.pwn(2084) : warning 217: loose indentation tkgaming\business.pwn(2085) : warning 217: loose indentation tkgaming\business.pwn(2086) : warning 217: loose indentation tkgaming\business.pwn(2087) : warning 217: loose indentation tkgaming\business.pwn(2178) : warning 217: loose indentation tkgaming\interiors.pwn(278) : warning 209: function "interiorTryEnterExit" should return a value tkgaming\jobs.pwn(237) : warning 217: loose indentation tkgaming\jobs.pwn(440) : warning 217: loose indentation tkgaming\jobs.pwn(2161) : warning 217: loose indentation tkgaming\jobs.pwn(2190) : warning 219: local variable "vehicleid" shadows a variable at a preceding level tkgaming\factions\leo.pwn(484) : warning 204: symbol is assigned a value that is never used: "rank" tkgaming\factions\leo.pwn(483) : warning 204: symbol is assigned a value that is never used: "faction" tkgaming\factions\news.pwn(8) : warning 204: symbol is assigned a value that is never used: "fid" tkgaming\factions.pwn(178) : warning 219: local variable "query" shadows a variable at a preceding level tkgaming\factions.pwn(187) : warning 217: loose indentation tkgaming\mapping.pwn(386) : warning 217: loose indentation tkgaming\mapping.pwn(416) : warning 217: loose indentation tkgaming\mapping.pwn(417) : warning 217: loose indentation tkgaming\mapping.pwn(666) : warning 217: loose indentation tkgaming\mapping.pwn(1227) : warning 217: loose indentation tkgaming\mapping.pwn(1367) : warning 217: loose indentation tkgaming\mapping.pwn(2798) : warning 216: nested comment tkgaming\mapping.pwn(2801) : warning 217: loose indentation tkgaming\mapping.pwn(3166) : warning 216: nested comment tkgaming\mapping.pwn(3175) : warning 217: loose indentation tkgaming\mapping.pwn(3300) : warning 217: loose indentation tkgaming\mapping.pwn(3665) : warning 217: loose indentation tkgaming\mapping.pwn(4299) : warning 217: loose indentation tkgaming\mapping.pwn(4361) : warning 217: loose indentation tkgaming\mapping.pwn(4386) : warning 217: loose indentation tkgaming\mapping.pwn(4704) : warning 217: loose indentation tkgaming\mapping.pwn(7794) : warning 217: loose indentation tkgaming\mapping.pwn(7916) : warning 216: nested comment tkgaming\mapping.pwn(7917) : warning 217: loose indentation tkgaming\mapping.pwn(7950) : warning 216: nested comment tkgaming\forumsync.pwn(31) : warning 203: symbol is never used: "email" tkgaming\forumsync.pwn(31) : warning 203: symbol is never used: "pass" tkgaming\forumsync.pwn(31) : warning 203: symbol is never used: "username" tkgaming\forumsync.pwn(31) : warning 203: symbol is never used: "playerid" tkgaming\forumsync.pwn(38) : warning 203: symbol is never used: "pass" tkgaming\forumsync.pwn(38) : warning 203: symbol is never used: "playerid" tkgaming\forumsync.pwn(92) : warning 203: symbol is never used: "newusername" tkgaming\forumsync.pwn(92) : warning 203: symbol is never used: "oldusername" tkgaming\forumsync.pwn(92) : warning 203: symbol is never used: "playerid" tkgaming\sqlqueries.pwn(360) : warning 217: loose indentation tkgaming\sqlqueries.pwn(365) : warning 217: loose indentation tkgaming\sqlqueries.pwn(349) : warning 203: symbol is never used: "pagelimit" tkgaming\sqlqueries.pwn(349) : warning 203: symbol is never used: "page" tkgaming\sqlqueries.pwn(393) : warning 217: loose indentation tkgaming\sqlqueries.pwn(442) : warning 235: public function lacks forward declaration (symbol "OnSQLQueryAdmin") tkgaming\sqlqueries.pwn(471) : warning 202: number of arguments does not match definition tkgaming\sqlqueries.pwn(471) : warning 202: number of arguments does not match definition tkgaming\sqlqueries.pwn(492) : warning 235: public function lacks forward declaration (symbol "OnSQLQueryHelper") tkgaming\sqlqueries.pwn(521) : warning 202: number of arguments does not match definition tkgaming\sqlqueries.pwn(521) : warning 202: number of arguments does not match definition tkgaming\sqlqueries.pwn(573) : warning 202: number of arguments does not match definition tkgaming\sqlqueries.pwn(573) : warning 202: number of arguments does not match definition tkgaming\cartoys.pwn(96) : warning 217: loose indentation tkgaming\cartoys.pwn(100) : warning 203: symbol is never used: "inputtext" tkgaming\cartoys.pwn(409) : warning 203: symbol is never used: "CRY" tkgaming\cartoys.pwn(409) : warning 203: symbol is never used: "CRX" tkgaming\cheats.pwn(18) : warning 203: symbol is never used: "reason" tkgaming\cheats.pwn(61) : warning 203: symbol is never used: "inputtext" tkgaming\cheats.pwn(76) : warning 203: symbol is never used: "oldkeys" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1149) : warning 219: local variable "query" shadows a variable at a preceding level C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1240) : warning 217: loose indentation C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1247) : warning 217: loose indentation C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "EventOnPlayerDeath" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "IsEventAdmin" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "IsFlyCar" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "LookupPlayerIP" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "NumPlayerRentCars" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "RPTestLabels" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "SendMsgToRadioSnoopers" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "ShowAllNameTagsForPlayer" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "SyncWarns" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "authorizeWepDamage" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "canUseDrugCommand" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "damageSystemOnPlayerDeath" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "damageSystemOnPlayerTakeDamage" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "damageSystemOnPlayerUpdate" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "decideWepAssign" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "deleteRadioURLPVars" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "diseaseCheck" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "doBankSettlement" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "doDiseaseEffect" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "doWepDamage" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "dropPlayerFromBike" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "endRace" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "factorBulletPower" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "factorBulletSpeed" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "fpscamkeysOnPlayerKeyState" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "getBasketTeam" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "getCraftCooldownTime" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "getDrugCooldownTime" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "getMaxRoundsToHurt" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "getPlayerCustomRadioURL" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "getPlayerNumAjails" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "getPlayerRadioStreamingID" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "getVehicleReclaimPrice" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "hasOOCTag" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "infectNearbyPlayers" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "isBankInNegative" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "isPlayerOnGround" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "isRaceActive" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "isSwitchingChars" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "isValidShootingDistance" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "onSetCustomRadioURL" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "playerGetsDisease" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "revertWepDamageBeforeDamage" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "sendAreaSound" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "sendGunSoundToInteriors" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "sendTourettesMessage" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "setAttackerID" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "setPlayerCustomRadioURL" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "setPlayerHurt" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "truckjob" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "tryToApplyHurt" C:\Users\**********\Desktop\tk-gaming\gamemodes\tkgaming.pwn(1300) : warning 203: symbol is never used: "wobbleScreenForPlayer" Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 147 Warnings.
Line 635:
pawn Код:
{"DMV",1284.765991, -1583.946044, 13.546875,0,0},
pawn Код:
new msg[129];
if(help) {
SendClientMessage(playerid, X11_WHITE, "Hide you from admin list.");
return 1;
}
if(GetPVarInt(playerid, "AdminHidden") == 2)
{
DeletePVar(playerid, "AdminHidden");
format(msg, sizeof(msg), "%s is now unhide from admin list", GetPlayerNameEx(playerid, ENameType_AccountName));
ABroadcast(X11_ORANGE, msg, EAdminFlags_Scripter);
}
else
{
SetPVarInt(playerid, "AdminHidden", 2);
format(msg, sizeof(msg), "%s is now hide from admin list", GetPlayerNameEx(playerid, ENameType_AccountName));
ABroadcast(X11_ORANGE, msg, EAdminFlags_Scripter);
}
return 1;
}
pawn Код:
new EAdminlags:aflags = EAdminFlags:GetPVarInt(editingadmin, "AdminFlags");
new EAdminFlags:setterflags = EAdminFlags:GetPVarInt(playerid, "AdminFlags");
if(GetPVarInt(editingadmin, "AdminHidden") == 2 && ~setterflags & EAdminFlags_Scripter) {
aflags = EAdminFlags_None;
}
if(listitem < sizeof(AdminFlagDescription)) {
if(~setterflags & EAdminFlags_Scripter) {
if(~setterflags & AdminFlagDescription[listitem][EAFIFlag]) {
ShowAdminFlagsMenu(playerid, editingadmin);
SendClientMessage(playerid, X11_TOMATO_2, "You cannot elevate your privileges.");
return 1;
}
}
if(AdminFlagDescription[listitem][EAFIFlag] == EAdminFlags_None) {
aflags = EAdminFlags_None;
} else if(aflags & AdminFlagDescription[listitem][EAFIFlag]) {
aflags &= ~AdminFlagDescription[listitem][EAFIFlag];
} else {
aflags |= AdminFlagDescription[listitem][EAFIFlag];
}
Line 969-1001:
pawn Код:
new total;
GetPlayerIpEx(playerid, ip, sizeof(ip));
if((total = numPlayersOnIp(ip)) > 1) {
format(msg, sizeof(msg), "* AdmWarn: %s[%d] has logged in %d times from the same IP(%s).",GetPlayerNameEx(playerid, ENameType_CharName),playerid,total,ip);
ABroadcast(X11_YELLOW, msg, EAdminFlags_All);
}
pawn Код:
new costlevel = nxtlevel*levelcost;
pawn Код:
//new exp = GetPVarInt(playerid, "RespectPoints");
format(infostring, sizeof(infostring), "~g~LEVEL UP~n~~w~You Are Now Level %d", nxtlevel);
GameTextForPlayer(i, infostring, 5000, 1);
PlayerPlaySound(i, 1052, 0.0, 0.0, 0.0);
PlayerPlayMusic(i);
//GiveMoneyEx(playerid, -costlevel);
SetPVarInt(i, "Level", nxtlevel);
SetPlayerScore(i, nxtlevel);
exp -= expamount;
SetPVarInt(i, "RespectPoints", exp);
}
}
Line 253-273:
pawn Код:
public UpDateContactList(playerid)
{
new msg[2000];
new name[32];
if(GetPVarInt(playerid, "DeletingContact") != 1)
{
GetPVarString(playerid,"AddNamePhone", name,sizeof(name));
mysql_real_escape_string(name, name);
format(msg,sizeof(msg),"INSERT INTO `contactlist` SET `id` = %d,`name` = \"%s\",`number` = %d",GetPVarInt(playerid, "CharID"),name, GetPVarInt(playerid, "AddNumberPhone"));
mysql_function_query(g_mysql_handle, msg, true, "EmptyCallback", "");
DeletePVar(playerid, "AddNamePhone");
DeletePVar(playerid, "AddNumberPhone");
SendClientMessage(playerid, X11_WHITE, "Your contact is now saved on your phone book!");
return 1;
}
format(msg,sizeof(msg),"DELETE FROM `contactlist` WHERE `id` = %d AND `number` = %d",GetPVarInt(playerid, "CharID"), GetPVarInt(playerid, "DeletePhoneContact"));
mysql_function_query(g_mysql_handle, msg, true, "EmptyCallback", "");
DeletePVar(playerid, "DeletePhoneContact");
DeletePVar(playerid, "DeletingContact");
SendClientMessage(playerid, X11_WHITE, "Your contact is delete successfully!");
}
pawn Код:
new jailtime = GetPVarInt(targetid, "ReleaseTime");
new isajail;
if(jailtime == 0) {
jailtime = GetPVarInt(targetid, "AJailReleaseTime");
isajail = 1;
}
Line 4075-4077:
pawn Код:
if(GetSpeed(shamal) > 0.0) {
GivePlayerWeaponEx(playerid, 46, -1);
}
Line 255-278:
pawn Код:
for(new i=0;i<sizeof(Interiors);i++) {
if(Interiors[i][ESQLID] != 0) {
if(IsPlayerInRangeOfPoint(playerid, 3.0, Interiors[i][EEntranceInteriorX],Interiors[i][EEntranceInteriorY],Interiors[i][EEntranceInteriorZ])) {
if(Interiors[i][EInteriorFreeze]) {
showHelpText(playerid, "You are being frozen to wait for the objects to stream.");
TogglePlayerControllableEx(playerid, 0);
SetTimerEx("SetControllable",2500,false,"dd",playerid,1);
}
SetPlayerPos(playerid, Interiors[i][EInteriorX], Interiors[i][EInteriorY], Interiors[i][EInteriorZ]);
SetPlayerInterior(playerid, Interiors[i][EInteriorInt]);
SetPlayerVirtualWorld(playerid, Interiors[i][EInteriorVW]);
if(Interiors[i][EInteriorAngle] != 0.0){
SetPlayerFacingAngle(playerid, Interiors[i][EInteriorAngle]);
}
} else if(IsPlayerInRangeOfPoint(playerid, 3.0, Interiors[i][EInteriorX], Interiors[i][EInteriorY], Interiors[i][EInteriorZ])) {
if(GetPlayerVirtualWorld(playerid) == Interiors[i][EInteriorVW]) {
SetPlayerPos(playerid, Interiors[i][EEntranceInteriorX],Interiors[i][EEntranceInteriorY],Interiors[i][EEntranceInteriorZ]);
SetPlayerVirtualWorld(playerid, 0);
SetPlayerInterior(playerid, 0);
}
}
}
}
}
Line 2190-2203:
pawn Код:
new vehicleid = GetPlayerVehicleID(playerid);
if(!IsTrailerAttachedToVehicle(vehicleid))
{
SendClientMessage(playerid, X11_WHITE, "You don't have a Trailer attached to your Truck!");
return 1;
}
new Float:distance = GetPointDistance(SmugglerRoutes[r][EIRX], SmugglerRoutes[r][EIRY], SmugglerRoutes[r][EIRZ], SmugglerRoutes[o][EIRX], SmugglerRoutes[o][EIRY], SmugglerRoutes[o][EIRZ]);
new money = floatround(distance)*5;
money -= 1500;
SetPVarInt(playerid, "SmugglerDeliver", 0);
GiveMoneyEx(playerid, money);
format(query, sizeof(query), "* You earned $%d from this delievery!",money);
SendClientMessage(playerid, COLOR_LIGHTGREEN, query);
}