Bueno Soy [sT]Alejo o [X]P_One Y Les Vengo A Mostrar Un Pequeño MiniPacks De
Zonas De DeathMatch Son Simples Pero Buenos x'D Los Comandos Son
/Dm
/Rocket
/Minigun
Y Para Salirse Es /Salir
Imagen
Bueno Esto Lo Cree Yo Por Si Queren Saber
Zonas De DeathMatch Son Simples Pero Buenos x'D Los Comandos Son
/Dm
/Rocket
/Minigun
Y Para Salirse Es /Salir
Imagen
Bueno Esto Lo Cree Yo Por Si Queren Saber
- Código:
/*=====By [X]P_OnE / [sT]Alejo=============
Por Favor No Robar Creditos
Se Tiene Que Valorar El Trabajo De Otro
====================================*/
#include <a_samp>
new MiniGame[MAX_PLAYERS];
new Tipo[MAX_PLAYERS];
//MiniGame Minigun
new Float:RandomMini1[][10] =
{
{2275.110107,1110.360351,71.003967},
{2304.612304,1074.463256,32.515625},
{2295.262695,1082.798828,36.916976},
{2285.368896,1043.723022,32.615329},
{2272.077148,1053.124145,37.011150},
{2261.958007,1064.224731,64.840797},
{2239.140625,1134.622070,49.198131},
{2228.292480,1112.952270,54.637405},
{2207.539062,1061.161132,73.770378}
};
//Rocket
new Float:RandomMini2[][10] =
{
{1147.3363,2748.4590,10.8231},
{1209.0524,2831.6311,10.8360},
{1326.3113,2824.9265,10.8203},
{1358.6270,2741.6196,10.8203}
};
//Dm
new Float:RandomMini3[][10] =
{
{1390.9579,2192.7092,11.0234},
{1304.3623,2106.4260,11.0156}
};
public OnPlayerCommandText(playerid, cmdtext[])
{
new cmd[256];
if(strcmp("/Salir", cmd, true) == 0)//para salirse
{
if(MiniGame[playerid] == 1)
{
SetPlayerVirtualWorld(playerid, 0);
ResetPlayerWeapons(playerid);
MiniGame[playerid] = 0;
GivePlayerWeapon(playerid, 24, 7000);
GivePlayerWeapon(playerid, 25, 7000);//les deje unas armas que al salir te den esas armas x'D
GivePlayerWeapon(playerid, 29, 7000);
GivePlayerWeapon(playerid, 31, 7000);
GivePlayerWeapon(playerid, 34, 7000);
GivePlayerWeapon(playerid, 4, 1);
GivePlayerWeapon(playerid, 9, 1);
}
return 1;
}
if(MiniGame[playerid] == 1) return GameTextForPlayer(playerid,"~r~ERROR ~n~ Usa ~y~/SALIR ~w~para salir del MiniJuego",3000,3);//Esto Les Saldra Al Poner Un comando x'D
if(strcmp("/Minigun", cmd, true) == 0)//x'DDDDDD
{
if(MiniGame[playerid] == 0)
{
new rand = random(sizeof(RandomMini1));
SetPlayerPos(playerid, RandomMini1[rand][0], RandomMini1[rand][1],RandomMini1[rand][2]);
MiniGame[playerid] = 1;
Tipo[playerid] = 1;
ResetPlayerWeapons(playerid);
SetVehicleVirtualWorld(playerid, 1);
GivePlayerWeapon(playerid, 38, 999999);
GameTextForPlayer(playerid, "~r~Minigun", 1500, 3);
}
return 1;
}
if(strcmp("/Rocket", cmd, true) == 0)
{
if(MiniGame[playerid] == 0)
{
new rand = random(sizeof(RandomMini2));
SetPlayerPos(playerid, RandomMini2[rand][0], RandomMini2[rand][1],RandomMini2[rand][2]);
MiniGame[playerid] = 1;
SetPlayerHealth(playerid,100.0);
Tipo[playerid] = 2;
ResetPlayerWeapons(playerid);
SetVehicleVirtualWorld(playerid, 2);
GivePlayerWeapon(playerid, 35, 999999);
GameTextForPlayer(playerid, "~r~Rocket", 1500, 3);
}
return 1;
}
if(strcmp("/Dm", cmd, true) == 0)
{
if(MiniGame[playerid] == 0)
{
GameTextForPlayer(playerid, "~r~Dm", 1500, 3);
new rand = random(sizeof(RandomMini3));
SetPlayerPos(playerid, RandomMini3[rand][0], RandomMini3[rand][1],RandomMini3[rand][2]);
MiniGame[playerid] = 1;
SetPlayerHealth(playerid,100.0);
Tipo[playerid] = 3;
SetVehicleVirtualWorld(playerid, 3);
ResetPlayerWeapons(playerid);
GivePlayerWeapon(playerid, 26, 999999);
}
return 1;
}
return 0;
}
public OnPlayerSpawn(playerid)
{
if(MiniGame[playerid] == 1)//Esto Seria Que Al Morir vuelvas al minijuego x'D
{
if(Tipo[playerid] == 1)
{
new rand = random(sizeof(RandomMini1));
SetPlayerPos(playerid, RandomMini1[rand][0], RandomMini1[rand][1],RandomMini1[rand][2]);
ResetPlayerWeapons(playerid);
GivePlayerWeapon(playerid, 38, 999999);
ResetPlayerWeapons(playerid);
}
else if(Tipo[playerid] == 2)
{
new rand = random(sizeof(RandomMini2));
SetPlayerPos(playerid, RandomMini2[rand][0], RandomMini2[rand][1],RandomMini2[rand][2]);
ResetPlayerWeapons(playerid);
GivePlayerWeapon(playerid, 35, 999999);
}
else if(Tipo[playerid] == 3)
{
new rand = random(sizeof(RandomMini3));
SetPlayerPos(playerid, RandomMini3[rand][0], RandomMini3[rand][1],RandomMini3[rand][2]);
ResetPlayerWeapons(playerid);
GivePlayerWeapon(playerid, 26, 999999);
}
return 1;
}
return 0;
}
Bueno Eso Es Todo Ojalas Les Haya Gustado Adios