27.04.2013, 19:37
Hola a todos, tengo unos warnings de hace mбs de 1 aсo y nosй como resolverlos jeje, son los siguientes (3):
Lineas: 4457, 4459, (cуdigo en general)
El otro warning linea (12118, es el rRace modificado :P):
Pero el cуdigo en general es este: 
Eso, espero que me ayuden xD... otra cosa, como Ђ#@|!? hago un spoiler? saludos
Код:
C:\Users\yessica\Desktop\Carpetas\WEAPON_SCROLL_MOD_2_0_BETA\Andromeda 2.0\filterscripts\ladmin.pwn(4457) : warning 225: unreachable code C:\Users\yessica\Desktop\Carpetas\WEAPON_SCROLL_MOD_2_0_BETA\Andromeda 2.0\filterscripts\ladmin.pwn(4459) : warning 209: function "dcmd_rango" should return a value C:\Users\yessica\Desktop\Carpetas\WEAPON_SCROLL_MOD_2_0_BETA\Andromeda 2.0\filterscripts\ladmin.pwn(12188) : warning 202: number of arguments does not match definition Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 3 Warnings.
Код:
dcmd_rango(playerid,params[]) {
#pragma unused params
if(PlayerInfo[playerid][Level] >= 1) {
if(RangoEnElChat[playerid] == 0) {
RangoEnElChat[playerid] = 1;
ShowPlayerDialog(playerid, 0, DIALOG_STYLE_MSGBOX, " {9933CC}|| HABLAR AUTOMБTICAMENTE ||", "{FFFFFF}Ahora cuando hables, se te agregarб tu rango, usa de nuevo el comando para desactivarlo!", "Cerrar", "");
return CMDMessageToAdmins(playerid,"RANGO");
} else {
RangoEnElChat[playerid] = 0;
} return CMDMessageToAdmins(playerid,"RANGO (OFF)");
ShowPlayerDialog(playerid, 0, DIALOG_STYLE_MSGBOX, " {9933CC}|| HABLAR AUTOMБTICAMENTE ||", "{FFFFFF}Ahora podrбs hablar como usuario normal!", "Cerrar", ""); // Esta 4457
} else return SendClientMessage(playerid,red,"{9933CC}[ADMINISTRACION]:{FFFFFF} No tienes suficiente nivel para usar este comando");
} // Esta 4459
Код:
StartRace(playerid);

Код:
function CountTillRace(playerid)
{
switch(CountAmount)
{
case 0:
{
ForEach(i, MAX_PLAYERS)
{
if(Joined[i] == false)
{
new
string[256]
;
format(string, sizeof(string), ">> El tiempo para ingresar a la carrera \"%s\" ha terminado", RaceName);
TextDrawHideForAll(EntrarCarrera);
TextDrawHideForAll(CuadroEntrarCarrera);
}
}
StartRace(playerid); // Esta 12188
}
case 5:
{
new string[256];
format(string, sizeof(string), "~w~La carrera ~g~~h~~h~%s ~w~comenzara en ~r~~h~%d segundos~w~, usa ~p~/entrarc ~w~para entrar", RaceName, CountAmount);
TextDrawSetString(EntrarCarrera,string);
TextDrawShowForAll(CuadroEntrarCarrera);
format(string, sizeof(string), "%d", CountAmount);
ForEach(i, MAX_PLAYERS)
{
if(Joined[i] == true)
{
GameTextForPlayer(i, string, 1000,6);
PlayerPlaySound(i, 1056, 0.0, 0.0, 0.0);
GetPlayerPos(i,PosCarrera[playerid][0],PosCarrera[playerid][1],PosCarrera[playerid][2]);
SetPlayerCameraLookAt(i, PosCarrera[i][0]+2, PosCarrera[i][1], PosCarrera[i][2]-1);
}
}
}
case 4:
{
new string[256];
format(string, sizeof(string), "~w~La carrera ~g~~h~~h~%s ~w~comenzara en ~r~~h~%d segundos~w~, usa ~p~/entrarc ~w~para entrar", RaceName, CountAmount);
TextDrawSetString(EntrarCarrera,string);
TextDrawShowForAll(CuadroEntrarCarrera);
format(string, sizeof(string), "%d", CountAmount);
ForEach(i, MAX_PLAYERS)
{
if(Joined[i] == true)
{
GameTextForPlayer(i, string, 1000,6);
PlayerPlaySound(i, 1056, 0.0, 0.0, 0.0);
GetPlayerPos(i,PosCarrera[playerid][0],PosCarrera[playerid][1],PosCarrera[playerid][2]);
SetPlayerCameraLookAt(i, PosCarrera[i][0]+4, PosCarrera[i][1], PosCarrera[i][2]-2);
//Camera(i, RaceVehCoords[0][0]+4, RaceVehCoords[0][1], RaceVehCoords[0][2]-2,RaceVehCoords[0][3], 20);
}
}
}
case 3:
{
new string[256];
format(string, sizeof(string), "~w~La carrera ~g~~h~~h~%s ~w~comenzara en ~r~~h~%d segundos~w~, usa ~p~/entrarc ~w~para entrar", RaceName, CountAmount);
TextDrawSetString(EntrarCarrera,string);
TextDrawShowForAll(CuadroEntrarCarrera);
format(string, sizeof(string), "%d", CountAmount);
ForEach(i, MAX_PLAYERS)
{
if(Joined[i] == true)
{
GameTextForPlayer(i, string, 1000,6);
PlayerPlaySound(i, 1056, 0.0, 0.0, 0.0);
GetPlayerPos(i,PosCarrera[playerid][0],PosCarrera[playerid][1],PosCarrera[playerid][2]);
SetPlayerCameraLookAt(i, PosCarrera[i][0]+6, PosCarrera[i][1], PosCarrera[i][2]-3);
//Camera(i, RaceVehCoords[0][0]+6, RaceVehCoords[0][1], RaceVehCoords[0][2]-3,RaceVehCoords[0][3], 20);
}
}
}
case 2:
{
new string[256];
format(string, sizeof(string), "~w~La carrera ~g~~h~~h~%s ~w~comenzara en ~r~~h~%d segundos~w~, usa ~p~/entrarc ~w~para entrar", RaceName, CountAmount);
TextDrawSetString(EntrarCarrera,string);
TextDrawShowForAll(CuadroEntrarCarrera);
format(string, sizeof(string), "%d", CountAmount);
ForEach(i, MAX_PLAYERS)
{
if(Joined[i] == true)
{
GameTextForPlayer(i, string, 1000,6);
PlayerPlaySound(i, 1056, 0.0, 0.0, 0.0);
GetPlayerPos(i,PosCarrera[playerid][0],PosCarrera[playerid][1],PosCarrera[playerid][2]);
SetPlayerCameraLookAt(i, PosCarrera[i][0]+8, PosCarrera[i][1], PosCarrera[i][2]-4);
//Camera(i, RaceVehCoords[0][0]+8, RaceVehCoords[0][1], RaceVehCoords[0][2]-4,RaceVehCoords[0][3], 20);
}
}
}
case 1:
{
new string[256];
format(string, sizeof(string), "~w~La carrera ~g~~h~~h~%s ~w~comenzara en ~r~~h~%d segundos~w~, usa ~p~/entrarc ~w~para entrar", RaceName, CountAmount);
TextDrawSetString(EntrarCarrera,string);
TextDrawShowForAll(CuadroEntrarCarrera);
format(string, sizeof(string), "%d", CountAmount);
ForEach(i, MAX_PLAYERS)
{
if(Joined[i] == true)
{
GameTextForPlayer(i, string, 1000,6);
PlayerPlaySound(i, 1056, 0.0, 0.0, 0.0);
GetPlayerPos(i,PosCarrera[playerid][0],PosCarrera[playerid][1],PosCarrera[playerid][2]);
SetPlayerCameraLookAt(i, PosCarrera[i][0]+10, PosCarrera[i][1], PosCarrera[i][2]-5);
//Camera(i, RaceVehCoords[0][0]+10, RaceVehCoords[0][1], RaceVehCoords[0][2]-5,RaceVehCoords[0][3], 20);
}
}
}
case 6..60:
{
new string[256];
format(string, sizeof(string), "~w~La carrera ~g~~h~~h~%s ~w~comenzara en ~r~~h~%d segundos~w~, usa ~p~/entrarc ~w~para entrar", RaceName, CountAmount);
TextDrawSetString(EntrarCarrera,string);
TextDrawShowForAll(EntrarCarrera);
TextDrawShowForAll(CuadroEntrarCarrera);
format(string, sizeof(string), "%d", CountAmount);
ForEach(i, MAX_PLAYERS)
{
if(Joined[i] == true)
{
GameTextForPlayer(i, string, 1000,6);
PlayerPlaySound(i, 1056, 0.0, 0.0, 0.0);
}
}
}
}
return CountAmount--;
}


