Jump to content

thegost

Members
  • Posts

    43
  • Joined

  • Last visited

Everything posted by thegost

  1. Not Have erros... You need All script? the Spawn?
  2. Hello people , In my Spawn Menu I add respawn System, But not work if you die you watch the Spawn Menu And I put to watch in first menu with 2 option option 1 spawn screen and option 2 respawn in hospital but this menu not work I cant see. And in debugscript 3 not have erros I dont understane... can help me? Client: --My Add function showSpawnScreen() if not spawnWindow then drawSpawnScreen() end setElementInterior(localPlayer,0) setElementDimension(localPlayer,0) setSpawnCamera() setTimer(function () fadeCamera(true) guiSetVisible(spawnWindow,true) guiSetVisible(infoMemo,true) guiSetVisible(locationGridList,false) guiGridListSetSelectedItem(classGridList,-1,0) showCursor(true) end,2000,1) end ------ function deathMode() if deathscreen then deathscreen = guiCreateWindow(0.3,0.8,0.4,0.2,SPAWN SCRREN",true) guiWindowSetSizable(deathscreen,false) death_hospital = guiCreateButton(0.0332,0.5463,0.4688,0.3659,"Hospital (1000$) \n You'll keep your weapons",true,deathscreen) death_spawn = guiCreateButton(0.5156,0.5463,0.4531,0.3659,"SPAWNSCREEN",true,deathscreen) deathbar = guiCreateProgressBar(0.0391,0.2732,0.9121,0.1902,true,deathscreen) deathlabel = guiCreateLabel(0.1094,0.1415,0.7754,0.1073,"... WAITING FOR REANIMATION ...",true,deathscreen) guiLabelSetVerticalAlign(deathlabel,"center") guiLabelSetHorizontalAlign(deathlabel,"center",false) addEventHandler("onClientGUIClick",death_hospital,spawnAtHospital) addEventHandler("onClientGUIClick",death_spawn,normalSpawnWindow) end guiProgressBarSetProgress(deathbar,100) guiSetVisible(deathscreen, true) showCursor(true) fadeCamera(true) deathTimer = setTimer(countUntilDeath, 1000, 1, 50) end addEvent("spawnhotpital.showDeathScreen",true) addEventHandler("spawnhotpital.showDeathScreen",localPlayer,deathMode) function countUntilDeath(time) if getElementData(getLocalPlayer(),"reanimation") then reanimatePlayer() setElementData(getLocalPlayer(),"reanimationtime",false) deathTimer = nil else if time > 0 then time = time -1 guiProgressBarSetProgress(deathbar,time * 2) deathTimer = setTimer(countUntilDeath, 1000, 1, time) else setElementData(getLocalPlayer(),"reanimationtime",false) deathTimer = nil normalSpawnWindow() end end end function normalSpawnWindow() if deathTimer then killTimer(deathTimer) deathTimer = nil end guiSetVisible(deathscreen, false) setElementData(getLocalPlayer(), "class", "N/A") showSpawnScreen() tempweapons = {} end function spawnAtHospital() if source == death_hospital then if ((getTeamName(getPlayerTeam(getLocalPlayer())) == "Criminals")or(getTeamName(getPlayerTeam(getLocalPlayer())) == "RvB Blue")) then triggerEvent("newMessage",root,nil,getLocalPlayer(),"*HELP* You can't use hospital while using RvB teams","call",255, 100, 50) return end if getPlayerMoney(getLocalPlayer()) >= 1000 then if deathTimer then killTimer(deathTimer) deathTimer = nil end guiSetVisible(deathscreen, false) showCursor(false) triggerServerEvent("SPAWNATHOSIPTAL", getLocalPlayer(), tempweapons) tempweapons = {} exports.RPGcommands:takeMoney(getLocalPlayer(),1000) else outputChatBox("You need 1000$ to spawn at a Hospital", 255, 100, 0) end end end function reanimatePlayer() local Dim = getElementDimension(getLocalPlayer()) local Int = getElementInterior(getLocalPlayer()) if deathTimer then killTimer(deathTimer) deathTimer = nil end guiSetVisible(deathscreen, false) showCursor(false) triggerServerEvent("REANIMATEPLAYER", getLocalPlayer(), tempweapons, Dim, Int) tempweapons = {} end function weaponsAfterDeath() if source == getLocalPlayer() then tempweapons = {} local weaponSlots = {0,1,2,3,4,5,6,7,8,9,10,11,12} for i, slot in ipairs(weaponSlots) do local ammo = getPedTotalAmmo ( getLocalPlayer(), slot ) if ( getPedWeapon ( getLocalPlayer(), slot ) ~= 0 ) then local weapon = getPedWeapon ( getLocalPlayer(), slot ) local ammo = getPedTotalAmmo ( getLocalPlayer(), slot ) table.insert(tempweapons, {weapon, ammo}) end end end end addEventHandler("onClientPlayerWasted", getRootElement(), weaponsAfterDeath) function waterCheck() if isElementInWater(localPlayer) then local px,py,pz = getElementPosition(localPlayer) local wx,wy,wz = getWaterLevel(x,y,z) setElementPostion(localPlayer,px,py,wz+3) end end addEventHandler("onClientPlayerSpawn",root,waterCheck) Server: function onPlayerWastedHandler(ammo,attacker,weapon,bodypart,stealth) if getElementData(source,"id") then fadeCamera(source,false) triggerClientEvent(source,"spawnhotpital.showDeathScreen",source) setElementData(source,"reanimation",false) setElementData(source,"reanimationtime",true) end local blips = getAttachedElements(source) if blips then for k,v in ipairs(blips) do if isElement(v) and getElementType(v) == "blip" then destroyElement(v) end end end end addEventHandler("onPlayerWasted",root,onPlayerWastedHandler) --- Hospital = { -- {x,y,z,rot} {2033,-1404,17.3,180}, {1173,-1323.6,15.4,270}, {-2656,636,14.5,180}, {-1514.6,2521.8,55.9,0}, {-320,1055,19.8,0}, {1607.4,1817.4,10.9,0}, {-2200.7,-2312.4,30.7,0} } function findNearestHospital(player) distanceToHospital = 9999999999 local wastedX, wastedY, wastedZ = getElementPosition(player) for k, v in ipairs(Hospital) do local loopX,loopY,loopZ,loopRot = v[1],v[2],v[3],v[4] newDistance = getDistanceBetweenPoints3D(wastedX,wastedY,wastedZ,loopX,loopY,loopZ) if newDistance < distanceToHospital then distanceToHospital = newDistance hospitalX = loopX hospitalY = loopY hospitalZ = loopZ hospitalRot = loopRot end end return hospitalX, hospitalY, hospitalZ, hospitalRot end function spawnPlayerAtHospital(savedWeapons) local skin = getPedSkin(source) local team = getPlayerTeam(source) local r, g, b = getPlayerNametagColor(source) local posX,posY,posZ,posRot = findNearestHospital(source) createBlipAttachedTo(source, 0, 2, r, g, b, 255, 0, 400) setPlayerNametagColor(source, r, g, b) spawnPlayer (source, posX, posY, posZ, posRot, skin, 0, 0, team) for i, t in ipairs(savedWeapons) do giveWeapon(source, t[1], t[2]) end fadeCamera(source,true) setCameraTarget(source,source) end addEvent("SPAWNATHOSIPTAL",true) addEventHandler("SPAWNATHOSIPTAL",root,spawnPlayerAtHospital) function reanimatePlayer(savedWeapons, dimP, intP) setElementData(source, "reanimation", false) setElementData(source, "time", false) local skin = getPedSkin(source) local team = getPlayerTeam(source) local r, g, b = getPlayerNametagColor(source) local posX, posY, posZ = getElementPosition(source) createBlipAttachedTo(source, 0, 2, r, g, b, 255, 0, 400) setPlayerNametagColor(source, r, g, b) spawnPlayer (source, posX, posY, posZ, 0, skin, 0, 0, team) setElementInterior(source, intP) setElementDimension(source, dimP) setElementHealth(source, 30) for i, t in ipairs(savedWeapons) do giveWeapon(source, t[1], t[2]) end fadeCamera(source,true) setCameraTarget(source,source) end addEvent("REANIMATEPLAYER",true) addEventHandler("REANIMATEPLAYER",root,reanimatePlayer) function resetCache(source,cmd,id) if not exports.SANGacl:isPlayerInGroup(source,"Admin") or not id then return end if spawnCache[id] then spawnCache[id] = nil exports.RPGcommands:sendMessage("*INFO* Cache deleted.",0,255,0,source) else exports.RPGcommands:sendMessage("*INFO* Cache does not exist.",255,0,0,source) end end addCommandHandler("resetcache",resetCache) function getID(source,cmd,account) if not exports.SANGacl:isPlayerInGroup(source,"Admin") or not account then return end local query = executeSQLQuery("SELECT id FROM user_data WHERE username = '"..account.."' LIMIT 1") if query and query[1] then exports.RPGcommands:sendMessage("*INFO* The ID for the account \'"..account.."\' is "..tostring(query[1].id)..".",0,255,0,source) else exports.RPGcommands:sendMessage("*INFO* Unable to find account.",0,255,0,source) end end addCommandHandler("getid",getID)
  3. thegost

    WareHouse

    You understane i say?
  4. thegost

    WareHouse

    +/- the Warehouse not need comand its automatic in finish the Hr and i have this hr locate: houserob = {} houserob[1] = {562.69909667969,-1814.8981933594,6.1234374046326} -- Santa maria Breach houserob[2] = {2350.9162597656,-2172.7534179688,13.546875} -- Oceane Doks ,Ls houserob[3] = {2504.5856933594,-1781.0590820313,13.638743400574} -- teaton Doks(ao Pe da casa do Big Smoke), Ls houserob[4] = {2348.9296875,-2007.6644287109,13.62343788147} -- willwolueldfield(ao Pe do spawn de armes dealer), Ls houserob[5] = {1794.7677001953,-1928.93359375,13.42343711853} -- Estaçao dos autocarros, Ls houserob[6] = {603.32775878906,-1188.4716796875,49.504688262939} -- Sr in Ls House houserob[7] = {1377.6688232422,-450.14120483398,52.430519104004} -- Sr in Ls Montain houserob[8] = {1341.7897949219,196.16741943359,19.723438262939} -- Red Country houserob[9] = {2418.6962890625,91.955596923828,26.493436813354} -- Red Country houserob[10] = {2177.5703125,102.99882507324,26.363447189331} -- Red Country houserob[11] = {250.4478302002,-57.158576965332,1.5703125} -- Red Country houserob[12] = {-2395.6291503906,-2178.9738769531,33.323436737061} -- Bone Country Monatai houserob[13] = {-2005.9456787109,-733.89862060547,32.223438262939} -- Foster Vally , San Fierro houserob[14] = {-2720.0549316406,448.5451965332,4.3334374427795} -- Armes dealer Spawn , San Fierro houserob[15] = {-2464.8759765625,2233.2077636719,4.8334374427795} -- Tierra ROubada houserob[16] = {-1530.1484375,2636.9428710938,55.8359375} -- El Quebrados houserob[17] = {-657.45465087891,2711.822265625,72.375} -- Tierra Roubada houserob[18] = {-225.64117431641,2733.6147460938,62.723438262939} -- Bone Country houserob[19] = {-882.78973388672,1491.119140625,24.323436737061} -- Tierra roubada los quebrados houserob[20] = {-171.1417388916,1225.7291259766,19.7421875} -- Bone Country Biker Spawn houserob[21] = {599.77520751953,1229.6207275391,11.723437309265} -- Bone Country FInal Farmer houserob[22] = {1431.6755371094,2689.7751464844,11.223437309265} -- Lv em cima houserob[23] = {2775.37109375,1452.2525634766,10.823437690735} -- Lv Perto dos Un houserob[24] = {2568.7614746094,1033.0362548828,10.823437690735} -- Lv Perto dos Down houserob[25] = {1941.3050537109,-1810.6721191406,13.62343788147} -- ls AO pe das bombas
  5. thegost

    WareHouse

    Now Its more Clear or not understane?
  6. thegost

    WareHouse

    I like but warehouse restrit areas All lv robs! have warehouse in lv and all sf robs have warehouse in sf and all robs in ls have warehouse in ls! type ware hous in ls have one locate and all stores have +/- 500M the distace this warehouse have with finish rob in this warehouse
  7. thegost

    WareHouse

    Good Morning People I need help! in warehouse in finish the assalt , i have math.random(#warehouse) but i want put the warehouse to distance think you in lv area assalt and assalt finish i like put the warehouse in lv and sf assalts ware house sf and ls assalts and warehouse, and this i have its math random you in lv assalt you go sf.... warehouse can help me? warehouse = {} warehouse[1] = {2872.1005859375,-2124.9311523438,4.6315641403198} --LS warehouse[2] = {-1885.1981201172,-201.48069763184,15.597852706909} --SF warehouse[3] = {2140.6916503906,2835.0744628906,10.8203125} --LV addEvent("showWarehouses", true) addEventHandler("showWarehouses", getRootElement(), function() if source == getLocalPlayer() then local index = math.random(#warehouse) local marker = createMarker(warehouse[index][1],warehouse[index][2],warehouse[index][3]-1,"cylinder", 3, 255, 255, 255, 255) setElementData(marker, "houserobblip", true) local blip = createBlipAttachedTo(marker, 43) setElementData(blip, "houserobblip", true) addEventHandler("onClientMarkerHit", marker, finish) end end)
  8. Hey People I wanted to help my script I got put to see people who are in Sr within the market but and everything but I wanted to was to see people who are spawn in criminal and also to see how many who are spawn in police to see how many so it also if can help me would greatly and was so for example : Player In Rob : 5 Crimians Vs Cops 2 robberTeams = { ["Criminals"] = true,["Liberation Organisation"] = true,["The Devils Of Darkness"] = true, ["Official Gangs"] = true, ["Admin"] = true} robberTeams2 = { ["Criminals"] = true,["Liberation Organisation"] = true,["The Devils Of Darkness"] = true, ["Official Gangs"] = true, ["Admin"] = true} resX, resY = guiGetScreenSize() resX2 = resX*(1/3) function startHRDisplay(hrthing) if hrthing and tonumber(getElementData(hrthing, "percent")) then houserobMarker = hrthing addEventHandler("onClientRender", root, displayHR) end end function stopHRDisplay() houserobMarker = false removeEventHandler("onClientRender", root, displayHR) end local width,height = guiGetScreenSize() addEventHandler("onClientRender", getRootElement(), function() if houserob == 1 then if isElement(houserobMarker) and isElementWithinMarker(getLocalPlayer(), houserobMarker) then local percent = getElementData(houserobMarker, "percent") dxDrawRectangle(10,(height/2)-10, 200, 20, tocolor(255,255,255,255)) dxDrawRectangle(10,(height/2)-10, percent*2, 20, tocolor(255,100,100,255)) local text = "Houserob done: "..percent.." %" local textwidth = dxGetTextWidth(text, 0.6, "bankgothic") dxDrawText(text,10,(height/2)-40, textwidth, 20,tocolor(255,255,255,255),0.6,"bankgothic" ) local checkk = getPlayersInMarker(houserobMarker) dxDrawText("Player In Rob: '" .. checkk .. "'",resX2-450,300,resX2*2.7,600,tocolor(255,255,255,255),0.8,"bankgothic","left","center",true,true,false) else houserob = nil houserobMarker = nil end end end) function getPlayersInMarker(houserobMarker) local players = 0 if houserobMarker and getElementType(houserobMarker) == "marker" then for i,player in ipairs(getElementsByType("player")) do if isElementWithinMarker(player,houserobMarker) then players = players + 1 end end end return players end addEventHandler("onClientPlayerWasted", getLocalPlayer(), function() houserob = nil hideALL() end) addEvent("showProcess", true) addEventHandler("showProcess", getRootElement(), function(robber, housemarker) if robber == getLocalPlayer() then houserob = 1 houserobMarker = housemarker end end) addEvent("hideProcess", true) addEventHandler("hideProcess", getRootElement(), function(robber) if robber == getLocalPlayer() then houserob = nil houserobMarker = nil end end)
  9. thegost

    Delete

    Can Help me?
  10. thegost

    Delete

    Delete this
  11. what I meant was , the official gangs when rob the bank the money from the robbery so goes the officiais they did to others so that everyone in the bank will not receive any , criminal and other officiais Sorry my bad english
  12. Hello Guys I have problem in my BR script!. In Br The Official Gang Start Br Open Doors ... and in zone take money , the people in gang create Br Take Money But the people in Br Criminals and other offiical Gangs not take money! The Money Take All to the people in The Gang Rob Bank The Others not take can help me ?? in put all can take money? SFbankrobLevel = 0 -- you must be a trusted gang with a level of "number" to start robbing ( /rm for admins) numberOfPolice = 0 -- PLAYERS THAT HAVE TO BE IN THE POLICETEAM or you cant start hack the doors criminalTeams = { ["Official Gangs"] = true,["Criminals"] = true} cs1 = createColRectangle(350, 370, 90, 60 ) setElementInterior(cs1, 3) setElementDimension(cs1, 2) function SFrespawnOutside() local players = getElementsByType("player") for i, getOut in pairs (players) do if getElementDimension(getOut) == 2 and getElementInterior(getOut) == 3 and isElementWithinColShape(getOut, cs1) then local x, y, z = getElementPosition(getOut) if z >= 969 and z <= 982 then local x = math.random(400,400.5) local y = math.random(384,384.5) setElementPosition(getOut, x, y, 981.6) exports.RPGcommands:sendMessage("*San FierroBank Robbery Reset*", 200,0,0, getOut) triggerClientEvent("closeKeyPad", getRootElement(), getOut) end end end end function SFstartBankrob() SFplayerName1 = nil SFbanktimer = nil SFbanktimer1 = nil SFgang = "" if SFDoor1 then destroyElement(SFDoor1) SFDoor1 = nil end if SFDoor2 then destroyElement(SFDoor2) SFDoor2 = nil end if SFDoor3 then destroyElement(SFDoor3) SFDoor3 = nil end if SFmarkerDoor1 then destroyElement(SFmarkerDoor1) SFmarkerDoor1 = nil end if SFmarkerDoor2 then destroyElement(SFmarkerDoor2) SFmarkerDoor2 = nil end if SFmarkerDoor3 then destroyElement(SFmarkerDoor3) SFmarkerDoor3 = nil end if SFmarkerSafe1 then destroyElement(SFmarkerSafe1) SFmarkerSafe1 = nil end if SFmarkerSafe2 then destroyElement(SFmarkerSafe2) SFmarkerSafe2 = nil end if SFmarkerSafe3 then destroyElement(SFmarkerSafe3) SFmarkerSafe3 = nil end if SFmarkerSafe4 then destroyElement(SFmarkerSafe4) SFmarkerSafe4 = nil end if SFmarkerSafe5 then destroyElement(SFmarkerSafe4) SFmarkerSafe5 = nil end if SFmarkerSafe6 then destroyElement(SFmarkerSafe4) SFmarkerSafe6 = nil end if SFmarkerSafe7 then destroyElement(SFmarkerSafe4) SFmarkerSafe7 = nil end if SFmarkerSafe8 then destroyElement(SFmarkerSafe4) SFmarkerSafe8 = nil end SFDoor1 = createObject(2634, 401, 380.6, 982, 0, 0, 0) setElementInterior(SFDoor1, 3) setElementDimension(SFDoor1, 2) SFDoor2 = createObject(2634, 364.5, 350.70001, 975.70001, 0, 0, 270) setElementInterior(SFDoor2, 3) setElementDimension(SFDoor2, 2) SFDoor3 = createObject(2634, 382.29999, 371.5, 969.59998, 0, 0, 90) setElementInterior(SFDoor3, 3) setElementDimension(SFDoor3, 2) SFrespawnOutside() end function SFstartBankrob2() SFsecurity1 = 0 SFsecurity2 = 0 SFsecurity3 = 0 SFsecurity4 = 0 SFsecurity5 = 0 SFsecurity6 = 0 SFsecurity7 = 0 SFsecurity8 = 0 SFgang = "" outputDebugString("new bankrob approved at SAN FIERRO") if SFmarkerDoor1 then destroyElement(SFmarkerDoor1) SFmarkerDoor1 = nil end if SFmarkerDoor2 then destroyElement(SFmarkerDoor2) SFmarkerDoor2 = nil end if SFmarkerDoor3 then destroyElement(SFmarkerDoor3) SFmarkerDoor3 = nil end if SFmarkerSafe1 then destroyElement(SFmarkerSafe1) SFmarkerSafe1 = nil end if SFmarkerSafe2 then destroyElement(SFmarkerSafe2) SFmarkerSafe2 = nil end if SFmarkerSafe3 then destroyElement(SFmarkerSafe3) SFmarkerSafe3 = nil end if SFmarkerSafe4 then destroyElement(SFmarkerSafe4) SFmarkerSafe4 = nil end if SFmarkerSafe5 then destroyElement(SFmarkerSafe4) SFmarkerSafe4 = nil end if SFmarkerSafe6 then destroyElement(SFmarkerSafe4) SFmarkerSafe4 = nil end if SFmarkerSafe7 then destroyElement(SFmarkerSafe4) SFmarkerSafe4 = nil end if SFmarkerSafe8 then destroyElement(SFmarkerSafe4) SFmarkerSafe4 = nil end SFmarkerDoor1 = createMarker(402.02828979492, 381.04418182373,982.73931884766, "arrow", 0.7, 0, 162, 232, 200) setElementInterior(SFmarkerDoor1, 3) setElementDimension(SFmarkerDoor1, 2) SFmarkerDoor2 = createMarker(366.6608581543,350.06567382813,976, "arrow", 0.7, 0, 162, 232, 200) setElementInterior(SFmarkerDoor2, 3) setElementDimension(SFmarkerDoor2, 2) SFmarkerDoor3 = createMarker(380.62088012695,399.0364685058,969.6, "arrow", 0.7, 0, 162, 232, 200) setElementInterior(SFmarkerDoor3, 3) setElementDimension(SFmarkerDoor3, 2) SFmarkerSafe1 = createMarker(393.3, 409, 969.6, "arrow", 0.8, 0, 162, 232, 200) setElementInterior(SFmarkerSafe1, 3) setElementDimension(SFmarkerSafe1, 2) SFmarkerSafe2 = createMarker(393.3, 412.69999694824, 969.6, "arrow", 0.8, 0, 162, 232, 200) setElementInterior(SFmarkerSafe2, 3) setElementDimension(SFmarkerSafe2, 2) SFmarkerSafe3 = createMarker(399.29998779297, 412.5, 969.59997558594, "arrow", 0.8, 0, 162, 232, 200) setElementInterior(SFmarkerSafe3, 3) setElementDimension(SFmarkerSafe3, 2) SFmarkerSafe4 = createMarker(393.3, 417, 969.6, "arrow", 0.8, 0, 162, 232, 200) setElementInterior(SFmarkerSafe4, 3) setElementDimension(SFmarkerSafe4, 2) SFmarkerSafe5 = createMarker(393.3, 405.4, 969.6, "arrow", 0.8, 0, 162, 232, 200) setElementInterior(SFmarkerSafe5, 3) setElementDimension(SFmarkerSafe5, 2) SFmarkerSafe6 = createMarker(399.29998779297, 417, 969.6, "arrow", 0.8, 0, 162, 232, 200) setElementInterior(SFmarkerSafe6, 3) setElementDimension(SFmarkerSafe6, 2) SFmarkerSafe7 = createMarker(399.29998779297, 409, 969.6, "arrow", 0.8, 0, 162, 232, 200) setElementInterior(SFmarkerSafe7, 3) setElementDimension(SFmarkerSafe7, 2) SFmarkerSafe8 = createMarker(399.29998779297, 405.4, 969.6, "arrow", 0.8, 0, 162, 232, 200) setElementInterior(SFmarkerSafe8, 3) setElementDimension(SFmarkerSafe8, 2) addEventHandler("onMarkerHit", SFmarkerDoor1, SFbankDoorGUI) addEventHandler("onMarkerHit", SFmarkerDoor2, SFbankDoorGUI) addEventHandler("onMarkerHit", SFmarkerDoor3, SFbankDoorGUI) addEventHandler("onMarkerHit", SFmarkerSafe1, SFbankDoorGUI) addEventHandler("onMarkerHit", SFmarkerSafe2, SFbankDoorGUI) addEventHandler("onMarkerHit", SFmarkerSafe3, SFbankDoorGUI) addEventHandler("onMarkerHit", SFmarkerSafe4, SFbankDoorGUI) addEventHandler("onMarkerHit", SFmarkerSafe5, SFbankDoorGUI) addEventHandler("onMarkerHit", SFmarkerSafe6, SFbankDoorGUI) addEventHandler("onMarkerHit", SFmarkerSafe7, SFbankDoorGUI) addEventHandler("onMarkerHit", SFmarkerSafe8, SFbankDoorGUI) SFrespawnOutside() end function SFbankDoorGUI(hitElement, matchingDimension) if getElementType(hitElement) == "player" and matchingDimension then if criminalTeams[getTeamName(getPlayerTeam(hitElement))] then if countPlayersInTeam(getTeamFromName("Police")) + countPlayersInTeam(getTeamFromName("Official Squads")) >= numberOfPolice then if source == SFmarkerDoor1 and SFsecurity1 ~= 1 then if criminalTeams[getTeamName(getPlayerTeam(hitElement))] then if SFdisable ~= 1 then local wl = exports.ITWpolice:getWantedLevel(hitElement) local wl = wl + 5 if wl > 36 then wl = 36 end exports.ITWpolice:setWantedLevel(hitElement, wl) triggerClientEvent("MARKERDOOR", getRootElement(), hitElement, "Door1") else outputChatBox("robbing is disabled currently, come back later.", hitElement) end else outputChatBox("Only 'trusted' gangs may rob a bank", hitElement, 200,0,0) end end if source == SFmarkerDoor2 and SFsecurity2 ~= 1 then if SFgang == getElementData(hitElement, "gang") then --if SFplayerName1 ~= getPlayerName(hitElement) then local wl = exports.ITWpolice:getWantedLevel(hitElement) local wl = wl + 5 if wl > 36 then wl = 36 end exports.ITWpolice:setWantedLevel(hitElement, wl) triggerClientEvent("MARKERDOOR", getRootElement(), hitElement, "Door2") --else --outputChatBox("You may not disable this System! Search for a second Player!", hitElement, 255, 0, 0) end else outputChatBox(SFgang.." is currently robbing the bank.", hitElement, 200,0,0) end end if source == SFmarkerDoor3 and SFsecurity3 ~= 1 then if SFgang == getElementData(hitElement, "gang") then local wl = exports.ITWpolice:getWantedLevel(hitElement) local wl = wl + 5 if wl > 36 then wl = 36 end exports.ITWpolice:setWantedLevel(hitElement, wl) triggerClientEvent("MARKERDOOR", getRootElement(), hitElement, "Door3") else outputChatBox(SFgang.." is currently robbing the bank.", hitElement, 200,0,0) end end if source == SFmarkerSafe1 and SFsecurity5 ~= 1 then if SFgang == getElementData(hitElement, "gang") then if SFsecurity1 == 1 and SFsecurity2 == 1 and SFsecurity3 == 1 then local wl = exports.ITWpolice:getWantedLevel(hitElement) local wl = wl + 5 if wl > 36 then wl = 36 end exports.ITWpolice:setWantedLevel(hitElement, wl) triggerClientEvent("MARKERDOOR", getRootElement(), hitElement, "Safe1") else playername = getPlayerName(hitElement) SFbankWatcher(playername) end else outputChatBox(SFgang.." is currently robbing the bank.", hitElement, 200,0,0) end end if source == SFmarkerSafe2 and SFsecurity6 ~= 1 then if SFgang == getElementData(hitElement, "gang") then if SFsecurity1 == 1 and SFsecurity2 == 1 and SFsecurity3 == 1 then local wl = exports.ITWpolice:getWantedLevel(hitElement) local wl = wl + 5 if wl > 36 then wl = 36 end exports.ITWpolice:setWantedLevel(hitElement, wl) triggerClientEvent("MARKERDOOR", getRootElement(), hitElement, "Safe2") else playername = getPlayerName(hitElement) SFbankWatcher(playername) end else outputChatBox(SFgang.." is currently robbing the bank.", hitElement, 200,0,0) end end if source == SFmarkerSafe3 and SFsecurity7 ~= 1 then if SFgang == getElementData(hitElement, "gang") then if SFsecurity1 == 1 and SFsecurity2 == 1 and SFsecurity3 == 1 then local wl = exports.ITWpolice:getWantedLevel(hitElement) local wl = wl + 5 if wl > 36 then wl = 36 end exports.ITWpolice:setWantedLevel(hitElement, wl) triggerClientEvent("MARKERDOOR", getRootElement(), hitElement, "Safe3") else playername = getPlayerName(hitElement) SFbankWatcher(playername) end else outputChatBox(SFgang.." is currently robbing the bank.", hitElement, 200,0,0) end end if source == SFmarkerSafe4 and SFsecurity8 ~= 1 then if SFgang == getElementData(hitElement, "gang") then if SFsecurity1 == 1 and SFsecurity2 == 1 and SFsecurity3 == 1 then local wl = exports.ITWpolice:getWantedLevel(hitElement) local wl = wl + 5 if wl > 36 then wl = 36 end exports.ITWpolice:setWantedLevel(hitElement, wl) triggerClientEvent("MARKERDOOR", getRootElement(), hitElement, "Safe4") else playername = getPlayerName(hitElement) SFbankWatcher(playername) end else outputChatBox(SFgang.." is currently robbing the bank.", hitElement, 200,0,0) end end if source == SFmarkerSafe5 and SFsecurity9 ~= 1 then if SFgang == getElementData(hitElement, "gang") then if SFsecurity1 == 1 and SFsecurity2 == 1 and SFsecurity3 == 1 then local wl = exports.ITWpolice:getWantedLevel(hitElement) local wl = wl + 5 if wl > 36 then wl = 36 end exports.ITWpolice:setWantedLevel(hitElement, wl) triggerClientEvent("MARKERDOOR", getRootElement(), hitElement, "Safe5") else playername = getPlayerName(hitElement) SFbankWatcher(playername) end else outputChatBox(SFgang.." is currently robbing the bank.", hitElement, 200,0,0) end end if source == SFmarkerSafe6 and SFsecurity10 ~= 1 then if SFgang == getElementData(hitElement, "gang") then if SFsecurity1 == 1 and SFsecurity2 == 1 and SFsecurity3 == 1 then local wl = exports.ITWpolice:getWantedLevel(hitElement) local wl = wl + 5 if wl > 36 then wl = 36 end exports.ITWpolice:setWantedLevel(hitElement, wl) triggerClientEvent("MARKERDOOR", getRootElement(), hitElement, "Safe6") else playername = getPlayerName(hitElement) SFbankWatcher(playername) end else outputChatBox(SFgang.." is currently robbing the bank.", hitElement, 200,0,0) end end if source == SFmarkerSafe7 and SFsecurity11 ~= 1 then if SFgang == getElementData(hitElement, "gang") then if SFsecurity1 == 1 and SFsecurity2 == 1 and SFsecurity3 == 1 then local wl = exports.ITWpolice:getWantedLevel(hitElement) local wl = wl + 5 if wl > 36 then wl = 36 end exports.ITWpolice:setWantedLevel(hitElement, wl) triggerClientEvent("MARKERDOOR", getRootElement(), hitElement, "Safe7") else playername = getPlayerName(hitElement) SFbankWatcher(playername) end else outputChatBox(SFgang.." is currently robbing the bank.", hitElement, 200,0,0) end end if source == SFmarkerSafe8 and SFsecurity12 ~= 1 then if SFgang == getElementData(hitElement, "gang") then if SFsecurity1 == 1 and SFsecurity2 == 1 and SFsecurity3 == 1 then local wl = exports.ITWpolice:getWantedLevel(hitElement) local wl = wl + 5 if wl > 36 then wl = 36 end exports.ITWpolice:setWantedLevel(hitElement, wl) triggerClientEvent("MARKERDOOR", getRootElement(), hitElement, "Safe8") else playername = getPlayerName(hitElement) SFbankWatcher(playername) end else outputChatBox(SFgang.." is currently robbing the bank.", hitElement, 200,0,0) end end else outputChatBox("There are not enough cops on the server/you are not in official gangs. Access denied!",hitElement,255,255,255) end end end function SFbankWatcher(playername) local players = getElementsByType("player") for i, subAdmin in pairs (players) do if exports.ITWacl:isPlayerInGroup(subAdmin, "subadmin") then exports.RPGcommands:sendMessage("*Buguser/Cheater AT SF-BANK: " .. playername, 255, 0, 0, subAdmin) end end end function SFdisableDoor(doorname) if doorname == "Door1" and SFmarkerDoor1 and SFsecurity1 == 0 then SFgang =
  13. Hello people I have one problem in my script turf I did not understand why when i /turf make does not create the area and appears this: (Turf Error: Provide: leftX bottomY Height Width Red Green and Blue!) and does not understand that and to do
  14. thegost

    Help In HR

    I already tried but I don't get and the suitcase continues in the hand doesn't leave
  15. thegost

    Help In HR

    cliente or sevrer?
  16. thegost

    Help In HR

    the bag not remove
  17. thegost

    Help In HR

    Hello People I have one problema in my script HouseRobbery / Store Robberys , problema is i add in script bonne attake bag to players in end the Sr but he go warehouses the bag not remove players have bag all time can help Server function nextStep() for i, robber in pairs (getElementsWithinColShape(houserobCircle, "player")) do if not isPedDead(robber) and isPedOnGround(robber) and robberTeams[getTeamName(getPlayerTeam(robber))] then local x,y,z = getElementPosition(robber) exports.RPGcommands:giveMoney(robber, 16000) exports.RPGcommands:sendMessage("*STORE ROBBERY* You got $16000 from the rob, go to the a warehouse in the city to get more money!", 0, 255, 0, robber) atBag = createObject(1210,x,y,z) exports.bone_attach:attachElementToBone(atBag,robber,12,0,0.05,0.27,0,180,0) triggerClientEvent("showWarehouses", robber) end end Client [ PROBLEM IN] function finish(robber) if not isPedDead(robber) and isPedOnGround(robber) and robber == getLocalPlayer(robber) then exports.RPGcommands:giveMoney(robber, 10000) exports.RPGcommands:sendClientMessage("You got $10000 from the warehouse.", 0, 255, 0) hideALL() destroyElement(atBag) end end addEventHandler("onClientMarkerHit", marker, finish)
  18. Yes this script I not script ....
  19. But the error that is your expressed in print
×
×
  • Create New...