Jump to content

AlbertWesker

Members
  • Posts

    21
  • Joined

  • Last visited

Everything posted by AlbertWesker

  1. Okay, i have done this but still no dual wield for the uzi or pistol or Sawn Off
  2. Okay Solidsnake can you help me with the part of the setPedStat as it is not alowing me to get the Dual Wield For the Uzi, pistol and Sawn Off Shotgun here is the Clients --- --- --- --- --- -- Created: 09/05/2012 00:59 addEventHandler("onClientResourceStart",resourceRoot, function() GUIEditor_Window = {} GUIEditor_Button = {} GUIEditor_Image = {} GUIEditor_Window[1] = guiCreateWindow(224,131,364,323,"Umbrella Corperation's Weapon Shop!",false) guiSetVisible(GUIEditor_Window[1], false) guiSetAlpha(GUIEditor_Window[1],1) GUIEditor_Window[2] = guiCreateWindow(0.25,0.35,0.5,0.2,"UPS!",true) button = guiCreateButton (0.35,0.6,0.3,0.2,"ok",true,GUIEditor_Window[2]) guiSetAlpha(GUIEditor_Window[2],1) label = guiCreateLabel (0.35,0.25,0.5,0.2,"Not enough money for that weapon",true,GUIEditor_Window[2]) guiSetVisible(GUIEditor_Window[2], false) GUIEditor_Button[1] = guiCreateButton(19,39,80,45,"Buy Dildo Large: $500000",false,GUIEditor_Window[1]) GUIEditor_Button[2] = guiCreateButton(144,37,80,45,"Buy Dildo Small: $250000",false,GUIEditor_Window[1]) GUIEditor_Button[3] = guiCreateButton(266,36,80,45,"Buy 50 RPG: $15000",false,GUIEditor_Window[1]) GUIEditor_Button[4] = guiCreateButton(145,119,79,50,"Buy 1000 Pistol Skill: $500000",false,GUIEditor_Window[1]) GUIEditor_Button[5] = guiCreateButton(266,120,85,51,"Buy 1000 Dual Uzi Skill: $1000000",false,GUIEditor_Window[1]) GUIEditor_Button[6] = guiCreateButton(17,120,79,50,"Buy 1000 SawnOff Skill: $750000",false,GUIEditor_Window[1]) GUIEditor_Image[1] = guiCreateStaticImage(14,196,88,73,"images/molotov.png",false,GUIEditor_Window[1]) GUIEditor_Button[7] = guiCreateButton(29,271,59,43,"Buy 5 Cocktales: $60000",false,GUIEditor_Window[1]) GUIEditor_Image[2] = guiCreateStaticImage(273,190,75,80,"images/minigun.png",false,GUIEditor_Window[1]) GUIEditor_Button[8] = guiCreateButton(280,271,70,43,"Buy 10000 Miniguns: $100000",false,GUIEditor_Window[1]) GUIEditor_Button[9] = guiCreateButton(114,200,145,99,"EXIT",false,GUIEditor_Window[1]) end ) addEventHandler("onClientGUIClick",getRootElement(), function (player) if (source == GUIEditor_Button[29]) then guiSetVisible (GUIEditor_Window[1],false) showCursor (false) elseif (source == GUIEditor_Button[9]) then guiSetVisible (GUIEditor_Window[1],false) showCursor (false) elseif (source == GUIEditor_Button[30]) then guiSetVisible (GUIEditor_Window[2],false) showCursor (false) elseif (source == GUIEditor_Button[1]) then money = getPlayerMoney (source) if (money >= 500000) then player = getLocalPlayer() outputChatBox ("You bought a Dildo Large! For: $500000",225,225,0) takePlayerMoney(500000) triggerServerEvent ("give10",getLocalPlayer(),give10) else guiSetVisible(GUIEditor_Window[2],true) guiSetVisible(GUIEditor_Window[1],false) end elseif (source == GUIEditor_Button[2]) then money = getPlayerMoney (source) if (money >= 250000) then player = getLocalPlayer() outputChatBox ("You bought a Dildo Small! For: $250000",225,225,0) takePlayerMoney(250000) triggerServerEvent ("give11",getLocalPlayer(),give11) else guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],true) end elseif (source == GUIEditor_Button[3]) then money = getPlayerMoney (source) if (money >= 150000) then player = getLocalPlayer() outputChatBox ("You bought a... Seriously?! Nice try Troll!! For: $150000",225,225,0) takePlayerMoney(150000) triggerServerEvent ("give15",getLocalPlayer(),give15) else guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],true) end elseif (source == GUIEditor_Button[8]) then money = getPlayerMoney (source) if (money >= 100000) then player = getLocalPlayer() outputChatBox ("You Nab You Shouldnt Be A Troll! For: $100000",225,225,0) takePlayerMoney(100000) triggerServerEvent ("give14",getLocalPlayer(),give15) else guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],true) end elseif (source == GUIEditor_Button[7]) then money = getPlayerMoney (source) if (money >= 60000) then player = getLocalPlayer() outputChatBox ("You bought 5 Cocktails! For: $60000",225,225,0) takePlayerMoney(60000) triggerServerEvent ("give18",getLocalPlayer(),give18) else guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],true) end elseif (source == GUIEditor_Button[5]) then money = getPlayerMoney (source) if (money >= 1000000) then outputChatBox ("You bought Dual Uzi Skill For: $1000000",225,225,0) takePlayerMoney(1000000) triggerServerEvent ("setPedStat75",getLocalPlayer()) -- you don't have to put the function as it is on the server-side and the event is attached to the function server side else guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],true) end elseif (source == GUIEditor_Button[4]) then money = getPlayerMoney (source) if (money >= 500000) then outputChatBox ("You bought Dual Pistol Skill For: $500000",225,225,0) takePlayerMoney(500000) triggerServerEvent ("setPedStat69",getLocalPlayer()) else guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],true) end elseif (source == GUIEditor_Button[6]) then money = getPlayerMoney (source) if (money >= 750000) then outputChatBox ("You bought Dual Sawn Off Skill For: $750000",225,225,0) takePlayerMoney(750000) triggerServerEvent ("setPedStat73",getLocalPlayer()) else guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],true) end elseif (source == button) then guiSetVisible(GUIEditor_Window[2],false) guiSetVisible(GUIEditor_Window[1],true) elseif (source == button) then guiSetVisible(GUIEditor_Window[2],false) guiSetVisible(GUIEditor_Window[1],true) end end ) function showGUI () guiSetVisible (GUIEditor_Window[1],true) showCursor (true) end addEvent ("showGUI",true) addEventHandler ("showGUI",getRootElement(),showGUI) --- --- --- --- --- Server: marker1 = createMarker (295.239,-37.58,1000.515,"cylinder",1.5,0,0,225,100) marker2 = createMarker (295.48,-80.38,1000.51,"cylinder",1.5,0,0,225,100) marker3 = createMarker (290.28,-109.35,1000.51,"cylinder",1.5,0,0,225,100) marker4 = createMarker (211.25,1858.46,12.10,"arrow",1.5,0,0,225,100) pedammusf = createPed (179,290.187,-111.514,1001.51) setElementInterior(pedammusf,6) setPedFrozen(pedammusf,true) pedammulv = createPed (179,295.47,-82.53,1001.51) setElementInterior (pedammulv,4) setElementInterior (marker2,4) setElementInterior (marker1,1) setElementInterior (marker3,6) function showGUI (jugador) if (source == marker1) then triggerClientEvent (jugador,"showGUI",getRootElement(),jugador) elseif (source == marker2) then triggerClientEvent (jugador,"showGUI",getRootElement(),jugador) elseif (source == marker3) then triggerClientEvent (jugador,"showGUI",getRootElement(),jugador) elseif (source == marker4) then triggerClientEvent (jugador,"showGUI",getRootElement(),jugador) end end addEventHandler ("onMarkerHit",getRootElement(),showGUI) function give10 () giveWeapon (source,10,1,true) end addEvent("give10",true) addEventHandler("give10",getRootElement(),give10) function give11 () giveWeapon (source,11,1,true) end addEvent("give11",true) addEventHandler("give11",getRootElement(),give11) function give15 () giveWeapon (source,15,1,true) end addEvent("give15",true) addEventHandler("give15",getRootElement(),give15) function give14 () setWeaponProperty (source,14,1,true) end addEvent("give14",true) addEventHandler("give14",getRootElement(),give14) function setPedStat75 () setPedStat (client,75,999,true) end addEvent("setPedStat75",true) addEventHandler("seTPedStat75",getRootElement(),setPedStat75) function setPedStat73 () setPedStat (client,73,999,true) end addEvent("setPedStat73",true) addEventHandler("setPedStat73",getRootElement(),setPedStat73) function setPedStat69 () setPedStat (source,69,999,true) end addEvent("setPedStat69",true) addEventHandler("setPedStat69",getRootElement(),setPedStat69) Btw this is kinda urgently needed now the parts with the skill stats i trye the setWeaponProperty Wayyy before i came here, but i didnt know how to set it out Please help! Thanks.
  3. the 3 weapons are Uzi,Pistol and SawnOff
  4. I tryed it, and nothing happend as i said befoe it takes your money finely but doesent give you your skill to acquire Dual wield
  5. Okay as you were probably expecting i am back, with the setPedStat Ability i am able to click and buy it in the GUI, but, i do not get me 999 stat to make the weapons dual here is the codes containing the setPedStat; function setPedStat75 () setPedStat (source,75,999,true) end addEvent("setPedStat75",true) addEventHandler("seTPedStat75",getRootElement(),setPedStat75) function setPedStat73 () setPedStat (source,73,999,true) end addEvent("setPedStat73",true) addEventHandler("setPedStat73",getRootElement(),setPedStat73) function setPedStat69 () setPedStat (source,69,999,true) end addEvent("setPedStat69",true) addEventHandler("setPedStat69",getRootElement(),setPedStat69) That is the server side now for the Client; elseif (source == GUIEditor_Button[5]) then money = getPlayerMoney (source) if (money >= 1000000) then player = getLocalPlayer() outputChatBox ("You bought Dual Uzi Skill For: $1000000",225,225,0) takePlayerMoney(1000000) triggerServerEvent ("setPedStat75",getLocalPlayer(),setPedStat75) else guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],true) end elseif (source == GUIEditor_Button[4]) then money = getPlayerMoney (source) if (money >= 500000) then player = getLocalPlayer() outputChatBox ("You bought Dual Pistol Skill For: $500000",225,225,0) takePlayerMoney(500000) triggerServerEvent ("setPedStat69",getLocalPlayer(),setPedStat69) else guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],true) end elseif (source == GUIEditor_Button[6]) then money = getPlayerMoney (source) if (money >= 750000) then player = getLocalPlayer() outputChatBox ("You bought Dual Sawn Off Skill For: $750000",225,225,0) takePlayerMoney(750000) triggerServerEvent ("setPedStat73",getLocalPlayer(),setPedStat73) else guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],true) end elseif (source == button) then guiSetVisible(GUIEditor_Window[2],false) guiSetVisible(GUIEditor_Window[1],true) elseif (source == button) then guiSetVisible(GUIEditor_Window[2],false) guiSetVisible(GUIEditor_Window[1],true) end end Sorry for being a pain but this si my first custom script i have been through the tutorials
  6. Yeah Solid, i used the wiki but couldnt see but thanks again you sure do help alot of people and thanks to all who gave there solutions!
  7. wait, there are Actual Stat ID's?
  8. SolidSnake i love you Thanks, but how do i set it for seperate weapons like?; setPedStat 26 1000? 26 Sawn Off...
  9. Okay all is good for now, But how do i sell Skills like SetUzISkill 1000 takePlayerMoney 750000? that is totally wrong but im learning
  10. okay the Buy Dildo Long Button doesent work it doesent sell the dildo it Exits the GUI
  11. Okay Progress is starting to gain, The Exit Button doesent do anything but the Buy Dildo Large button makes you Exit :L also, the Buy Cocktail button makes you buy a Night Vision and the Night Vision buttone makes you buy a Cocktail but the other 2 buttons are working, also when i get to the login window the both Gui windows pop up "Not Enough Cash" And the Actual shop EDIT i see the corrections now
  12. Ok when i start the Resource it poped up with part of the gui "You Do Not Have Enought For That Weapon" also wheni walk into the marker the window doesent show but the cursor appears Thanks though
  13. D: Nope Still wont show the GUI D:
  14. Thank you the Resource is loading, but when i go and Hitthemarker the GUI doesent appear :L
  15. Here is the client: --- --- --- --- --- -- Created: 09/05/2012 00:59 addEventHandler("onClientResourceStart",resourceRoot, function() GUIEditor_Window = {} GUIEditor_Button = {} GUIEditor_Image = {} GUIEditor_Window[1] = guiCreateWindow(224,131,364,323,"Umbrella Corperation's Weapon Shop!",true) guiSetAlpha(GUIEditor_Window[1],1) GUIEditor_Window[2] = guiCreateWindow(0.25,0.35,0.5,0.2,"UPS!",true) button = guiCreateButton (0.35,0.6,0.3,0.2,"ok",true,GUIEditor_Window[2]) guiSetAlpha(GUIEditor_Window[2],1) label = guiCreateLabel (0.35,0.25,0.5,0.2,"Not enough money for that weapon",true,GUIEditor_Window[2]) GUIEditor_Button[1] = guiCreateButton(19,39,80,45,"Buy Dildo Large: $500000",false,GUIEditor_Window[1]) GUIEditor_Button[2] = guiCreateButton(144,37,80,45,"Buy Dildo Small: $250000",false,GUIEditor_Window[1]) GUIEditor_Button[3] = guiCreateButton(266,36,80,45,"Buy Viberator: $150000",false,GUIEditor_Window[1]) GUIEditor_Button[4] = guiCreateButton(145,119,79,50,"Buy 1000 Pistol Skill: $500000",false,GUIEditor_Window[1]) GUIEditor_Button[5] = guiCreateButton(266,120,85,51,"Buy 1000 Dual Uzi Skill: $1500000",false,GUIEditor_Window[1]) GUIEditor_Button[6] = guiCreateButton(17,120,79,50,"Buy 1000 SawnOff Skill: $750000",false,GUIEditor_Window[1]) GUIEditor_Image[1] = guiCreateStaticImage(14,196,88,73,"images/molotov.png",false,GUIEditor_Window[1]) GUIEditor_Button[7] = guiCreateButton(29,271,59,43,"Buy 5 Cocktales: $60000",false,GUIEditor_Window[1]) GUIEditor_Image[2] = guiCreateStaticImage(273,190,75,80,"images/night.png",false,GUIEditor_Window[1]) GUIEditor_Button[8] = guiCreateButton(280,271,70,43,"Buy 1 Night Vision: $100000",false,GUIEditor_Window[1]) GUIEditor_Button[9] = guiCreateButton(114,200,145,99,"EXIT",false,GUIEditor_Window[1]) end ) addEventHandler("onClientGUIClick",getRootElement(), function (player) if (source == GUIEditor_Button[29]) then guiSetVisible (GUIEditor_Window[1],false) showCursor (false) if (source == GUIEditor_Button[1]) then guiSetVisible (GUIEditor_Window[1],false) showCursor (false) elseif (source == GUIEditor_Button[30]) then guiSetVisible (GUIEditor_Window[2],false) showCursor (false) elseif (source == GUIEditor_Button[1]) then money = getPlayerMoney (source) if (money >= 500000) then player = getLocalPlayer() outputChatBox ("You bought a Dildo Large! For: $500000",225,225,0) takePlayerMoney(500000) triggerServerEvent ("give10",getLocalPlayer(),give10) else guiSetVisible(GUIEditor_Window[2],true) guiSetVisible(GUIEditor_Window[1],false) end elseif (source == GUIEditor_Button[2]) then money = getPlayerMoney (source) if (money >= 250000) then player = getLocalPlayer() outputChatBox ("You bought a Dildo Small! For: $250000",225,225,0) takePlayerMoney(250000) triggerServerEvent ("give11",getLocalPlayer(),give11) else guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],true) end elseif (source == GUIEditor_Button[3]) then money = getPlayerMoney (source) if (money >= 150000) then player = getLocalPlayer() outputChatBox ("You bought a Viberater! For: $150000",225,225,0) takePlayerMoney(150000) triggerServerEvent ("give12",getLocalPlayer(),give12) else guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],true) end elseif (source == GUIEditor_Button[7]) then money = getPlayerMoney (source) if (money >= 100000) then player = getLocalPlayer() outputChatBox ("You bought Night Vision! For: $100000",225,225,0) takePlayerMoney(100000) triggerServerEvent ("give44",getLocalPlayer(),give44) else guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],true) end elseif (source == GUIEditor_Button[8]) then money = getPlayerMoney (source) if (money >= 60000) then player = getLocalPlayer() outputChatBox ("You bought 5 Cocktails! For: $60000",225,225,0) takePlayerMoney(60000) triggerServerEvent ("give18",getLocalPlayer(),give18) else guiSetVisible(GUIEditor_Window[1],false) guiSetVisible(GUIEditor_Window[2],true) end elseif (source == button) then guiSetVisible(GUIEditor_Window[2],false) guiSetVisible(GUIEditor_Window[1],true) end end function showGUI () guiSetVisible (GUIEditor_Window[1],true) showCursor (true) end addEvent ("showGUI",true) addEventHandler ("showGUI",getRootElement(),showGUI) --- --- --- --- --- Now For the Server marker1 = createMarker (295.239,-37.58,1000.515,"cylinder",1.5,0,0,225,100) marker2 = createMarker (295.48,-80.38,1000.51,"cylinder",1.5,0,0,225,100) marker3 = createMarker (290.28,-109.35,1000.51,"cylinder",1.5,0,0,225,100) marker4 = createMarker (211.25,1858.46,12.10,"arrow",1.5,0,0,225,100) pedammusf = createPed (179,290.187,-111.514,1001.51) setElementInterior(pedammusf,6) setPedFrozen(pedammusf,true) pedammulv = createPed (179,295.47,-82.53,1001.51) setElementInterior (pedammulv,4) setElementInterior (marker2,4) setElementInterior (marker1,1) setElementInterior (marker3,6) function showGUI (jugador) if (source == marker1) then triggerClientEvent (jugador,"showGUI",getRootElement(),jugador) elseif (source == marker2) then triggerClientEvent (jugador,"showGUI",getRootElement(),jugador) elseif (source == marker3) then triggerClientEvent (jugador,"showGUI",getRootElement(),jugador) elseif (source == marker4) then triggerClientEvent (jugador,"showGUI",getRootElement(),jugador) end end addEventHandler ("onMarkerHit",getRootElement(),showGUI) function give10 () giveWeapon (source,10,1,true) end addEvent("give10",true) addEventHandler("give10",getRootElement(),give10) function give11 () giveWeapon (source,11,1,true) end addEvent("give11",true) addEventHandler("give11",getRootElement(),give11) function givedeagle () giveWeapon (source,12,1,true) end addEvent("give12",true) addEventHandler("give12",getRootElement(),give12) function give44 () setWeaponProperty (source,44,1,true) end addEvent("give44",true) addEventHandler("give44",getRootElement(),give44) function give18 () giveWeapon (source,18,5,true) end addEvent("give18",true) addEventHandler("give18",getRootElement(),give18) If the Meta Helps here is that too! meta> <info author="Albert" name="MyScript" version="1.0.0" type="script"/> <script src="Script2.lua" type="server"/> <script src="Script1.lua" type="client"/> </meta> Now for the explanation; I am getting an error on the console saying "WARNING: Not Loading Resource "MyScript" As It Contains Illegal Characters!" this usually happens to like map files and stuff but they give another message, this one doesn't ... i have looked over this many times and i cant see a problem also this is my first script well, copyed alot but it was mixed about and added my own modifications to it! if you guys could help i would be pleased
  16. -- Advanced Anti Zombie Script Created By volk-rus ( Kenix ) version 1.0.4 -- colShape x coordinate, y coordinate, radius -- RadarArea x coordinate, y coordinate ,size 1, size 2, color: red,green,blue,alpha. ---- you need to change the fact that less then that now there is an example local savePlaces = { {328, 2059, 92, 1783}, {91, 1789, 395, 2087} } -- more colshapes local radarAreaPlaces = { {328, 2059, 10,10,0,30,255,150}, {91, 1789, 300,300,0,30,255,150} } -- more radar areas From the top of this code i can see guide sort of lines, theses "-- colShape x coordinate, y coordinate, radius " but the "Radius" part is the part im having problems with this will be simple to all you people but i am a newb that is starting to understand scripting if someone could copy the Coords of the Colshape and the radar area and then tell me how i could find the radius i would most certainly be greatful! but first ill tell you what i have tried, the radius at the moment is an X and Y Coord and it doesn't seem to work, all the Zombies die literly miles from Area 69 and i dont want them too, i only want them to die in area 69, when they enter it or when they spawn they will die!, the other ways in the very begining was that i was guessing the radius and you know your self, it went wrong! so please if you could help me that will be great! in the mean time ill work on a challenge to try and make my own custom script :3
  17. Guys i have went over most of this... i understand it but what i am tying to make i instantly go to a blank
  18. Ok thanks guys, but can you atleast help me with the Priate Spawn bit? that is kinda desperate
  19. Ok, i am a total and utter Noob that has very high interests in lua Scripting!!! so i need some help from the pro's with a couple of scripts, firslty, this link: https://community.multitheftauto.com/index.php?p= ... ls&id=1152 Leads to the almighty 50p's Spawn menu Resource, its a great resource!!! but i need help with making some of the spawns set to private, like so the public default ACL Group cant access without being on a list of who can!. Next is a script for vehicles to be set to a private ACL Group! so it doesent go by skin! Thanks. P.S. 50p I admire your work aswell as Flaker7 and Castillo!
×
×
  • Create New...