Jump to content

Search the Community

Showing results for tags 'mtadayz '.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Multi Theft Auto: San Andreas 1.x
    • Support for MTA:SA 1.x
    • User Guides
    • Open Source Contributors
    • Suggestions
    • Ban appeals
  • General MTA
    • News
    • Media
    • Site/Forum/Discord/Mantis/Wiki related
    • MTA Chat
    • Other languages
  • MTA Community
    • Scripting
    • Maps
    • Resources
    • Other Creations & GTA modding
    • Competitive gameplay
    • Servers
  • Other
    • General
    • Multi Theft Auto 0.5r2
    • Third party GTA mods
  • Archive
    • Archived Items
    • Trash

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Member Title


Gang


Location


Occupation


Interests

Found 1 result

  1. Preciso de uma ajuda numa função.. toda vez que to o comando de criar o veiculo com as coordenada ja na tabela da esse erro vehicle_spawns.lua:3: bad argument #1 to 'pairs' (table expected, got number) função server. function spawnDayZVehicles() for i,vehs in pairs(vehiclesTable)do for i,spawn in pairs(#vehSpawns[vehs[1]]) do local x,y,z = spawn[1],spawn[2],spawn[3] local veh = createVehicle(vehs[2],x,y,z) local vehCol = createColSphere(x,y,z,4) attachElements(vehCol,veh,0,0,0) setElementData(vehCol,"parent",veh) setElementData(veh,"parent",vehCol) setElementData(vehCol,"vehicle",true) setElementData(vehCol,"MAX_Slots",vehs[8]) local engRand = math.random(0,vehs[3]) local tireRand = math.random(0,vehs[4]) local partRand = math.random(0,vehs[5]) local rotorRand = math.random(0,vehs[6]) local glaRand = math.random(0,vehs[7]) setElementData(vehCol,"Engine_inVehicle",engRand) setElementData(vehCol,"Tire_inVehicle",tireRand) setElementData(vehCol,"Parts_inVehicle",partRand) setElementData(vehCol,"Rotor_inVehicle",rotorRand) setElementData(vehCol,"Glass_inVehicle",glaRand) setElementData(vehCol,"spawn",{vehs[2],x,y,z}) setElementData(vehCol,"fuel",10) setElementData(vehCol,"ProtectionPercent",0) setElementData(vehCol,"maxfuel",vehs[9]) setElementData(vehCol,"needengines",vehs[3]) setElementData(vehCol,"needtires",vehs[4]) setElementData(vehCol,"needparts",vehs[5]) setElementData(vehCol,"needrotor",vehs[6]) setElementData(vehCol,"needglass",vehs[7]) if tireRand >= 1 then setElementData(vehCol,"TireState",math.random(0,100)) else setElementData(vehCol,"TireState",100) end if engRand >= 1 then setElementData(vehCol,"EngineState",math.random(0,100)) else setElementData(vehCol,"EngineState",100) end if rotorRand >= 1 then setElementData(vehCol,"RotorState",math.random(0,100)) else setElementData(vehCol,"RotorState",100) end if partRand >= 1 then setElementData(vehCol,"PartsState",math.random(0,100)) else setElementData(vehCol,"PartsState",100) end end end end
×
×
  • Create New...