Jump to content

Plate

Members
  • Posts

    938
  • Joined

  • Last visited

Everything posted by Plate

  1. probastes poniendo /debugscript 3 y mirando el error no?
  2. Si ya se alex solid no es la mejor manera de hacer alex me dijo que lo haga con arrays pero no tengo idea de como hacerlo con arrays
  3. Hola tengo una duda se pueden poner muchas getElementData en una gridList por ejemplo getElementData(source, "m4") getElementData(source, "Sniper Rifle") getElementData(source, "Pistol") eso se puede poner todo en una gridlist?
  4. Lo de los acl esta mal tenes que usar un for-loop puerta = createObject ( 980, -3131.3000488281, 467.5, 7.5999999046326, 0, 0, 270.99975585938 ) function abrir ( thePlayer, seat, jacked ) -- seat, jacked WTF? local playerAcc = getPlayerAccount ( source ) if ( source == puerta ) and ( getPlayerTeam(thePlayer) and getTeamName(getPlayerTeam(thePlayer)) ~= "ZS~Gamers" ) then outputChatBox("Solo los del clan ZS~Gamers pueden abrir esta puerta.", thePlayer, 255,90,0, true) for _, group in ipairs ( { "Admin", "Moderator", "SuperModerator", "Console" } ) do if isObjectInACLGroup ( "user.".. getAccountName ( playerAcc ), aclGetGroup ( group ) ) then moveObject ( puerta, 1500, -3131.3000488281, 467.5, 3.5999999046326 ) end end end addCommandHandler ( "test1" , abrir ) function cerrar ( thePlayer, seat, jacked ) -- quita los argumentos de seat jacked if ( source == puerta ) and ( getPlayerTeam(thePlayer) and getTeamName(getPlayerTeam(thePlayer)) ~= "ZS~Gamers" ) then moveObject ( puerta, 3000, -3131.3000488281, 467.5, 7.5999999046326, 0, 0, 270.99975585938 ) end end addCommandHandler ( "test2" , abrir ) despues nose lo demas si esta bien jaja
  5. Plate

    Arma primaria

    No creo que este bien pero ... function setweapon() local row, col = guiGridListGetSelectedItem ( lista ) if ( row and col and row ~= -1 and col ~= -1 ) then local weaponName = guiGridListGetItemText ( lista, row, 1 ) local pedSlot = getPedWeaponSlot ( source ) if (pedSlot == 6 or pedSlot == 5) then setElementData(source, "Arma1", true) if getElementData(source, "Arma1" ) then outputChatBox("Ya tienes un arma primaria", source, 0, 255, 0) outputChatBox("Te equipastes un arma primaria", source, 0, 255, 0) elseif( pedSlot ==1 or pedSlot == 2 or pedSlot == 3 or pedSlot == 4 or pedSlot == 7 or pedSlot == -- s8) --> then setElementData(source, "Arma2", true) outputChatBox("Te equipastes un arma secundaria", source, 0, 255, 0) elseif getElementData(source, "Arma2") then outputChatBox("Ya tienes un arma secundaria", source, 255, 0, 0) setPedWeaponSlot(localPlayer, getSlotFromWeapon(weaponName)) end end end addEventHandler("onClientGUIClick", equipar, setweapon, false)
  6. Plate

    Arma primaria

    Si pero nadie responde el tema yo pense en un setElementData pero creo que no se puede con eso
  7. Plate

    Arma primaria

    Hola tengo una duda como se podria ponerle un arma primaria al player y una secundaria osea que si tiene arma primaria y segundaria no pueda ponerse otra que esas 2
  8. Plate

    guiSetText

    Lol no me di cuenta gracias
  9. Plate

    guiSetText

    Hola necesito una ayuda es que esto no sirve y tampoco tira ningun error addEventHandler("onClientElementDataChange", getRootElement(), function (datName) if ( dataName == "Level" ) then guiSetText ( GUIEditor_Label[1],( getElementData ( localPlayer, "Level" ) ) ) elseif ( dataName == "EXP" ) then guiSetText ( GUIEditor_Label[3], ( getElementData ( localPlayer, "EXP" ) ) ) end end )
  10. Plate

    fuel

    El vehicleType Aircraft no existe se divide en Helicopter y Plane
  11. Plate

    fuel

    if getVehicleType(vehicle) ~= 'Automobile' and getVehicleType(vehicle) ~= 'Bike' and getVehicleType(vehicle) ~= 'Monster Truck' and getVehicleType(vehicle) ~= 'Quad' and and getVehicleType(vehicle) ~= 'Helicopter' and getVehicleType(vehicle) ~= 'Plane' then return end probe asi pero no anda
  12. Plate

    setElementData

    Hola necesito una ayuda con este script es que me da error en el setElementData el codigo local colshape = createColRectangle ( 103.88594818115, 1302.0729980469, 220, 200 ) zombiesMatados = 0 function zona ( ) if ( isElementWithinColShape ( source, colshape ) ) then zombiesMatados = ( zombiesMatados + 1 ) if ( zombiesMatados == 3 ) then if ( not isElement ( slothbot1 ) ) then slothbot1 = exports [ "slothbot" ]:spawnBot ( 111.79273223877, 1336.3046875, 10.5859375, 90, math.random(300, 302), 0, 0, ex, 38, "hunting", true ) exports.extra_health:setElementExtraHealth(slothbot1, 3000) myBlip = createBlipAttachedTo ( slothbot1, 23 ) triggerClientEvent("spawneo", getRootElement(), slothbot1) end end end end addEventHandler ( "onZombieWasted", getRootElement(), zona ) addEventHandler("onBotSpawn",getRootElement(),zona) function restartear ( ) if ( isElementWithinColShape ( source, colshape ) ) then zombiesMatados = 0 end end addEvent ( "onBotWasted", true ) addEventHandler ( "onBotWasted",getRootElement(), restartear ) function start() setElementData(colshape, "High", true) outputChatBox("La zona del boss esta en High", getRootElement(), 255, 0, 0) end addEventHandler("onResourceStart", getRootElement(), start) function grabe() if getElementData(colshape, "High") then setElementData(colshape, "Medium", true) if getElementData(colshape, "Medium") then setElementData(colshape, "Slow", true) end end end addEventHandler("onBotWasted", getRootElement(), grabe) function destro() destroyElement(myBlip) end addEventHandler("onBotWasted", getRootElement(), destro) function inf() if getElementData(colshape, "High") then outputChatBox("[bOSS]: Boss High Spawned", getRootElement(), 255, 0, 0) if getElementData(colshape, "Medium") then outputChatBox("[bOSS]: Boss Medium Spawned", getRootElement(), 0, 255, 0) if getElementData(colshape, "Slow") then outputChatBox("[bOSS]: Boss Slow Spawned", getRootElement(), 100, 255, 100) end end end end addEventHandler("onBotSpawn", getRootElement(), inf) o asi? ( en el setElementData) setElementData(colshape, "zona", "High", true)
  13. Plate

    Ayuda Pls..

    Ponelo en la secion español no en la de ingles
  14. Plate

    setPlayerTeam

    Si gracias Solid y alex
  15. Plate

    setPlayerTeam

    local player = guiGridListGetItemText ( playerList, row2, column )
  16. Plate

    setPlayerTeam

    function deteam (player) local row, col = guiGridListGetSelectedItem ( teamList ) if ( row and col and row ~= -1 and col ~= -1 ) then local row2, col2 = guiGridListGetSelectedItem ( playerList ) if ( row2 and col2 and row2 ~= -1 and col2 ~= -1 ) then local team = guiGridListGetItemText ( teamList, row, columnA ) local player = guiGridListGetItemText ( playerList, row3, column ) triggerServerEvent ( "onClanPlayerMove", localPlayer, getPlayerFromName ( player ), team ) end end addEventHandler ( "onClientGUIClick", mover, deteam, false )
  17. Plate

    setPlayerTeam

    guiGridListGetSelectedItem guiGridListGetItemText eso no?
  18. Plate

    setPlayerTeam

    function deteam (player)
  19. Plate

    setPlayerTeam

    Hola neceisto una ayuda con este script en el que me ayudo Solidsnake14 y Alex_Steel me dice: Bad Argument @ setPlayerTeam Bad Argument @ getPlayerName [ Expected element at argument 1, got boolean ] attempt to concatentate a boolean valvue client: function deteam (player) local row, col = guiGridListGetSelectedItem ( teamList ) if ( row and col and row ~= -1 and col ~= -1 ) then local team = guiGridListGetItemText ( teamList, row, columnA ) triggerServerEvent ( "onClanPlayerMove", localPlayer, getPlayerFromName ( player ), team ) end end addEventHandler ( "onClientGUIClick", mover, deteam, false ) server: function setTeam(player, teamName) local theTeam = getTeamFromName ( teamName ) if ( theTeam ) then setPlayerTeam ( player , theTeam ) outputChatBox(getPlayerName(source).." agrego a "..getPlayerName(player).." al clan "..getTeamName(theTeam).."", getRootElement(), 0, 255 ,255 ,true) end end addEvent("onClanPlayerMove", true) addEventHandler("onClanPlayerMove",getRootElement(), setTeam)
  20. Plate

    fuel

    es demasiado largo para postearlo yo te diria que lo descargues y lo mires vos mismo PD posteo el carData "-1" fuel="35" />-- Player entry --> "0" fuel="200" />-- Default entry --> "602" fuel="250" />-- Alpha --> "545" fuel="250" />-- Hustler --> "496" fuel="250" />-- Blista --> "517" fuel="250" />-- Majestic --> "401" fuel="250" />-- Bravura --> "410" fuel="250" />-- Manana --> "518" fuel="250" />-- Buccaneer --> "600" fuel="250" />-- Picador --> "527" fuel="250" />-- Cadrona --> "436" fuel="250" />-- Previon --> "589" fuel="250" />-- Club --> "580" fuel="250" />-- Stafford --> "419" fuel="250" />-- Esperanto --> "439" fuel="250" />-- Stallion --> "533" fuel="250" />-- Feltzer --> "549" fuel="250" />-- Tampa --> "526" fuel="250" />-- Fortune --> "491" fuel="250" />-- Virgo --> "474" fuel="250" />-- Hermes --> "445" fuel="350" />-- Admiral --> "604" fuel="350" />-- Glendale --> "507" fuel="350" />-- Elegant --> "585" fuel="350" />-- Emperor --> "587" fuel="350" />-- Euros --> "466" fuel="350" />-- Glendale --> "492" fuel="350" />-- Greenwood --> "546" fuel="350" />-- Intruder --> "551" fuel="350" />-- Merit --> "516" fuel="350" />-- Nebula --> "467" fuel="350" />-- Oceanic --> "426" fuel="350" />-- Premier --> "547" fuel="350" />-- Primo --> "405" fuel="350" />-- Sentinel --> "409" fuel="350" />-- Stretch --> "550" fuel="350" />-- Sunrise --> "566" fuel="350" />-- Tahoma --> "540" fuel="350" />-- Vincent --> "421" fuel="350" />-- Washington --> "529" fuel="350" /> "497" fuel="350" />
  21. function setweapon(weaponName) local row, col = guiGridListGetSelectedItem ( lista ) if ( row and col and row ~= -1 and col ~= -1 ) then local weaponName = guiGridListGetItemText ( lista, row, 1 ) local theWeapon = getWeaponIDFromName(weaponName) setPedWeaponSlot(localPlayer, getSlotFromWeapon(theWeapon)) end end addEventHandler("onClientGUIClick", equipar, setweapon, false)
  22. weponName es un argument no copie de otro tema sino de otro de mis scripts en los que vos me ayudastes function setweapon() local row, col = guiGridListGetSelectedItem ( lista ) if ( row and col and row ~= -1 and col ~= -1 ) then local weaponName = guiGridListGetItemText ( lista, row, 1 ) setPedWeaponSlot(localPlayer, getSlotFromWeapon(weaponName)) end end addEventHandler("onClientGUIClick", equipar, setweapon, false)
×
×
  • Create New...