Jump to content

boro

Members
  • Posts

    231
  • Joined

  • Last visited

Everything posted by boro

  1. client function eag () txd = engineLoadTXD ( "Teams/EAG/ac.txd" ) engineImportTXD ( txd, skin[2] ) dff = engineLoadDFF ( "Teams/EAG/ac.dff", 0 ) engineReplaceModel ( dff, skin[2] ) end addEventHandler( "onClientResourceStart", getResourceRootElement(getThisResource()), eag )
  2. try this server setTimer(function() triggerClientEvent (source, "onStart", root, "test" ) end,3000,1) client addEvent ( "onStart", true ) function startEventHandler () triggerLatentClientEvent(source,"onServers",100000,false,source,scriptstr) end addEventHandler ( "onStart", getLocalPlayer(), startEventHandler )
  3. boro

    Kill System!

    open admin panel go to resource list find admin resource and set it.
  4. boro

    Kill System!

    ok set admin security in admin panel to 0 and problem is solved
  5. boro

    Green zone

    Try this server greenzoneEnter = createColCuboid ( 1844.5594482422, 1375.3376464844, 0.0, 255, 255, 255 ) greenzonemaparea = createRadarArea ( 1844.5594482422, 1375.3376464844, 255, 255, 0, 255, 0, 150 ) -- 150 = alpha. addEventHandler( "onColShapeHit", greenzoneEnter, function(hitPlayer,thePlayer) if getElementType(hitPlayer)=="player" then triggerClientEvent(thePlayer, "zoneEnter", thePlayer) toggleControl ( thePlayer, "fire", false ) toggleControl ( thePlayer, "next_weapon", false ) toggleControl ( thePlayer, "previous_weapon", false ) setPedWeaponSlot ( thePlayer, 0 ) toggleControl ( thePlayer, "aim_weapon", false ) toggleControl ( thePlayer, "vehicle_fire", false ) toggleControl ( thePlayer, "vehicle_secondary_fire", false ) end end) addEventHandler( "onColShapeLeave", greenzoneEnter,function(hitPlayer,thePlayer) if getElementType(hitPlayer)=="player"then triggerClientEvent(thePlayer, "zoneExit", thePlayer) toggleControl ( thePlayer, "fire", true ) toggleControl ( thePlayer, "next_weapon", true ) toggleControl ( thePlayer, "previous_weapon", true ) toggleControl ( thePlayer, "aim_weapon", true ) toggleControl ( thePlayer, "vehicle_fire", true ) toggleControl ( thePlayer, "vehicle_secondary_fire", true ) end end) client function buildNotice() purpleLabel = guiCreateLabel(0.65, 0, 1, 1, "You are in a Safe Zone.", true) guiSetFont(purpleLabel, "sa-header") guiLabelSetColor(purpleLabel,0,255,0) guiSetVisible(purpleLabel,false) end addEventHandler("onClientResourceStart", getResourceRootElement( getThisResource() ), buildNotice) addEvent("zoneEnter", true) addEventHandler("zoneEnter", getRootElement(), function() guiSetVisible(purpleLabel, true) end ) addEvent("zoneExit", true) addEventHandler("zoneExit", getRootElement(), function() guiSetVisible(purpleLabel, false) end )
  6. boro

    Kill System!

    show script code
  7. boro

    pedclothes

    up any ideas?
  8. boro

    godmode

    problem solved i use this if ( getElementType( attacker ) == "vehicle" ) then ty all for help
  9. boro

    godmode

    Yes with onClientPlayerDamage it work nice ty tapl and please how to make godmode for source when is attacker in vehicle ?
  10. boro

    godmode

    Hi all i have godmode script, this script work fine but how make godmode only for player vs player ? because when zombie attack me soo i have still 100% and this is bad i try this but it dont work function god ( attacker ) if ( getElementType ( attacker ) == "player" ) then if attacker == player then cancelEvent() end end end addEventHandler("onPlayerDamage", getRootElement(), god)
  11. boro

    pedclothes

    Hi all i have script from comunity cjpedcustomer and in log see this warning [2013-07-25 13:02:22] WARNING: cjcustomer/cjcustomer_s.lua:17: Bad argument @ 'addPedClothes' what is bad ? root = getRootElement () players = {} players = getElementsByType ( "player" ) function applyClothing ( incredibleTable ) if getElementModel ( source ) ~= 0 then setElementModel ( source, 0 ) end count = 0 while count ~= 9 do local c = count if(c > 3) then c = c+9 end if tostring(incredibleTable[count].storedValue) == "x" then removePedClothes ( source, c ) elseif tostring(incredibleTable[count].storedValue) ~= "" then --blank fields do nothing local texture, model = getClothesByTypeIndex ( c, tostring(incredibleTable[count].storedValue) ) addPedClothes ( source, texture, model, c ) --outputChatBox ( "texture: "..texture.." model: "..model.." count: "..count ) end count = count + 1 end if tostring(incredibleTable[9].storedValue) ~= "" then setPedStat ( source, 21, incredibleTable[9].storedValue ) --outputChatBox ( "Fat stuff triggered" ) end if tostring(incredibleTable[10].storedValue) ~= "" then setPedStat ( source, 23, incredibleTable[10].storedValue ) --outputChatBox ( "Strong stuff triggered" ) end end addEvent("applyClothes", true, "incredibleTable" ) addEventHandler("applyClothes", getRootElement(), applyClothing)
  12. please help i made resource for start and stop resource but log write this [2013-04-26 11:27:27] WARNING: newskin\server.lua:12: Bad argument @ 'startResource' [2013-04-26 11:27:27] WARNING: newskin\server.lua:13: Bad argument @ 'stopResource' Chatbox work fine server side function startingHandler ( ) outputChatBox ( "Test Start", getRootElement(), 255, 255, 255, true ) startResource(skin2) stopResource(skin1) end addEvent( "onStarting", true ) addEventHandler( "onStarting", getRootElement(), startingHandler ) function stopingHandler ( ) outputChatBox ( "Test Stop", getRootElement(), 255, 255, 255, true ) startResource(skin1) stopResource(skin2) end addEvent( "onStoping", true ) addEventHandler( "onStoping", getRootElement(), stopingHandler )
  13. boro

    How To

    is it good ? i dont must test it because am in school root = getRootElement () function checkTime () setTimer ( UpgradeWeather, 1000, 0 ) end addEventHandler ( "onClientRender", root, checkTime ) function UpgradeWeather ( ) local h, m = getTime() if h > 20 then setWeather ( 9 ) elseif h < 6 then setWeather ( 11 ) end end
  14. boro

    How To

    Please help how to setWeather ( 9 ) when is game time 20:00 ? Exist event for check game timer ?
  15. Ah yes it work but i have set in meta as client side lol but ty
  16. Hi all i make script for set account all 5 sec but this dont work why ? please help.. function updatePlayersKills ( ) for index, player in ipairs ( getElementsByType "player" ) do local account = getPlayerAccount (player) if not (isGuestAccount (account)) then setAccountData(account,"Zombie Kills",getElementData(player,"Zombie Kills")) end end end setTimer ( updatePlayersKills, 5000, 0 )
  17. boro

    unbindkey help

    Hi all please help i try make gui, it work fine but i dont know how to set unbindkey This work only for open bindKey('F4','down', function ( ) guiSetVisible (GUIEditor_Window[1],true) showCursor (true) end ) And next time i try this and guy dont open why ? please help bindKey('F4','down', function ( ) guiSetVisible (GUIEditor_Window[1],true) showCursor (true) end unbindKey('F4','down', function ( ) guiSetVisible (GUIEditor_Window[1],false) showCursor (false) end )
  18. boro

    help

    for this
  19. boro

    help

    thats right
  20. boro

    help

    local IDs ??
  21. boro

    help

    this is good for this but ty my old script work fine local IDs = { 579, 494, 424, 589, 469, 500, 504, 497, 434, 490, 489, 474, 461, 521, 470, 495, 601, 548, 487 } function quitPlayer ( ) for k, vehicle in pairs ( getElementsByType ( "vehicle" ) ) do if IDs [ getElementModel ( vehicle ) ] then if checkEmpty ( vehicle ) then destroyElement ( vehicle ) end end end end addEventHandler ( "onPlayerQuit", root, quitPlayer ) checkEmpty = function ( vehicle ) if #getVehicleOccupants ( vehicle ) == 0 then return true else return false end end
×
×
  • Create New...