Jump to content

Dentos

Members
  • Posts

    68
  • Joined

  • Last visited

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

Dentos's Achievements

Snitch

Snitch (10/54)

0

Reputation

  1. its just im very new at lua >.< I made other scripts with help
  2. IYAMA I tired script like that but dosent even work local pBlips = { } addEventHandler("onResourceStart", resourceRoot, function() for index, player in ipairs(getElementsByType("player")) do addTeamBlip(player) end end ) function addTeamBlip(player) if ( pBlips[player] ) then return false end -- Adding a prevention of duplicate blips local pAccount = getPlayerAccount(player) local theGang = ( isGuestAccount(pAccount) and false ) or exports["gang_system"]:getAccountGang(pAccount) if ( theGang ) then local r, g, b = getPlayerNametagColor( player ) local theBlip = createBlipAttachedTo( player, 0, 2, r, g, b ) -- Change visibility to only the team members setElementVisibleTo( theBlip, root, false ) for index, value in ipairs ( exports["gang_system"]:getGangMembers(theGang) ) do setElementVisibleTo( theBlip, value, true ) end pBlips[player] = theBlip end end function destroyBlip(element) local theElement = source or element if ( theElement ) then destroyElement(pBlips[theElement]) pBlips[theElement] = nil -- Just in-case... end end -- Events addEventHandler ( "onPlayerSpawn", root, addTeamBlip ) -- onPlayerSpawn will now add a teamBlip addEventHandler ( "onPlayerQuit", root, destroyBlip ) addEventHandler ( "onPlayerWasted", root, destroyBlip )
  3. still nothing Anubhav i can still see ppl that dont have gang when i dont have gang its funny cuz I cant see ppl dont have gang when im in a gang it works and i can only see gang member and when im not in gang it dosent work its like it ipairs ppl dont have a gang as it was gang
  4. sorry kinda new at all this so im not geting any errors in debugscript 3 but i can still see my blip in map i want it so if you dont have gang you cant see any blip in map
  5. IIYAMA I tried this but nothing playerBlibs = {} amouunt = 0 function updateGPS() amouunt = 0 local gangname = getElementData(getLocalPlayer(),"gang") for i, blip in ipairs(playerBlibs) do destroyElement(blip) end if not getElementData(getLocalPlayer(),"gang") then return end playerBlibs = {} for i, player in ipairs(getElementsByType("player")) do if gangname == getElementData(player,"gang") then amouunt = amouunt+1 playerBlibs[amouunt] = createBlipAttachedTo(player,0,2,22,255,22) setBlipVisibleDistance(playerBlibs[amouunt],1000) if not gangname then --ADDED THIS BUT STILL NOTHING destroyElement(blip) end end end end setTimer(updateGPS,1000,0) Saml1er my script works fine but for some reason its making player who dont have gang see eachother in map its a Dayz server so i dont want for you able to so people in map unless there people from your gang
  6. Still the same i think my server counts player who dont have gang as a gang since when you dont have gang you can only see player that dont have gang and not player that do btw im using castillos gang system idk if that helps at all maybe something like this if gangname == ("") then destroyElement(blip) tired it didnt work
  7. Si esq que lo copio con el celular aqui esta bien el script playerBlibs = {} amouunt = 0 function updateGPS() amouunt = 0 local gangname = getElementData(getLocalPlayer(),"gang") for i, blip in ipairs(playerBlibs) do destroyElement(blip) end if not getElementData(getLocalPlayer(),"gang") then return end playerBlibs = {} for i, player in ipairs(getElementsByType("player")) do if gangname == getElementData(player,"gang") then amouunt = amouunt+1 playerBlibs[amouunt] = createBlipAttachedTo(player,0,2,22,255,22) setBlipVisibleDistance(playerBlibs[amouunt],1000) end end end setTimer(updateGPS,1000,0)
  8. So I got this small script that allows you to see only the people in your gang(blips) in the map it works fine but theres a little problem with it when I login as a player with no gang it works fine at first but after you walk for while you start seeing people that dont have gang in map ... so I want make it so if you dont have gang you can never see anyone in the map heres the script playerBlibs = {} amouunt = 0 function updateGPS() amouunt = 0 local gangname = getElementData(getLocalPlayer(),"gang") for i, blip in ipairs(playerBlibs) do destroyElement(blip) end if not getElementData(getLocalPlayer(),"gang") then return end playerBlibs = {} for i, player in ipairs(getElementsByType("player")) do if gangname == getElementData(player,"gang") then amouunt = amouunt+1 playerBlibs[amouunt] = createBlipAttachedTo(player,0,2,22,255,22) setBlipVisibleDistance(playerBlibs[amouunt],1000) end end end setTimer(updateGPS,1000,0)
  9. Buenas..!! Amigos Quiero que me ayuden con esto porfavor, quiero Saber Como Hago para poner un punto amarillo o letra en el mapa identificando que es una zona de luteo (Lots) Porfavor Ayudenme Tengo mi Sv Aca se los Dejos mtasa://74.91.126.106:22053 64 slot Porfavor Espero Que me Ayuden Muchas Gracias...!!
  10. Lo que pasa es que yo tengo un resource de anti relog, me funciona pero los mensajes comoi estos _ outputChatBox ( "Ya puedes desconectarte.", ps, 255, 5, 0 ) end outputChatBox ( "Recibiste daño, no puedes desconectare hasta que pasen 30 segundos!", source, 255, 5, 0 ) end no me salen estos mensajes y quisiera que me salga eso aqui le dejo el resource completo --------------------------------------------------------------- --------------------------------------------------------------- --* MTADAYZ.COM --* MTADAYZ.COM --* MTADAYZ.COM --* MTADAYZ.COM --------------------------------------------------------------- function playerGetDamageDayZ ( attacker, weapon, bodypart, loss ) if not getElementData ( source, "tempodosexo" ) then if weapon and weapon > 1 and attacker and getElementType(attacker) == "player" then setTimer (deslogger, 30000, 1, source) setTimer ( setElementData, 30000, 1, source, "tempodosexo", false ) setElementData ( source, "tempodosexo", true ) outputChatBox ( "Recibiste daño, no puedes desconectare hasta que pasen 30 segundos!", source, 255, 5, 0 ) end end end addEventHandler ( "onClientPlayerDamage", getLocalPlayer (), playerGetDamageDayZ ) function deslogger(ps) outputChatBox ( "Ya puedes desconectarte.", ps, 255, 5, 0 ) end
  11. hola me preguntaba si por favor me pueden ayudar con este problemilla con este resourse. gracias de antemano. Lo que pasa es que tengo un resourse de vip que permite dar items a ti mismo y a otros jugadores y yo quiero que solo me pueda dar items a mi mismo y no a otros jugadores. He intentado editarlo varias veces pero no funciono, por favor me ayudan serian de gran ayuda. addEvent("onGIPOpened", true) local sW, sH = guiGetScreenSize() -- // Variables needed to know the width and height. local w = { gridList = {}, label = {}, editBox = {}, button = {}, comboBox = {} } local items = { ["Armas"] = { --"TEC-9", --"M136 Rocket Launcher", --"Heat-Seeking RPG", "M4", "AK-47", "Lee Enfield", "CZ 550", "MP5A5", "PDW", "SPAZ-12 Combat Shotgun", "Sawn-Off Shotgun", "Winchester 1866", "M9 SD", "M911", "Desert Eagle", "Binoculars", "Tear Gas", "Grenade", "Satchel", "Baseball Bat", "Shovel", "Golf Club", "Hunting Knife", "Hatchet" }, ["Municion"] = { --"M136 Rocket", "M4 Mag", "AK Mag", "Lee Enfield Mag", "CZ 550 Mag", "MP5A5 Mag", "PDW Mag", "SPAZ-12 Pellet", "2Rnd. Slug", "1866 Slug", "M9 SD Mag", "M911 Mag", "Desert Eagle Mag" }, ["Comida y bebidas"] = { "Water Bottle", "Pasta Can", "Beans Can", "Burger", "Pizza", "Soda Bottle", "Empty Water Bottle", "Empty Soda Cans", "Scruffy Burgers", "Milk", "Raw Meat", "Cooked Meat" }, ["Mochilas"] = { "Coyote Backpack", "Czech Backpack", "Assault Pack (ACU)", "Alice Pack" }, ["Herramientas"] = { "Box of Matches", "Infrared Goggles", "Night Vision Goggles", "GPS", "Map", "Toolbox", "Watch", "Radio Device" }, ["Medicinas"] = { "Bandage", "Morphine", "Medic Kit", "Heat Pack", "Blood Bag", "Painkiller", }, ["Partes de autos"] = { "Tire", "Engine", "Tank Parts" }, ["Skins"] = { "Camouflage[M] Clothing", "Civilian[M] Clothing", "Camouflage[F] Clothing", "Survivor[M] Clothing", "Ghillie[M] Suit", "Civilian[F] Clothing", "Survivor[F] Clothing", "Ghillie[F] Suit" }, ["Otros"] = { "Wood Pile", "Empty Gas Canister", "Full Gas Canister", "Roadflare", "Tent" } } local isItemSelected = false -- // Window creation code -- addEventHandler("onClientResourceStart", resourceRoot, function() w.main = guiCreateWindow(sW/2 - 179, sH/2 - 165, 358, 330, "Panel de Items [DeathRow]", false) guiWindowSetSizable(w.main, false) guiSetAlpha(w.main, 1.00) w.gridList.main = guiCreateGridList(10, 26, 151, 291, false, w.main) w.gridList.column = guiGridListAddColumn( w.gridList.main, "Player", 0.85 ) w.label.desc = guiCreateLabel(176, 26, 178, 22, "Choose a player from the GUI", false, w.main) guiSetFont(w.label.desc, "default-bold-small") w.label.desc2 = guiCreateLabel(233, 210, 60, 22, "Cantidad", false, w.main) guiSetFont(w.label.desc2, "default-bold-small") w.comboBox.category = guiCreateComboBox(171, 65, 266, 160, "-- Choose a category --", false, w.main) w.comboBox.itemList = guiCreateComboBox(171, 145, 266, 50, "-- Choose an item --", false, w.main) w.editBox.quantity = guiCreateEdit(231, 234, 55, 26, "", false, w.main) w.button.give = guiCreateButton(176, 280, 77, 37, "Give", false, w.main) w.button.close = guiCreateButton(263, 280, 77, 37, "Close", false, w.main) guiSetFont(w.button.give, "default-bold-small") guiSetProperty(w.button.give, "NormalTextColour", "FFAAAAAA") guiSetFont(w.button.close, "default-bold-small") guiSetProperty(w.button.close, "NormalTextColour", "FFAAAAAA") guiSetVisible(w.main, false) guiSetEnabled(w.button.give, false) for key, value in pairs (items) do if type(value) == "table" then guiComboBoxAddItem(w.comboBox.category, key) end end -- // Making quantity be only edited by numbers -- addEventHandler("onClientGUIChanged", w.editBox.quantity, function() guiSetText(source, guiGetText(source):gsub("[^0-9]","")) -- // We remove everything which is not a number check() end) -- // Changing second combobox items when first one changes -- addEventHandler("onClientGUIComboBoxAccepted", w.comboBox.category, function() local text = guiComboBoxGetItemText(w.comboBox.category, guiComboBoxGetSelected(w.comboBox.category)) guiComboBoxClear(w.comboBox.itemList) for i, st in ipairs(items[text]) do guiComboBoxAddItem(w.comboBox.itemList, st) end guiComboBoxAdjustHeight(w.comboBox.itemList, #items[text]) end ) -- // Showing item when second one was accepted. -- addEventHandler("onClientGUIComboBoxAccepted", w.comboBox.itemList, function() isItemSelected = true check() end ) -- // Handling button that closes. -- addEventHandler ( "onClientGUIClick", w.button.close, function() guiSetVisible(w.main, false) showCursor(false) end, false ) -- // Handling give button. -- addEventHandler ( "onClientGUIClick", w.button.give, function() local playerName = guiGridListGetItemText(w.gridList.main, guiGridListGetSelectedItem(w.gridList.main), 1) local item = guiComboBoxGetItemText(w.comboBox.itemList, guiComboBoxGetSelected(w.comboBox.itemList)) if (getPlayerFromName(playerName)) then triggerServerEvent("onGIPGive", localPlayer, playerName, item, tonumber(guiGetText(w.editBox.quantity))) else outputChatBox("El jugador no existe, o se cambio el nombre", 255, 0, 0) end guiSetVisible(w.main, true) showCursor(true) end, false ) addEventHandler("onClientGUIClick", w.gridList.main, check) end ) -- // Remi-X function. Sets height depending on item quantity -- function guiComboBoxAdjustHeight ( combobox, itemcount ) local width = guiGetSize ( combobox, false ) return guiSetSize ( combobox, width, ( itemcount * 20 ) + 20, false ) end -- // Handling when the administrator opens the panel -- -- // Handling when the administrator opens the panel -- addEventHandler("onGIPOpened", root, function() guiGridListClear ( w.gridList.main ) guiSetEnabled(w.button.give, false) isItemSelected = false for id, player in ipairs(getElementsByType("player")) do if player ~= localplayer then local row = guiGridListAddRow ( w.gridList.main ) guiGridListSetItemText ( w.gridList.main, row, w.gridList.column, getPlayerName ( player ), false, false ) end end guiSetVisible(w.main, true) showCursor(true) end ) function check() if guiGetText(w.editBox.quantity) ~= "" and isItemSelected and guiGridListGetItemText(w.gridList.main, guiGridListGetSelectedItem(w.gridList.main), 1) ~= "" then -- // If there's quantity guiSetEnabled(w.button.give, true) -- // We enable the button end end
  12. hola me preguntaba si por favor me pueden ayudar con este problemilla con este resourse. gracias de antemano. Lo que pasa es que tengo un resourse de vip que permite dar items a ti mismo y a otros jugadores y yo quiero que solo me pueda dar items a mi mismo y no a otros jugadores. He intentado editarlo varias veces pero no funciono, por favor me ayudan serian de gran ayuda. addEvent("onGIPOpened", true) local sW, sH = guiGetScreenSize() -- // Variables needed to know the width and height. local w = { gridList = {}, label = {}, editBox = {}, button = {}, comboBox = {} } local items = { ["Armas"] = { --"TEC-9", --"M136 Rocket Launcher", --"Heat-Seeking RPG", "M4", "AK-47", "Lee Enfield", "CZ 550", "MP5A5", "PDW", "SPAZ-12 Combat Shotgun", "Sawn-Off Shotgun", "Winchester 1866", "M9 SD", "M911", "Desert Eagle", "Binoculars", "Tear Gas", "Grenade", "Satchel", "Baseball Bat", "Shovel", "Golf Club", "Hunting Knife", "Hatchet" }, ["Municion"] = { --"M136 Rocket", "M4 Mag", "AK Mag", "Lee Enfield Mag", "CZ 550 Mag", "MP5A5 Mag", "PDW Mag", "SPAZ-12 Pellet", "2Rnd. Slug", "1866 Slug", "M9 SD Mag", "M911 Mag", "Desert Eagle Mag" }, ["Comida y bebidas"] = { "Water Bottle", "Pasta Can", "Beans Can", "Burger", "Pizza", "Soda Bottle", "Empty Water Bottle", "Empty Soda Cans", "Scruffy Burgers", "Milk", "Raw Meat", "Cooked Meat" }, ["Mochilas"] = { "Coyote Backpack", "Czech Backpack", "Assault Pack (ACU)", "Alice Pack" }, ["Herramientas"] = { "Box of Matches", "Infrared Goggles", "Night Vision Goggles", "GPS", "Map", "Toolbox", "Watch", "Radio Device" }, ["Medicinas"] = { "Bandage", "Morphine", "Medic Kit", "Heat Pack", "Blood Bag", "Painkiller", }, ["Partes de autos"] = { "Tire", "Engine", "Tank Parts" }, ["Skins"] = { "Camouflage[M] Clothing", "Civilian[M] Clothing", "Camouflage[F] Clothing", "Survivor[M] Clothing", "Ghillie[M] Suit", "Civilian[F] Clothing", "Survivor[F] Clothing", "Ghillie[F] Suit" }, ["Otros"] = { "Wood Pile", "Empty Gas Canister", "Full Gas Canister", "Roadflare", "Tent" } } local isItemSelected = false -- // Window creation code -- addEventHandler("onClientResourceStart", resourceRoot, function() w.main = guiCreateWindow(sW/2 - 179, sH/2 - 165, 358, 330, "Panel de Items [DeathRow]", false) guiWindowSetSizable(w.main, false) guiSetAlpha(w.main, 1.00) w.gridList.main = guiCreateGridList(10, 26, 151, 291, false, w.main) w.gridList.column = guiGridListAddColumn( w.gridList.main, "Player", 0.85 ) w.label.desc = guiCreateLabel(176, 26, 178, 22, "Choose a player from the GUI", false, w.main) guiSetFont(w.label.desc, "default-bold-small") w.label.desc2 = guiCreateLabel(233, 210, 60, 22, "Cantidad", false, w.main) guiSetFont(w.label.desc2, "default-bold-small") w.comboBox.category = guiCreateComboBox(171, 65, 266, 160, "-- Choose a category --", false, w.main) w.comboBox.itemList = guiCreateComboBox(171, 145, 266, 50, "-- Choose an item --", false, w.main) w.editBox.quantity = guiCreateEdit(231, 234, 55, 26, "", false, w.main) w.button.give = guiCreateButton(176, 280, 77, 37, "Give", false, w.main) w.button.close = guiCreateButton(263, 280, 77, 37, "Close", false, w.main) guiSetFont(w.button.give, "default-bold-small") guiSetProperty(w.button.give, "NormalTextColour", "FFAAAAAA") guiSetFont(w.button.close, "default-bold-small") guiSetProperty(w.button.close, "NormalTextColour", "FFAAAAAA") guiSetVisible(w.main, false) guiSetEnabled(w.button.give, false) for key, value in pairs (items) do if type(value) == "table" then guiComboBoxAddItem(w.comboBox.category, key) end end -- // Making quantity be only edited by numbers -- addEventHandler("onClientGUIChanged", w.editBox.quantity, function() guiSetText(source, guiGetText(source):gsub("[^0-9]","")) -- // We remove everything which is not a number check() end) -- // Changing second combobox items when first one changes -- addEventHandler("onClientGUIComboBoxAccepted", w.comboBox.category, function() local text = guiComboBoxGetItemText(w.comboBox.category, guiComboBoxGetSelected(w.comboBox.category)) guiComboBoxClear(w.comboBox.itemList) for i, st in ipairs(items[text]) do guiComboBoxAddItem(w.comboBox.itemList, st) end guiComboBoxAdjustHeight(w.comboBox.itemList, #items[text]) end ) -- // Showing item when second one was accepted. -- addEventHandler("onClientGUIComboBoxAccepted", w.comboBox.itemList, function() isItemSelected = true check() end ) -- // Handling button that closes. -- addEventHandler ( "onClientGUIClick", w.button.close, function() guiSetVisible(w.main, false) showCursor(false) end, false ) -- // Handling give button. -- addEventHandler ( "onClientGUIClick", w.button.give, function() local playerName = guiGridListGetItemText(w.gridList.main, guiGridListGetSelectedItem(w.gridList.main), 1) local item = guiComboBoxGetItemText(w.comboBox.itemList, guiComboBoxGetSelected(w.comboBox.itemList)) if (getPlayerFromName(playerName)) then triggerServerEvent("onGIPGive", localPlayer, playerName, item, tonumber(guiGetText(w.editBox.quantity))) else outputChatBox("El jugador no existe, o se cambio el nombre", 255, 0, 0) end guiSetVisible(w.main, true) showCursor(true) end, false ) addEventHandler("onClientGUIClick", w.gridList.main, check) end ) -- // Remi-X function. Sets height depending on item quantity -- function guiComboBoxAdjustHeight ( combobox, itemcount ) local width = guiGetSize ( combobox, false ) return guiSetSize ( combobox, width, ( itemcount * 20 ) + 20, false ) end -- // Handling when the administrator opens the panel -- -- // Handling when the administrator opens the panel -- addEventHandler("onGIPOpened", root, function() guiGridListClear ( w.gridList.main ) guiSetEnabled(w.button.give, false) isItemSelected = false for id, player in ipairs(getElementsByType("player")) do if player ~= localplayer then local row = guiGridListAddRow ( w.gridList.main ) guiGridListSetItemText ( w.gridList.main, row, w.gridList.column, getPlayerName ( player ), false, false ) end end guiSetVisible(w.main, true) showCursor(true) end ) function check() if guiGetText(w.editBox.quantity) ~= "" and isItemSelected and guiGridListGetItemText(w.gridList.main, guiGridListGetSelectedItem(w.gridList.main), 1) ~= "" then -- // If there's quantity guiSetEnabled(w.button.give, true) -- // We enable the button end end
  13. Lo que pasa es que cada vez que le doy restart a mi gamemode (dayz) se duplican los autos y es muy molesto cuando quiero agregar algo en al gamemode teniendo que quitar los autos extra alguien tiene una idea como arreglar esto talvez hacer un script para q los autos no puedan spawnear si ya ahi uno en ese lugar?
  14. tried it and still the same dont mean offend or anything but either im blind or you didnt change anything (sorry if im mistaken)
×
×
  • Create New...