Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* Well I bring to you My First FS.
- Well it was developed from scratch, it was nothing to do =).
- well this is pretty simple ta v.1 intão same.
- Do not remove the Credits
- This FS was made of heart!
- Soon I'll be here again to V.2 Release
- - = - = - = -
- - = - = - = -
- - = - = - = - = (MAGNETICLOVE-) = - = - = -
- - = - = - = - = (MAGNETICLOVE-) = - = - = -
- - = - = - = -
- - = - = - = -
- */
- #include < a_samp >
- #include < zcmd >
- #include < sscanf2 >
- #include < missel >
- new challenger;
- new opponent;
- new Vehicle;
- new bool:Battle[MAX_PLAYERS];
- public OnFilterScriptInit()
- {
- print("\n--------------------------------------");
- print("RC BATTLE COMBAT");
- print("--------------------------------------\n");
- return 1;
- }
- public OnFilterScriptExit()
- {
- return 1;
- }
- public OnPlayerRequestClass(playerid, classid)
- {
- SetPlayerPos(playerid, 1958.3783, 1343.1572, 15.3746);
- SetPlayerCameraPos(playerid, 1958.3783, 1343.1572, 15.3746);
- SetPlayerCameraLookAt(playerid, 1958.3783, 1343.1572, 15.3746);
- return 1;
- }
- COMMAND:createrc(playerid, params[])
- {
- new str[200];
- new Nome[MAX_PLAYER_NAME];
- GetPlayerName(playerid, Nome, 24);
- if(Battle[playerid]) return SendClientMessage(playerid, -1, "{5FFF00}Player Has Some In Battle");
- if(sscanf(params, "i", opponent)) return SendClientMessage(playerid, -1, "{8C8C8C}Use /createrc {5FFF00}[ID]");
- if(!IsPlayerConnected(opponent)) return SendClientMessage(playerid, -1, "ERROR:{8C8C8C} player is not connected !");
- Battle[playerid] = true;
- format(str, sizeof(str), "{0023FF}the player {5FFF00}%s {0023FF}is inviting you\nfor a battle in {5FFF00}RC Battle Command, {0023FF}want to accept?", Nome);
- ShowPlayerDialog(opponent, 1, DIALOG_STYLE_MSGBOX, "RC Battle Command", str, "Confirm","Cancel");
- return 1;
- }
- COMMAND:givebattle(playerid)
- {
- if(!Battle[playerid]) return SendClientMessage(playerid, -1, "You're not giving up the fight to");
- Battle[playerid] = false;
- SpawnPlayer(playerid);
- return 1;
- }
- COMMAND:missile(playerid)
- {
- AddVehicleMissiles(Vehicle,1.1,0.0);
- return 1;
- }
- public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
- {
- VM_OnPlayerKeyStateChange(playerid,newkeys);
- return 1;
- }
- public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
- {
- if(dialogid == 1)
- {
- if(!response) return SendClientMessage(challenger, -1, "{2DFF00}He refused to fight");
- SendClientMessage(challenger, -1, "{2DFF00}He Accept Your Invitation");
- SetPlayerInterior(challenger, 10);
- SetPlayerInterior(opponent, 10);
- SetPlayerPos(challenger, -974.2322,1061.0780,1345.6754);
- SetPlayerPos(opponent, -1130.2719,1057.8379,1346.4141);
- new
- Float:x,
- Float:y,
- Float:z
- ;
- GetPlayerPos(playerid,x,y,z);
- Vehicle = 0;
- Vehicle = CreateVehicle(564,-974.2322,1061.0780,1345.6754,0.0,-1,-1,1000);
- Vehicle = CreateVehicle(564,-1130.2719,1057.8379,1346.4141,0.0,-1,-1,1000);
- AddVehicleMissiles(Vehicle,1.1,0.0);
- PutPlayerInVehicle(opponent,Vehicle,0);
- PutPlayerInVehicle(challenger, Vehicle,0);
- LinkVehicleToInterior(Vehicle, 10);
- LinkVehicleToInterior(Vehicle, 10);
- PutPlayerInVehicle(challenger, Vehicle, 0);
- PutPlayerInVehicle(opponent, Vehicle, 0);
- return 1;
- }
- return 1;
- }
- public VM_OnVehicleFire(vehicleid,slot)
- {
- return 1;
- }
Advertisement
Add Comment
Please, Sign In to add comment