Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public TeamsStats(){
- if(Options[Language]==1)format(tstring,sizeof(tstring),"~b~Punti Difesa: %d~n~~r~Punti Nemico: %d",ArmyScore,EnemyScore);
- if(Options[Language]==2)format(tstring,sizeof(tstring),"~b~Defence Score: %d~n~~r~Enemy Score: %d",ArmyScore,EnemyScore);
- TextDrawSetString(ShipTextdraw1,tstring);
- return 1;}
- public EndRoundTimer(){
- if(RoundCountActive==1){
- if(EndRoundSeconds==0 && EndRoundMinutes==0){
- //if(PlayersCountShip>0){
- RoundTimer();
- EndRoundMinutes=0;
- EndRoundSeconds=0;}
- if(EndRoundSeconds==0){
- //if(PlayersCountShip>0){
- EndRoundMinutes--;
- EndRoundSeconds=60;
- if(Options[Language]==1)format(tstring3,sizeof(tstring3),"Tempo Fine Round: %d.%d",EndRoundMinutes,EndRoundSeconds);
- if(Options[Language]==2)format(tstring3,sizeof(tstring3),"Round Time Finish: %d.%d",EndRoundMinutes,EndRoundSeconds);
- TextDrawSetString(ShipTextdraw3,tstring3);}
- if(EndRoundSeconds>0){
- //if(PlayersCountShip>0){
- if(Options[Language]==1)format(tstring3,sizeof(tstring3),"Tempo Fine Round: %d.%d",EndRoundMinutes,EndRoundSeconds);
- if(Options[Language]==2)format(tstring3,sizeof(tstring3),"Round Time Finish: %d.%d",EndRoundMinutes,EndRoundSeconds);
- TextDrawSetString(ShipTextdraw3,tstring3);
- EndRoundSeconds--;}}
- return 1;}
- public RoundTimer(){
- SetTimer("RoundTimer2",4000,0);
- ShowShipCamera();
- for(new i=0;i<MAX_SERVER_PLAYERS;i++)if(IsPlayerConnected(i)){
- if(GetPlayerVirtualWorld(i)==SHIP__WORLD){
- TogglePlayerControllable(i,0);
- if(Options[Language]==1)GameTextForPlayer(i,"~w~La partita e' ~g~Finita!",3000,3);
- if(Options[Language]==2)GameTextForPlayer(i,"~w~The game is ~g~Finished!",3000,3);}}
- return 1;}
- public RoundTimer2(){
- RoundCountActive=0;
- KillTimer(TimerCountDown);
- SetTimer("RoundTimer3",14000,0);
- for(new i=0;i<MAX_SERVER_PLAYERS;i++){
- if(GetPlayerVirtualWorld(i)==SHIP__WORLD){
- if(ArmyScore==EnemyScore){
- if(Options[Language]==1)GameTextForPlayer(i,"~b~Nessun team ha vinto!",3000,3);
- if(Options[Language]==2)GameTextForPlayer(i,"~b~No one has won the Game!",3000,3);}
- if(ArmyScore>EnemyScore){
- if(Options[Language]==1)GameTextForPlayer(i,"~g~La Difesa ha vinto la partita!",3000,3);
- if(Options[Language]==2)GameTextForPlayer(i,"~g~Defence ~w~has won the game!",3000,3);}
- if(ArmyScore<EnemyScore){
- if(Options[Language]==1)GameTextForPlayer(i,"~r~Il nemico ~w~ha vinto la partita!",3000,3);
- if(Options[Language]==2)GameTextForPlayer(i,"~r~Enemy ~w~has won the game!",3000,3);}}}
- return 1;}
- public DefuseBomb(){
- for(new i=0;i<MAX_SERVER_PLAYERS;i++)if(IsPlayerConnected(i))if(GetPlayerVirtualWorld(i)==SHIP__WORLD){
- if(Checkpoint3[i]==SHIP_CHECKPOINT_BOMB || Checkpoint3[i]==SHIP_CHECKPOINT_NONE){
- Checkpoint3[i]=SHIP_CHECKPOINT_SHIP;
- if(Options[Language]==1)GameTextForPlayer(i,"~w~La BOMBA e' stata ~g~Disinnescata!!!",4000,3);
- if(Options[Language]==2)GameTextForPlayer(i,"~w~The BOMB has been ~g~Defused!!!",4000,3);
- DisablePlayerCheckpoint(i);
- KillTimer(TimerCountDown);
- Bombcountdown=bcountdown;
- DestroyObject(Bomb);
- BombPlazed=false;
- if(Options[Language]==1)TextDrawSetString(ShipTextdraw2,"~b~Bomba Disinnescata!");
- if(Options[Language]==2)TextDrawSetString(ShipTextdraw2,"~b~Bomb Defused!");
- print(">>> Bomb DEFUSED! <<<");
- new skin=GetPlayerSkin(i);
- switch(skin){
- case 121,122,206,102,103,104,0,269,270,271,272,108,109,110,105,106,107,114,115,116:{
- SetPlayerCheckpoint(i,-1438.6355,1490.2092,1.8366,2.0);
- Checkpoint3[i]=SHIP_CHECKPOINT_BOMB;
- if(Options[Language]==1)GameTextForPlayer(i,"~w~La BOMBA e' stata ~r~Disinnescata!!!~n~~b~Devi piazzarla di nuovo!",6000,3);
- if(Options[Language]==2)GameTextForPlayer(i,"~w~The BOMB has been ~r~Defused!!!~n~~b~You have to plaze it again!",6000,3);}}}}
- return 1;}
- public Winning(){
- SetTimer("RoundTimer3",10000,0);
- RoundCountActive=0;
- DestroyObject(Bomb);
- if(Options[Language]==1)TextDrawSetString(ShipTextdraw2,"~b~Bomba Non Attivata!");
- if(Options[Language]==2)TextDrawSetString(ShipTextdraw2,"~b~Bomb Not Plazed!");
- for(new i=0;i<MAX_SERVER_PLAYERS;i++){
- if(GetPlayerVirtualWorld(i)==SHIP__WORLD){
- RemovePlayerFromVehicle(i);
- if(Options[Language]==1)GameTextForPlayer(i,"~r~I Nemici ~w~hanno vinto la partita!~n~~w~La nave e' ~r~DISTRUTTA!",9000,3);
- if(Options[Language]==2)GameTextForPlayer(i,"~r~Enemy ~w~has won the game!~n~~w~The ship is ~r~DESTROYED!",9000,3);}}
- return 1;}
- public RoundTimer3(){
- if(Options[Language]==1)TextDrawSetString(ShipTextdraw2,"~b~Bomba Non Piazzata!");
- if(Options[Language]==2)TextDrawSetString(ShipTextdraw2,"~b~Bomb Not Plazed!");
- ArmyScore=0;
- EnemyScore=0;
- Bombcountdown=bcountdown;
- EndRoundMinutes=roundtime-1;
- EndRoundSeconds=60;
- BombPlazed=false;
- KillTimer(TimerCountDown);
- RoundCountActive=1;
- for(new i=0;i<MAX_SERVER_PLAYERS;i++)if(IsPlayerConnected(i)){
- if(GetPlayerVirtualWorld(i)==SHIP__WORLD){
- TogglePlayerControllable(i,1);
- SpawnPlayer(i);
- SetPlayerHealth(i,100);
- SendClientMessage(i,COLOR_GREEN,"____________________________________________________________________________");
- SendClientMessage(i,COLOR_WHITE,"____________________________________________________________________________");
- SendClientMessage(i,COLOR_LIGHTRED,"____________________________________________________________________________");
- if(Options[Language]==1)SendClientMessage(i,COLOR_YELLOW,"RESTART GAME: Il gioco รจ stato riavviato per un nuovo round.");
- if(Options[Language]==2)SendClientMessage(i,COLOR_YELLOW,"RESTART GAME: The game has been restarted for a new round.");}}
- return 1;}
- public ReActiveCheckpointBomb(playerid){
- Checkpoint3[playerid]=SHIP_CHECKPOINT_BOMB;
- SetPlayerCheckpoint(playerid,-1438.0116,1491.1317,1.8672,2.0);
- BombPlazed=false;
- return 1;}
- public PlantBomb(playerid){
- TogglePlayerControllable(playerid,1);
- Bomb=CreateObject(3786,-1438.0116,1491.1317,0.8672,0.0,0.0,0.0);
- TimerCountDown=SetTimer("BombCountDown",900,1);
- Bombcountdown=bcountdown;
- BombPlazed=true;
- TextDrawSetString(ShipTextdraw2,"Bomb Plazed!");
- for(new i=0;i<MAX_SERVER_PLAYERS;i++)if(IsPlayerConnected(i))if(GetPlayerVirtualWorld(i)==SHIP__WORLD){
- if(Options[Language]==1)GameTextForPlayer(i,"~r~LA BOMBA E' STATA ATTIVATA!",3000,3);
- if(Options[Language]==2)GameTextForPlayer(i,"~r~THE BOMB HAS BEEN ACTIVED!",3000,3);
- DisablePlayerCheckpoint(i);
- new skin=GetPlayerSkin(i);
- switch(skin){
- case 287,165,286,285,248,100,247:{
- Checkpoint3[i]=SHIP_CHECKPOINT_BOMB;
- SetPlayerCheckpoint(i,-1438.0116,1491.1317,1.8672,2.0);
- if(Options[Language]==1)GameTextForPlayer(i,"~r~DISATTIVA LA BOMBA PRIMA CHE ESPLODA!!!",3000,3);
- if(Options[Language]==2)GameTextForPlayer(i,"~r~DEFUSE THE BOMB BEFORE IT EXPLODES!!!",3000,3);}}}
- if(Options[Language]==1)GameTextForPlayer(playerid,"~r~SCAPPA DALLA NAVE!",3000,3);
- if(Options[Language]==2)GameTextForPlayer(playerid,"~r~ESCAPE FROM THE SHIP!",3000,3);
- return 1;}
- public BombCountDown(){
- if(Bombcountdown>=1){
- if(Options[Language]==1)format(tstring2,sizeof(tstring2),"~y~La bomba esplodera' tra~n~~r~%d Secondi~g~!!!",Bombcountdown);
- if(Options[Language]==2)format(tstring2,sizeof(tstring2),"~y~Bomb Will explode in~n~~r~%d Seconds~g~!!!",Bombcountdown);
- for(new i=0;i<MAX_SERVER_PLAYERS;i++)if(IsPlayerConnected(i))GameTextForPlayer(i,tstring2,2000,3);
- Bombcountdown--;}else
- if(Bombcountdown==0){
- for(new i=0;i<MAX_SERVER_PLAYERS;i++)if(IsPlayerConnected(i))if(GetPlayerVirtualWorld(i)==SHIP__WORLD){
- CodeActive[i]=0;
- GameTextForPlayer(i,"~r~BOOM!!!!",5000,3);
- TogglePlayerControllable(i,0);}
- KillTimer(TimerCountDown);
- SetTimer("SecondExp",1000,0);
- Bombcountdown=bcountdown;
- ShowShipCamera();
- ShowFirstExplosions();}
- return 1;}
- public SecondExp(){
- ShowSecondExplosions();
- SetTimer("ThirdExp",1000,0);
- return 1;}
- public ThirdExp(){
- ShowThirdExplosions();
- Winning();
- return 1;}
- public ShowFirstExplosions(){
- CreateExplosion(-1437.5767,1491.3003,1.8672,7,12000);
- CreateExplosion(-1430.2054,1490.6703,1.8672,7,12000);
- CreateExplosion(-1422.5399,1498.2721,1.8672,7,12000);
- CreateExplosion(-1413.2773,1496.5386,1.8672,7,12000);
- CreateExplosion(-1392.3235,1496.0385,1.8735,7,12000);
- CreateExplosion(-1392.5648,1481.6636,1.8672,7,12000);
- CreateExplosion(-1411.4480,1482.9911,1.8672,7,12000);
- CreateExplosion(-1417.1648,1489.5833,4.6081,7,12000);
- CreateExplosion(-1396.0765,1489.5842,4.6081,7,12000);
- TextDrawSetString(ShipTextdraw2,"~w~Bomb EXPLODED!");}
- public ShowSecondExplosions(){
- CreateExplosion(-1384.0355,1493.9211,1.8516,7,12000);
- CreateExplosion(-1371.4795,1494.9740,1.8516,7,12000);
- CreateExplosion(-1383.9622,1484.5983,8.9063,7,12000);
- CreateExplosion(-1378.2446,1488.9755,11.2031,7,12000);}
- public ShowThirdExplosions(){
- CreateExplosion(-1363.4955,1489.6821,11.0391,7,12000);
- CreateExplosion(-1371.0344,1497.2571,11.0391,7,12000);
- CreateExplosion(-1388.6154,1497.6204,7.1016,7,12000);
- CreateExplosion(-1389.0101,1481.4670,7.1092,7,12000);
- CreateExplosion(-1395.5691,1479.9114,7.1016,7,12000);
- CreateExplosion(-1417.3058,1479.9515,7.1016,7,12000);
- CreateExplosion(-1420.8896,1493.4929,7.1016,7,12000);
- CreateExplosion(-1437.3196,1490.3585,7.1016,7,12000);
- CreateExplosion(-1447.7533,1503.4209,1.7366,7,12000);
- CreateExplosion(-1465.6848,1494.2998,8.2578,7,12000);
- CreateExplosion(-1475.1741,1488.3488,8.2501,7,12000);
- CreateExplosion(-1446.0907,1483.5988,7.1016,7,12000);
- CreateExplosion(-1375.0986,1496.1176,13.8438,7,12000);
- CreateExplosion(-1375.3422,1481.8638,13.8438,7,12000);
- CreateExplosion(-1385.4469,1489.0769,13.8374,7,12000);
- CreateExplosion(-1385.1022,1496.8134,13.8438,7,12000);
- CreateExplosion(-1379.2994,1486.2386,16.3203,7,12000);
- CreateExplosion(-1382.9072,1489.8315,16.3189,7,12000);
- CreateExplosion(-1379.0686,1489.8683,24.7743,7,12000);
- BombPlazed=false;}
Advertisement
Add Comment
Please, Sign In to add comment