Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- [PC Filterscript by Ronny16
- Dieses Notebook System wurde von Ronny16
- Geschrieben. Schaut es euch einfach an.
- Ich würde es Cool finden wenn ihr es
- Bewerten / Benutzen würdet.
- */
- #include <a_samp>
- #include <ocmd>
- //=====|Defines|=====//
- #define DIALOG_BURGERSHOT 1
- #define DIALOG_WAFFENLADEN 2
- #define DIALOG_247LADEN 3
- #define DIALOG_HMLADEN 4
- #define DIALOG_PCKAUFEN 5
- //=====|News |=====//
- new Text:Textdraw0;
- new Text:Textdraw1;
- new Text:Textdraw2;
- new Text:Textdraw3;
- new Text:Textdraw4;
- new Text:Textdraw5;
- new Text:Textdraw6;
- new Text:Textdraw7;
- new Text:Textdraw8;
- new Text:Textdraw9;
- new Text:Textdraw10;
- new Text:Textdraw11;
- new Text:Textdraw12;
- new Text:Textdraw13;
- new Text:Textdraw14;
- new Text:Textdraw15;
- new Text:Textdraw16;
- new Text:Textdraw17;
- new Text:Textdraw18;
- enum PlayerInfo
- {
- Adminlevel,
- pLaptop, // Ist eigentlich Unwichtig! Da es ey nicht gespeichert / Geladen wird
- //Ist halt nur so gedacht das man sich vorher ein Laptop kaufen muss.
- //muss nicht benutzt werden. MFG Ronny :D
- };
- new pInfo[MAX_PLAYERS][PlayerInfo];
- main()
- {
- print("\n----------------------------------");
- print(" Notebook System| By Ronny16|");
- print(" Wurde erfolgreich geladen");
- print("----------------------------------\n");
- }
- public OnGameModeInit()
- {
- SetGameModeText("Pc");
- AddPlayerClass(53,998.7527,-944.7200,42.0745,78.2254,0,0,0,0,0,0); // Spawn Tankstelle [BSN]
- AddStaticPickup(1239, 2, 980.5051,-933.3316,41.3362); // Laptop kaufen
- Create3DTextLabel("Laufe ins Pickup",0xFF6E00FF,980.5051,-933.3316,41.3362,10,0,0);
- AddStaticVehicleEx(461,998.7527,-944.7200,42.0745,78.2254,22,22,-1); // BallaVehs10
- //=====|TextDraws|=====//
- print("Laptop Script V.0.1 [2012]");
- print("By Ronny16");
- // Create the textdraws:
- Textdraw0 = TextDrawCreate(177.000000, 150.000000, ".");
- TextDrawBackgroundColor(Textdraw0, 255);
- TextDrawFont(Textdraw0, 1);
- TextDrawLetterSize(Textdraw0, 1.759999, 19.300003);
- TextDrawColor(Textdraw0, 255);
- TextDrawSetOutline(Textdraw0, 0);
- TextDrawSetProportional(Textdraw0, 1);
- TextDrawSetShadow(Textdraw0, 1);
- TextDrawUseBox(Textdraw0, 1);
- TextDrawBoxColor(Textdraw0, 255);
- TextDrawTextSize(Textdraw0, 446.000000, 8.000000);
- TextDrawSetSelectable(Textdraw0,false);
- Textdraw1 = TextDrawCreate(175.000000, 156.000000, "--------------------------------------------");
- TextDrawBackgroundColor(Textdraw1, 255);
- TextDrawFont(Textdraw1, 1);
- TextDrawLetterSize(Textdraw1, 0.439999, 1.000000);
- TextDrawColor(Textdraw1, -1);
- TextDrawSetOutline(Textdraw1, 0);
- TextDrawSetProportional(Textdraw1, 1);
- TextDrawSetShadow(Textdraw1, 1);
- TextDrawSetSelectable(Textdraw1,false);
- Textdraw2 = TextDrawCreate(175.000000, 308.000000, "--------------------------------------------");
- TextDrawBackgroundColor(Textdraw2, 255);
- TextDrawFont(Textdraw2, 1);
- TextDrawLetterSize(Textdraw2, 0.439999, 1.000000);
- TextDrawColor(Textdraw2, -1);
- TextDrawSetOutline(Textdraw2, 0);
- TextDrawSetProportional(Textdraw2, 1);
- TextDrawSetShadow(Textdraw2, 1);
- TextDrawSetSelectable(Textdraw2,false);
- Textdraw3 = TextDrawCreate(229.000000, 149.000000, "Notebook bitte waehle etwas aus");
- TextDrawBackgroundColor(Textdraw3, 255);
- TextDrawFont(Textdraw3, 1);
- TextDrawLetterSize(Textdraw3, 0.280000, 1.000000);
- TextDrawColor(Textdraw3, 16711935);
- TextDrawSetOutline(Textdraw3, 0);
- TextDrawSetProportional(Textdraw3, 1);
- TextDrawSetShadow(Textdraw3, 1);
- TextDrawSetSelectable(Textdraw3,false);
- Textdraw4 = TextDrawCreate(186.000000, 176.000000, "Burger Shot");
- TextDrawBackgroundColor(Textdraw4, 255);
- TextDrawFont(Textdraw4, 2);
- TextDrawLetterSize(Textdraw4, 0.189999, 1.600000);
- TextDrawColor(Textdraw4, -16776961);
- TextDrawSetOutline(Textdraw4, 0);
- TextDrawSetProportional(Textdraw4, 1);
- TextDrawSetShadow(Textdraw4, 1);
- TextDrawSetSelectable(Textdraw4,true);
- Textdraw5 = TextDrawCreate(179.000000, 170.000000, "----------");
- TextDrawBackgroundColor(Textdraw5, 255);
- TextDrawFont(Textdraw5, 1);
- TextDrawLetterSize(Textdraw5, 0.500000, 1.000000);
- TextDrawColor(Textdraw5, 16711935);
- TextDrawSetOutline(Textdraw5, 0);
- TextDrawSetProportional(Textdraw5, 1);
- TextDrawSetShadow(Textdraw5, 1);
- TextDrawSetSelectable(Textdraw5,false);
- Textdraw6 = TextDrawCreate(179.000000, 185.000000, "----------");
- TextDrawBackgroundColor(Textdraw6, 255);
- TextDrawFont(Textdraw6, 1);
- TextDrawLetterSize(Textdraw6, 0.500000, 1.000000);
- TextDrawColor(Textdraw6, 16711935);
- TextDrawSetOutline(Textdraw6, 0);
- TextDrawSetProportional(Textdraw6, 1);
- TextDrawSetShadow(Textdraw6, 1);
- TextDrawSetSelectable(Textdraw6,false);
- Textdraw7 = TextDrawCreate(370.000000, 170.000000, "----------");
- TextDrawBackgroundColor(Textdraw7, 255);
- TextDrawFont(Textdraw7, 1);
- TextDrawLetterSize(Textdraw7, 0.500000, 1.000000);
- TextDrawColor(Textdraw7, 16711935);
- TextDrawSetOutline(Textdraw7, 0);
- TextDrawSetProportional(Textdraw7, 1);
- TextDrawSetShadow(Textdraw7, 1);
- TextDrawSetSelectable(Textdraw7,false);
- Textdraw8 = TextDrawCreate(371.000000, 185.000000, "----------");
- TextDrawBackgroundColor(Textdraw8, 255);
- TextDrawFont(Textdraw8, 1);
- TextDrawLetterSize(Textdraw8, 0.500000, 1.000000);
- TextDrawColor(Textdraw8, 16711935);
- TextDrawSetOutline(Textdraw8, 0);
- TextDrawSetProportional(Textdraw8, 1);
- TextDrawSetShadow(Textdraw8, 1);
- TextDrawSetSelectable(Textdraw8,false);
- Textdraw9 = TextDrawCreate(375.000000, 177.000000, "Waffenladen");
- TextDrawBackgroundColor(Textdraw9, 255);
- TextDrawFont(Textdraw9, 2);
- TextDrawLetterSize(Textdraw9, 0.210000, 1.300000);
- TextDrawColor(Textdraw9, -16776961);
- TextDrawSetOutline(Textdraw9, 0);
- TextDrawSetProportional(Textdraw9, 1);
- TextDrawSetShadow(Textdraw9, 1);
- TextDrawSetSelectable(Textdraw9,true);
- Textdraw10 = TextDrawCreate(179.000000, 269.000000, "----------");
- TextDrawBackgroundColor(Textdraw10, 255);
- TextDrawFont(Textdraw10, 1);
- TextDrawLetterSize(Textdraw10, 0.500000, 1.000000);
- TextDrawColor(Textdraw10, 16711935);
- TextDrawSetOutline(Textdraw10, 0);
- TextDrawSetProportional(Textdraw10, 1);
- TextDrawSetShadow(Textdraw10, 1);
- TextDrawSetSelectable(Textdraw10,false);
- Textdraw11 = TextDrawCreate(179.000000, 286.000000, "----------");
- TextDrawBackgroundColor(Textdraw11, 255);
- TextDrawFont(Textdraw11, 1);
- TextDrawLetterSize(Textdraw11, 0.500000, 1.000000);
- TextDrawColor(Textdraw11, 16711935);
- TextDrawSetOutline(Textdraw11, 0);
- TextDrawSetProportional(Textdraw11, 1);
- TextDrawSetShadow(Textdraw11, 1);
- TextDrawSetSelectable(Textdraw11,false);
- Textdraw12 = TextDrawCreate(189.000000, 278.000000, "24/7");
- TextDrawBackgroundColor(Textdraw12, 255);
- TextDrawFont(Textdraw12, 2);
- TextDrawLetterSize(Textdraw12, 0.400000, 1.100000);
- TextDrawColor(Textdraw12, -16776961);
- TextDrawSetOutline(Textdraw12, 0);
- TextDrawSetProportional(Textdraw12, 1);
- TextDrawSetShadow(Textdraw12, 1);
- TextDrawSetSelectable(Textdraw12,true);
- Textdraw13 = TextDrawCreate(368.000000, 269.000000, "----------");
- TextDrawBackgroundColor(Textdraw13, 255);
- TextDrawFont(Textdraw13, 1);
- TextDrawLetterSize(Textdraw13, 0.500000, 1.000000);
- TextDrawColor(Textdraw13, 16711935);
- TextDrawSetOutline(Textdraw13, 0);
- TextDrawSetProportional(Textdraw13, 1);
- TextDrawSetShadow(Textdraw13, 1);
- TextDrawSetSelectable(Textdraw13,false);
- Textdraw14 = TextDrawCreate(369.000000, 286.000000, "----------");
- TextDrawBackgroundColor(Textdraw14, 255);
- TextDrawFont(Textdraw14, 1);
- TextDrawLetterSize(Textdraw14, 0.500000, 1.000000);
- TextDrawColor(Textdraw14, 16711935);
- TextDrawSetOutline(Textdraw14, 0);
- TextDrawSetProportional(Textdraw14, 1);
- TextDrawSetShadow(Textdraw14, 1);
- TextDrawSetSelectable(Textdraw14,false);
- Textdraw15 = TextDrawCreate(372.000000, 278.000000, "Aussehen");
- TextDrawBackgroundColor(Textdraw15, 255);
- TextDrawFont(Textdraw15, 2);
- TextDrawLetterSize(Textdraw15, 0.290000, 1.100000);
- TextDrawColor(Textdraw15, -16776961);
- TextDrawSetOutline(Textdraw15, 0);
- TextDrawSetProportional(Textdraw15, 1);
- TextDrawSetShadow(Textdraw15, 1);
- TextDrawSetSelectable(Textdraw15,true);
- Textdraw16 = TextDrawCreate(269.000000, 314.000000, "Ausloggen");
- TextDrawBackgroundColor(Textdraw16, 255);
- TextDrawFont(Textdraw16, 1);
- TextDrawLetterSize(Textdraw16, 0.500000, 1.000000);
- TextDrawColor(Textdraw16, -16776961);
- TextDrawSetOutline(Textdraw16, 0);
- TextDrawSetProportional(Textdraw16, 1);
- TextDrawSetShadow(Textdraw16, 1);
- TextDrawSetSelectable(Textdraw16,true);
- Textdraw17 = TextDrawCreate(258.000000, 215.000000, "Windows ~y~7");
- TextDrawBackgroundColor(Textdraw17, 255);
- TextDrawFont(Textdraw17, 1);
- TextDrawLetterSize(Textdraw17, 0.649999, 3.399998);
- TextDrawColor(Textdraw17, -1);
- TextDrawSetOutline(Textdraw17, 0);
- TextDrawSetProportional(Textdraw17, 1);
- TextDrawSetShadow(Textdraw17, 1);
- Textdraw18 = TextDrawCreate(263.000000, 246.000000, "Premium Edition by Ronny");
- TextDrawBackgroundColor(Textdraw18, 255);
- TextDrawFont(Textdraw18, 1);
- TextDrawLetterSize(Textdraw18, 0.310000, 1.100000);
- TextDrawColor(Textdraw18, -1);
- TextDrawSetOutline(Textdraw18, 0);
- TextDrawSetProportional(Textdraw18, 1);
- TextDrawSetShadow(Textdraw18, 1);
- return 1;
- }
- public OnGameModeExit()
- {
- 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;
- }
- public OnPlayerConnect(playerid)
- {
- pInfo[playerid][Adminlevel] = 2000;
- return 1;
- }
- public OnPlayerDisconnect(playerid, reason)
- {
- return 1;
- }
- public OnPlayerSpawn(playerid)
- {
- return 1;
- }
- public OnPlayerDeath(playerid, killerid, reason)
- {
- return 1;
- }
- public OnVehicleSpawn(vehicleid)
- {
- return 1;
- }
- public OnVehicleDeath(vehicleid, killerid)
- {
- return 1;
- }
- public OnPlayerText(playerid, text[])
- {
- return 1;
- }
- public OnPlayerCommandText(playerid, cmdtext[])
- {
- if (strcmp("/Autoteuer", cmdtext, true, 10) == 0)
- {
- SetPlayerPos(playerid,1235.0052,-1661.7747,11.7969);
- return 1;
- }
- if (strcmp("/Kaufen", cmdtext, true, 10) == 0)
- {
- if(IsPlayerInRangeOfPoint(playerid,2.0,980.5051,-933.3316,41.3362))
- {
- new stringnews[1700];
- format(stringnews,sizeof(stringnews),"{FEFEFE}Herzlich Willkommen in Ronny,s Pc laden\nMoechten sie sich für {FF3200}50€{FEFEFE} ein Laptop laufen");
- ShowPlayerDialog(playerid, DIALOG_PCKAUFEN, DIALOG_STYLE_MSGBOX, "PC-Laden{0FFF00}[By Ronny]{FEFEFE}",stringnews,"Kaufen","Abbrechen");
- return 1;
- }
- else
- {
- SendClientMessage(playerid,0xEB0000FF,"Du bist nicht im Kauf Pickup!");
- return 1;
- }
- }
- if (strcmp("/Leben", cmdtext, true, 10) == 0)
- {
- SetPlayerHealth(playerid,40);
- return 1;
- }
- if (strcmp("/Geld", cmdtext, true, 10) == 0)
- {
- GivePlayerMoney(playerid,50000);
- return 1;
- }
- if (strcmp("/Laptop", cmdtext, true, 10) == 0)
- {
- if(pInfo[playerid][pLaptop] > 0)
- {
- TogglePlayerControllable ( playerid, false );
- Showlaptop(playerid);
- SendClientMessage(playerid,0x00FFDCFF,"Du hast dein Laptop gestartet");
- TextDrawShowForPlayer(playerid, Textdraw0);
- TextDrawShowForPlayer(playerid, Textdraw1);
- TextDrawShowForPlayer(playerid, Textdraw2);
- TextDrawShowForPlayer(playerid, Textdraw3);
- TextDrawShowForPlayer(playerid, Textdraw5);
- TextDrawShowForPlayer(playerid, Textdraw6);
- TextDrawShowForPlayer(playerid, Textdraw7);
- TextDrawShowForPlayer(playerid, Textdraw8);
- TextDrawShowForPlayer(playerid, Textdraw10);
- TextDrawShowForPlayer(playerid, Textdraw11);
- TextDrawShowForPlayer(playerid, Textdraw13);
- TextDrawShowForPlayer(playerid, Textdraw14);
- TextDrawShowForPlayer(playerid, Textdraw17);
- TextDrawShowForPlayer(playerid, Textdraw18);
- }
- else
- {
- SendClientMessage(playerid,0xEB0000FF,"Du hast kein Laptop!");
- return 1;
- }
- return 1;
- }
- return 0;
- }
- public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
- {
- return 1;
- }
- public OnPlayerExitVehicle(playerid, vehicleid)
- {
- return 1;
- }
- public OnPlayerStateChange(playerid, newstate, oldstate)
- {
- return 1;
- }
- public OnPlayerEnterCheckpoint(playerid)
- {
- return 1;
- }
- public OnPlayerLeaveCheckpoint(playerid)
- {
- return 1;
- }
- public OnPlayerEnterRaceCheckpoint(playerid)
- {
- return 1;
- }
- public OnPlayerLeaveRaceCheckpoint(playerid)
- {
- return 1;
- }
- public OnRconCommand(cmd[])
- {
- return 1;
- }
- public OnPlayerRequestSpawn(playerid)
- {
- return 1;
- }
- public OnObjectMoved(objectid)
- {
- return 1;
- }
- public OnPlayerObjectMoved(playerid, objectid)
- {
- return 1;
- }
- public OnPlayerPickUpPickup(playerid, pickupid)
- {
- if(IsPlayerInRangeOfPoint(playerid,2.0,980.5051,-933.3316,41.3362))//Laptop Kaufen
- {
- GameTextForPlayer(playerid,"~g~/kaufen",2000,4);
- }
- return 1;
- }
- public OnVehicleMod(playerid, vehicleid, componentid)
- {
- return 1;
- }
- public OnVehiclePaintjob(playerid, vehicleid, paintjobid)
- {
- return 1;
- }
- public OnVehicleRespray(playerid, vehicleid, color1, color2)
- {
- return 1;
- }
- public OnPlayerSelectedMenuRow(playerid, row)
- {
- return 1;
- }
- public OnPlayerExitedMenu(playerid)
- {
- return 1;
- }
- public OnPlayerInteriorChange(playerid, newinteriorid, oldinteriorid)
- {
- return 1;
- }
- public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
- {
- return 1;
- }
- public OnRconLoginAttempt(ip[], password[], success)
- {
- return 1;
- }
- public OnPlayerUpdate(playerid)
- {
- return 1;
- }
- public OnPlayerStreamIn(playerid, forplayerid)
- {
- return 1;
- }
- public OnPlayerStreamOut(playerid, forplayerid)
- {
- return 1;
- }
- public OnVehicleStreamIn(vehicleid, forplayerid)
- {
- return 1;
- }
- public OnVehicleStreamOut(vehicleid, forplayerid)
- {
- return 1;
- }
- public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
- {
- if(dialogid == DIALOG_PCKAUFEN)
- {
- if(response==0)
- {
- SendClientMessage(playerid,0xEB0000FF,"Du möchtest dir also kein Laptop kaufen!");
- }
- if(response==1)
- {
- if(GetPlayerMoney(playerid) < 50)
- {
- SendClientMessage(playerid, 0xFF3200FF, "{FF1E00}Du hast nicht genug Geld [{F5FF00}50,00${FF1E00}].");
- return 1;
- }
- SendClientMessage(playerid,0xEB0000FF,"Du hast dir für 50,00$ Ein Laptop gekauft /laptop !");
- GivePlayerMoney(playerid,-50);
- pInfo[playerid][pLaptop] = 1;
- }
- }
- if(dialogid == DIALOG_HMLADEN)
- {
- if(response == 1)
- {
- switch (listitem)
- {
- case 0://CJ-SKIN 5$
- {
- if(GetPlayerMoney(playerid) < 5)
- {
- SendClientMessage(playerid, 0xFF3200FF, "{FF1E00}Du hast nicht genug Geld [{F5FF00}5,00${FF1E00}].");
- return 1;
- }
- SendClientMessage(playerid,0xFAFAFAFF,"Du hast dir für {FF2800}-5,00€{FAFAFA} Den CJ Skin bestellt!");
- GivePlayerMoney(playerid,-5);
- SetPlayerSkin(playerid,0);
- ShowPlayerDialog(playerid, DIALOG_HMLADEN, DIALOG_STYLE_LIST, "{FF6400}H&M-Internetseite{FEFEFE}", "CJ-Skin: 5,00$\nOma-Skin: 10,00$\nGangster-Skin: 15,00$", "Bestellen", "Zurueck");
- }
- case 1://Oma-SKIN 10$
- {
- if(GetPlayerMoney(playerid) < 10)
- {
- SendClientMessage(playerid, 0xFF3200FF, "{FF1E00}Du hast nicht genug Geld [{F5FF00}10,00${FF1E00}].");
- return 1;
- }
- SendClientMessage(playerid,0xFAFAFAFF,"Du hast dir für {FF2800}-10,00€{FAFAFA} Den Oma Skin bestellt!");
- GivePlayerMoney(playerid,-10);
- SetPlayerSkin(playerid,10);
- ShowPlayerDialog(playerid, DIALOG_HMLADEN, DIALOG_STYLE_LIST, "{FF6400}H&M-Internetseite{FEFEFE}", "CJ-Skin: 5,00$\nOma-Skin: 10,00$\nGangster-Skin: 15,00$", "Bestellen", "Zurueck");
- }
- case 2://Gangster-Skin 15,00$
- {
- if(GetPlayerMoney(playerid) < 15)
- {
- SendClientMessage(playerid, 0xFF3200FF, "{FF1E00}Du hast nicht genug Geld [{F5FF00}15,00${FF1E00}].");
- return 1;
- }
- SendClientMessage(playerid,0xFAFAFAFF,"Du hast dir für {FF2800}-15,00€{FAFAFA} Den Gangster Skin bestellt!");
- GivePlayerMoney(playerid,-15);
- SetPlayerSkin(playerid,21);
- ShowPlayerDialog(playerid, DIALOG_HMLADEN, DIALOG_STYLE_LIST, "{FF6400}H&M-Internetseite{FEFEFE}", "CJ-Skin: 5,00$\nOma-Skin: 10,00$\nGangster-Skin: 15,00$", "Bestellen", "Zurueck");
- }
- }
- }
- }
- if(dialogid == DIALOG_247LADEN)
- {
- if(response == 1)
- {
- switch (listitem)
- {
- case 0://Kippen 5$
- {
- if(GetPlayerMoney(playerid) < 5)
- {
- SendClientMessage(playerid, 0xFF3200FF, "{FF1E00}Du hast nicht genug Geld [{F5FF00}5,00${FF1E00}].");
- return 1;
- }
- SendClientMessage(playerid,0xFAFAFAFF,"Du hast dir für {FF2800}-5,00€{FAFAFA} eine Schachtel Kippen bestellt!");
- GivePlayerMoney(playerid,-5);
- SetPlayerSpecialAction(playerid,SPECIAL_ACTION_SMOKE_CIGGY);
- ShowPlayerDialog(playerid, DIALOG_247LADEN, DIALOG_STYLE_LIST, "{FF6400}24/7-Internetseite{FEFEFE}", "Kippen: 5$", "Bestellen", "Zurueck");
- }
- }
- }
- }
- if(dialogid == DIALOG_WAFFENLADEN)
- {
- if(response == 1)
- {
- switch (listitem)
- {
- case 0://Deagle 150$
- {
- if(GetPlayerMoney(playerid) < 150)
- {
- SendClientMessage(playerid, 0xFF3200FF, "{FF1E00}Du hast nicht genug Geld [{F5FF00}150,00${FF1E00}].");
- return 1;
- }
- SendClientMessage(playerid,0xFAFAFAFF,"Du hast dir für {FF2800}-150,00€{FAFAFA} eine Deagle bestellt!");
- GivePlayerMoney(playerid,-150);
- GivePlayerWeapon(playerid,24,50);
- ShowPlayerDialog(playerid, DIALOG_WAFFENLADEN, DIALOG_STYLE_LIST, "{FF6400}WL-Internetseite{FEFEFE}", "Deagle: 150$\nMesser: 5,00$\n9mm: 200$\nAK-47: 500$", "Bestellen", "Zurueck");
- }
- case 1://Messer 5$
- {
- if(GetPlayerMoney(playerid) < 5)
- {
- SendClientMessage(playerid, 0xFF3200FF, "{FF1E00}Du hast nicht genug Geld [{F5FF00}5,00${FF1E00}].");
- return 1;
- }
- SendClientMessage(playerid,0xFAFAFAFF,"Du hast dir für {FF2800}-5,00€{FAFAFA} ein Messer bestellt!");
- GivePlayerMoney(playerid,-5);
- GivePlayerWeapon(playerid,4,1);
- ShowPlayerDialog(playerid, DIALOG_WAFFENLADEN, DIALOG_STYLE_LIST, "{FF6400}WL-Internetseite{FEFEFE}", "Deagle: 150$\nMesser: 5,00$\n9mm: 200$\nAK-47: 500$", "Bestellen", "Zurueck");
- }
- case 2://9mm 200$
- {
- if(GetPlayerMoney(playerid) < 200)
- {
- SendClientMessage(playerid, 0xFF3200FF, "{FF1E00}Du hast nicht genug Geld [{F5FF00}200,00${FF1E00}].");
- return 1;
- }
- SendClientMessage(playerid,0xFAFAFAFF,"Du hast dir für {FF2800}-200,00€{FAFAFA} eine 9mm bestellt!");
- GivePlayerMoney(playerid,-200);
- GivePlayerWeapon(playerid,22,100);
- ShowPlayerDialog(playerid, DIALOG_WAFFENLADEN, DIALOG_STYLE_LIST, "{FF6400}WL-Internetseite{FEFEFE}", "Deagle: 150$\nMesser: 5,00$\n9mm: 200$\nAK-47: 500$", "Bestellen", "Zurueck");
- }
- case 3://Ak47 500$
- {
- if(GetPlayerMoney(playerid) < 500)
- {
- SendClientMessage(playerid, 0xFF3200FF, "{FF1E00}Du hast nicht genug Geld [{F5FF00}500,00${FF1E00}].");
- return 1;
- }
- SendClientMessage(playerid,0xFAFAFAFF,"Du hast dir für {FF2800}-500,00€{FAFAFA} eine Ak47 bestellt!");
- GivePlayerMoney(playerid,-500);
- GivePlayerWeapon(playerid,30,500);
- ShowPlayerDialog(playerid, DIALOG_WAFFENLADEN, DIALOG_STYLE_LIST, "{FF6400}WL-Internetseite{FEFEFE}", "Deagle: 150$\nMesser: 5,00$\n9mm: 200$\nAK-47: 500$", "Bestellen", "Zurueck");
- }
- }
- }
- }
- if(dialogid == DIALOG_BURGERSHOT)
- {
- if(response == 1)
- {
- switch (listitem)
- {
- case 0://Pizza 5$
- {
- new Float:health;
- if(GetPlayerMoney(playerid) < 5)
- {
- SendClientMessage(playerid, 0xFF3200FF, "{FF1E00}Du hast nicht genug Geld [{F5FF00}5,00${FF1E00}].");
- return 1;
- }
- SendClientMessage(playerid,0xFAFAFAFF,"Du hast dir für {FF2800}-5,00€{FAFAFA} eine Pizza bestellt!");
- GivePlayerMoney(playerid,-5);
- GetPlayerHealth(playerid,health);
- SetPlayerHealth(playerid, health+5);
- ShowPlayerDialog(playerid, DIALOG_BURGERSHOT, DIALOG_STYLE_LIST, "{FF6400}BS-Internetseite{FEFEFE}", "Pizza: 5,00$\nCola: 1,00$\nBig-Mag: 10,00$\nBier :1,00$", "Bestellen", "Zurueck");
- }
- case 1://Cola 1$
- {
- new Float:health;
- if(GetPlayerMoney(playerid) < 1)
- {
- SendClientMessage(playerid, 0xFF3200FF, "{FF1E00}Du hast nicht genug Geld [{F5FF00}1,00${FF1E00}].");
- return 1;
- }
- SendClientMessage(playerid,0xFAFAFAFF,"Du hast dir für {FF2800}-1,00${FAFAFA} ein Glas Cola bestellt!");
- GivePlayerMoney(playerid,-1);
- GetPlayerHealth(playerid,health);
- SetPlayerHealth(playerid, health+1);
- SetPlayerSpecialAction(playerid, SPECIAL_ACTION_DRINK_SPRUNK);
- ShowPlayerDialog(playerid, DIALOG_BURGERSHOT, DIALOG_STYLE_LIST, "{FF6400}BS-Internetseite{FEFEFE}", "Pizza: 5,00$\nCola: 1,00$\nBig-Mag: 10,00$\nBier :1,00$", "Bestellen", "Zurueck");
- }
- case 2://Big-Mag 10,00$
- {
- new Float:health;
- if(GetPlayerMoney(playerid) < 10)
- {
- SendClientMessage(playerid, 0xFF3200FF, "{FF1E00}Du hast nicht genug Geld [{F5FF00}10,00${FF1E00}].");
- return 1;
- }
- SendClientMessage(playerid,0xFAFAFAFF,"Du hast dir für {FF2800}-10,00${FAFAFA} ein Big-Mag bestellt!");
- GivePlayerMoney(playerid,-10);
- GetPlayerHealth(playerid,health);
- SetPlayerHealth(playerid, health+10);
- ShowPlayerDialog(playerid, DIALOG_BURGERSHOT, DIALOG_STYLE_LIST, "{FF6400}BS-Internetseite{FEFEFE}", "Pizza: 5,00$\nCola: 1,00$\nBig-Mag: 10,00$\nBier :1,00$", "Bestellen", "Zurueck");
- }
- case 3://Bier 1,00$
- {
- new Float:health;
- if(GetPlayerMoney(playerid) < 1)
- {
- SendClientMessage(playerid, 0xFF3200FF, "{FF1E00}Du hast nicht genug Geld [{F5FF00}1,00${FF1E00}].");
- return 1;
- }
- SendClientMessage(playerid,0xFAFAFAFF,"Du hast dir für {FF2800}-1,00${FAFAFA} eine Flasche Bier bestellt!");
- GivePlayerMoney(playerid,-1);
- GetPlayerHealth(playerid,health);
- SetPlayerHealth(playerid, health+1);
- SetPlayerSpecialAction(playerid, SPECIAL_ACTION_DRINK_BEER);
- ShowPlayerDialog(playerid, DIALOG_BURGERSHOT, DIALOG_STYLE_LIST, "{FF6400}BS-Internetseite{FEFEFE}", "Pizza: 5,00$\nCola: 1,00$\nBig-Mag: 10,00$\nBier :1,00$", "Bestellen", "Zurueck");
- }
- }
- }
- }
- return 1;
- }
- public OnPlayerClickPlayer(playerid, clickedplayerid, source)
- {
- return 1;
- }
- public OnPlayerClickTextDraw(playerid, Text:clickedid)
- {
- if ( clickedid == Textdraw4 )
- {
- SendClientMessage(playerid,0xFAFAFAFF,"Willkommen auf der Burger Shot Internet seite");
- SendClientMessage(playerid,0xFAFAFAFF,"Hier koennen sie sich etwas Online bestellen");
- SendClientMessage(playerid,0xFAFAFAFF,"Bitte weahlen sie ihr bestellung");
- ShowPlayerDialog(playerid, DIALOG_BURGERSHOT, DIALOG_STYLE_LIST, "{FF6400}BS-Internetseite{FEFEFE}", "Pizza: 5,00$\nCola: 1,00$\nBig-Mag: 10,00$\nBier :1,00$", "Bestellen", "Zurueck");
- return 1;
- }
- else if ( clickedid == Textdraw9 )
- {
- SendClientMessage(playerid,0xFAFAFAFF,"Willkommen auf der Internet seite des Waffenladens");
- SendClientMessage(playerid,0xFAFAFAFF,"Hier koennen sie sich etwas Online bestellen");
- ShowPlayerDialog(playerid, DIALOG_WAFFENLADEN, DIALOG_STYLE_LIST, "{FF6400}WL-Internetseite{FEFEFE}", "Deagle: 150$\nMesser: 5,00$\n9mm: 200$\nAK-47: 500$", "Bestellen", "Zurueck");
- return 1;
- }
- else if ( clickedid == Textdraw12 )
- {
- SendClientMessage(playerid,0xFAFAFAFF,"Willkommen auf der Internet vom 24/7 Shop");
- SendClientMessage(playerid,0xFAFAFAFF,"Hier koennen sie sich etwas Online bestellen");
- ShowPlayerDialog(playerid, DIALOG_247LADEN, DIALOG_STYLE_LIST, "{FF6400}24/7-Internetseite{FEFEFE}", "Kippen: 5$", "Bestellen", "Zurueck");
- return 1;
- }
- else if ( clickedid == Textdraw15 )
- {
- SendClientMessage(playerid,0xFAFAFAFF,"Willkommen auf der Internet von H&M");
- SendClientMessage(playerid,0xFAFAFAFF,"Hier koennen sie sich etwas Online bestellen");
- ShowPlayerDialog(playerid, DIALOG_HMLADEN, DIALOG_STYLE_LIST, "{FF6400}H&M-Internetseite{FEFEFE}", "CJ-Skin: 5,00$\nOma-Skin: 10,00$\nGangster-Skin: 15,00$", "Bestellen", "Zurueck");
- return 1;
- }
- else if ( clickedid == Textdraw16 )
- {
- SendClientMessage(playerid,0x00FFDCFF,"Du hast dein Laptop Heruntergefahren");
- TextDrawHideForPlayer(playerid,Textdraw0);
- TextDrawHideForPlayer(playerid,Textdraw1);
- TextDrawHideForPlayer(playerid,Textdraw2);
- TextDrawHideForPlayer(playerid,Textdraw3);
- TextDrawHideForPlayer(playerid,Textdraw4);
- TextDrawHideForPlayer(playerid,Textdraw5);
- TextDrawHideForPlayer(playerid,Textdraw6);
- TextDrawHideForPlayer(playerid,Textdraw7);
- TextDrawHideForPlayer(playerid,Textdraw8);
- TextDrawHideForPlayer(playerid,Textdraw9);
- TextDrawHideForPlayer(playerid,Textdraw10);
- TextDrawHideForPlayer(playerid,Textdraw11);
- TextDrawHideForPlayer(playerid,Textdraw12);
- TextDrawHideForPlayer(playerid,Textdraw13);
- TextDrawHideForPlayer(playerid,Textdraw14);
- TextDrawHideForPlayer(playerid,Textdraw15);
- TextDrawHideForPlayer(playerid,Textdraw16);
- TextDrawHideForPlayer(playerid,Textdraw17);
- TextDrawHideForPlayer(playerid,Textdraw18);
- TogglePlayerControllable ( playerid, true );
- CancelSelectTextDraw (playerid);
- return 1;
- }
- return 1;
- }
- stock Showlaptop(p)
- {
- TextDrawShowForPlayer ( p, Textdraw4);
- TextDrawShowForPlayer ( p, Textdraw9);
- TextDrawShowForPlayer ( p, Textdraw12);
- TextDrawShowForPlayer ( p, Textdraw15);
- TextDrawShowForPlayer ( p, Textdraw16);
- SelectTextDraw ( p , 0xFF9600FF );
- new x = 0;
- for ( ; x<20; x++ ) { SendClientMessage ( p, 0xFFFFFFFF, "" ); }
- return 1;
- }
- ocmd:veh(playerid,params[])
- {
- if(!isPlayerAnAdmin(playerid,5))return SendClientMessage(playerid,0xFF1400FF,"Du Hast Kein Adminrang[5].");
- new ModelID, color[2],Float:VehPos[4], vehicleid;
- if(GetPlayerState(playerid)!=PLAYER_STATE_ONFOOT) return SendClientMessage(playerid,0xB0AFB0FF,"Du bist nicht zu Fuss");
- if(sscanf(params, "ddd",ModelID,color[0],color[1])) return SendClientMessage(playerid,0xB0AFB0FF, "/veh [vehicleid] [color1] [color2]");
- if(ModelID < 400 || ModelID > 611) return SendClientMessage(playerid,0xB0AFB0FF, "Die Fahrzeug Id muss von 400 bis 611 sein");
- if(color[0] < 0 || color[0] > 126 || color[1] < 0 || color[1] > 126) return SendClientMessage(playerid,0xB0AFB0FF, "the colorid must be between 0 - 126");
- if(isPlayerAnAdmin(playerid,3) || CallRemoteFunction("PlayerIsAnAdmin","i",playerid))
- {
- GetPlayerPos(playerid, VehPos[0],VehPos[1],VehPos[2]);
- GetPlayerFacingAngle(playerid, VehPos[3]);
- vehicleid = CreateVehicle(ModelID,VehPos[0],VehPos[1],VehPos[2],VehPos[3],color[0],color[1],-1);
- LinkVehicleToInterior(vehicleid,GetPlayerInterior(playerid));
- SetVehicleVirtualWorld(vehicleid,GetPlayerVirtualWorld(playerid));
- PutPlayerInVehicle(playerid, vehicleid, 0);
- }
- return 1;
- }
- stock isPlayerAnAdmin(playerid,rang)
- {
- if(pInfo[playerid][Adminlevel]>=rang)return 1;
- return 0;
- }
- stock sscanf(sstring[], format[], {Float,_}:...)
- {
- #if defined isnull
- if (isnull(sstring))
- #else
- if (sstring[0] == 0 || (sstring[0] == 1 && sstring[1] == 0))
- #endif
- {
- return format[0];
- }
- #pragma tabsize 4
- new
- formatPos = 0,
- sstringPos = 0,
- paramPos = 2,
- paramCount = numargs(),
- delim = ' ';
- while (sstring[sstringPos] && sstring[sstringPos] <= ' ')
- {
- sstringPos++;
- }
- while (paramPos < paramCount && sstring[sstringPos])
- {
- switch (format[formatPos++])
- {
- case '\0':
- {
- return 0;
- }
- case 'i', 'd':
- {
- new
- neg = 1,
- num = 0,
- ch = sstring[sstringPos];
- if (ch == '-')
- {
- neg = -1;
- ch = sstring[++sstringPos];
- }
- do
- {
- sstringPos++;
- if ('0' <= ch <= '9')
- {
- num = (num * 10) + (ch - '0');
- }
- else
- {
- return -1;
- }
- }
- while ((ch = sstring[sstringPos]) > ' ' && ch != delim);
- setarg(paramPos, 0, num * neg);
- }
- case 'h', 'x':
- {
- new
- num = 0,
- ch = sstring[sstringPos];
- do
- {
- sstringPos++;
- switch (ch)
- {
- case 'x', 'X':
- {
- num = 0;
- continue;
- }
- case '0' .. '9':
- {
- num = (num << 4) | (ch - '0');
- }
- case 'a' .. 'f':
- {
- num = (num << 4) | (ch - ('a' - 10));
- }
- case 'A' .. 'F':
- {
- num = (num << 4) | (ch - ('A' - 10));
- }
- default:
- {
- return -1;
- }
- }
- }
- while ((ch = sstring[sstringPos]) > ' ' && ch != delim);
- setarg(paramPos, 0, num);
- }
- case 'c':
- {
- setarg(paramPos, 0, sstring[sstringPos++]);
- }
- case 'f':
- {
- new changestr[16], changepos = 0, strpos = sstringPos;
- while(changepos < 16 && sstring[strpos] && sstring[strpos] != delim)
- {
- changestr[changepos++] = sstring[strpos++];
- }
- changestr[changepos] = '\0';
- setarg(paramPos,0,_:floatstr(changestr));
- }
- case 'p':
- {
- delim = format[formatPos++];
- continue;
- }
- case '\'':
- {
- new
- end = formatPos - 1,
- ch;
- while ((ch = format[++end]) && ch != '\'') {}
- if (!ch)
- {
- return -1;
- }
- format[end] = '\0';
- if ((ch = strfind(sstring, format[formatPos], false, sstringPos)) == -1)
- {
- if (format[end + 1])
- {
- return -1;
- }
- return 0;
- }
- format[end] = '\'';
- sstringPos = ch + (end - formatPos);
- formatPos = end + 1;
- }
- case 'u':
- {
- new
- end = sstringPos - 1,
- id = 0,
- bool:num = true,
- ch;
- while ((ch = sstring[++end]) && ch != delim)
- {
- if (num)
- {
- if ('0' <= ch <= '9')
- {
- id = (id * 10) + (ch - '0');
- }
- else
- {
- num = false;
- }
- }
- }
- if (num && IsPlayerConnected(id))
- {
- setarg(paramPos, 0, id);
- }
- else
- {
- #if !defined foreach
- #define foreach(%1,%2) for (new %2 = 0; %2 < MAX_PLAYERS; %2++) if (IsPlayerConnected(%2))
- #define __SSCANF_FOREACH__
- #endif
- sstring[end] = '\0';
- num = false;
- new
- name[MAX_PLAYER_NAME];
- id = end - sstringPos;
- foreach (Player, playerid)
- {
- GetPlayerName(playerid, name, sizeof (name));
- if (!strcmp(name, sstring[sstringPos], true, id))
- {
- setarg(paramPos, 0, playerid);
- num = true;
- break;
- }
- }
- if (!num)
- {
- setarg(paramPos, 0, INVALID_PLAYER_ID);
- }
- sstring[end] = ch;
- #if defined __SSCANF_FOREACH__
- #undef foreach
- #undef __SSCANF_FOREACH__
- #endif
- }
- sstringPos = end;
- }
- case 's', 'z':
- {
- new
- i = 0,
- ch;
- if (format[formatPos])
- {
- while ((ch = sstring[sstringPos++]) && ch != delim)
- {
- setarg(paramPos, i++, ch);
- }
- if (!i)
- {
- return -1;
- }
- }
- else
- {
- while ((ch = sstring[sstringPos++]))
- {
- setarg(paramPos, i++, ch);
- }
- }
- sstringPos--;
- setarg(paramPos, i, '\0');
- }
- default:
- {
- continue;
- }
- }
- while (sstring[sstringPos] && sstring[sstringPos] != delim && sstring[sstringPos] > ' ')
- {
- sstringPos++;
- }
- while (sstring[sstringPos] && (sstring[sstringPos] == delim || sstring[sstringPos] <= ' '))
- {
- sstringPos++;
- }
- paramPos++;
- }
- do
- {
- if ((delim = format[formatPos++]) > ' ')
- {
- if (delim == '\'')
- {
- while ((delim = format[formatPos++]) && delim != '\'') {}
- }
- else if (delim != 'z')
- {
- return delim;
- }
- }
- }
- while (delim > ' ');
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement