Jump to content

Aruna

Members
  • Posts

    72
  • Joined

  • Last visited

Everything posted by Aruna

  1. Hola, le queria contar el problema que me tira este script, Cuando uno se acerca alguna gasolinera del servidor no aparese los carteles o mensajes de que precionen "J" "-" para abrir o recargar gasolina, pienso que los patrol estan mal configurado. Este Vendria siendo el script completo. --[[ #---------------------------------------------------------------# ----* DayZ MTA Script menu_client.lua *---- ----* Script *---- ----* New additions and functions by: Unknown *---- #---------------------------------------------------------------# ]] local theTableMenuScroll = {} function createScrollMenuMessage(text, r, g, b, data) table.insert(theTableMenuScroll,{text,r,g,b,data}) end function showClientMenuItem(arg1,arg2,arg3,arg4) theTableMenuScroll = {} setElementData(getLocalPlayer(),"usedItem",false) numberMenuScroll = 1 if arg1 == "Take" then createScrollMenuMessage("Take "..arg2,255,255,255,arg2) setElementData(getLocalPlayer(),"usedItem",true) end if arg1 == "stop" then disableMenu() refreshLoot(false) end if arg1 == "Helicrashsite" then createScrollMenuMessage("Gear Helicrash",255,255,255,"helicrashsite") setElementData(getLocalPlayer(),"usedItem",true) end if arg1 == "Hospitalbox" then createScrollMenuMessage("Gear Hospitalbox",255,255,255,"hospitalbox") setElementData(getLocalPlayer(),"usedItem",true) end if arg1 == "Vehicle" then createScrollMenuMessage("Gear ("..arg2..")",255,255,255,"vehicle") setElementData(getLocalPlayer(),"usedItem",true) if getElementData(getElementData(arg3,"parent"),"tent") then createScrollMenuMessage("Remove Tent",255,255,255,"tent") return end if getElementHealth(arg3) <= 999 and getElementData(getLocalPlayer(),"Toolbox") >= 1 then createScrollMenuMessage("Repair ("..arg2..")",255,255,255,"repairvehicle") setElementData(getLocalPlayer(),"usedItem",true) end if getElementData(getLocalPlayer(),"Toolbox") >= 1 then createScrollMenuMessage("Remove Tire ("..arg2..")",255,255,255,"removetire") setElementData(localPlayer,"usedItem",true) end if getElementData(getLocalPlayer(),"Toolbox") >= 1 then createScrollMenuMessage("Remove Engine ("..arg2..")",255,255,255,"removeengine") setElementData(localPlayer,"usedItem",true) end end if arg1 == "Player" then if 0 < getElementData(arg2, "bleeding") and 1 <= getElementData(getLocalPlayer(), "Bandage") then number = number + 1 guiSetVisible(spalteGuiImage[number], true) guiSetText(spalteGuiText[number], "Give Bandage") guiLabelSetColor(spalteGuiText[1], 50, 255, 50) setElementData(spalteGuiText[1], "markedMenuItem", true) setElementData(spalteGuiText[number], "usedItem", "bandage") end if getElementData(arg2, "blood") < 11900 and 1 <= getElementData(getLocalPlayer(), "Blood Bag") then number = number + 1 guiSetVisible(spalteGuiImage[number], true) guiSetText(spalteGuiText[number], "Administer Blood Bag") setElementData(spalteGuiText[number], "usedItem", "giveblood") if number == 1 then guiLabelSetColor(spalteGuiText[number], 50, 255, 50) setElementData(spalteGuiText[number], "markedMenuItem", true) end end end if arg1 == "Dead" then createScrollMenuMessage("Gear ("..arg2..")",255,255,255,"dead") createScrollMenuMessage("Check Body",255,255,255,"deadreason") setElementData(getLocalPlayer(),"usedItem",true) if getElementData(getLocalPlayer(),"Shovel") >= 1 then createScrollMenuMessage("Hide Body",255,255,255,"hidebody") setElementData(getLocalPlayer(),"usedItem",true) end end if arg1 == "Fireplace" then if getElementData(getLocalPlayer(),"Raw Meat") >= 1 then createScrollMenuMessage("Cook Meat",255,255,255,"fireplace") setElementData(getLocalPlayer(),"usedItem",true) end end if arg1 == "patrol" then if getElementData(getLocalPlayer(),"Jerry Can (Empty)") >= 1 then createScrollMenuMessage("Refill Jerry Can (Empty)",255,255,255,"patrolstation") --setElementData(getLocalPlayer(),"usedItem",true) setElementData(getLocalPlayer(), "usedItem", "patrolstation") end end if arg1 == "Wirefence" then if getElementData(getLocalPlayer(),"Toolbox") >= 1 then createScrollMenuMessage("Remove Wire Fence",255,255,255,"wirefence") --setElementData(getLocalPlayer(),"usedItem",true) setElementData(getLocalPlayer(), "usedItem", "wirefence") end end if arg1 == "Bottle" then if getElementData(getLocalPlayer(),"Empty Water Bottle") >= 1 then createScrollMenuMessage("Refill Empty Water Bottle",255,255,255,"bottle") setElementData(getLocalPlayer(),"usedItem",true) end end if arg1 == "Gear" then createScrollMenuMessage("Gear",255,255,255,"itemloot") --setElementData(getLocalPlayer(),"usedItem",true) setElementData(getLocalPlayer(), "usedItem", "itemloot") end numberMenuScroll = 1 end addEvent("showClientMenuItem",true) addEventHandler("showClientMenuItem",getLocalPlayer(),showClientMenuItem) function startScrollMenu(key,keyState,arg) if getElementData(getLocalPlayer(),"usedItem") then if (keyState == "down") then if arg == "up" then numberMenuScroll = numberMenuScroll-1 if numberMenuScroll < 1 then numberMenuScroll = #theTableMenuScroll end elseif arg == "down" then numberMenuScroll = numberMenuScroll+1 if numberMenuScroll > #theTableMenuScroll then numberMenuScroll = 1 end end end end end bindKey("mouse_wheel_up","down",startScrollMenu,"up") bindKey("mouse_wheel_down","down",startScrollMenu,"down") function disableMenu() theTableMenuScroll = {} setElementData(getLocalPlayer(),"usedItem",false) setNewbieInfo (false,"","") end addEvent("disableMenu",true) addEventHandler("disableMenu",getLocalPlayer(),disableMenu) function getPlayerInCol(tab) for theKey,thePlayer in ipairs(tab) do if thePlayer ~= getLocalPlayer() then return true end end return false end isInFirePlace = false function onPlayerTargetPickup (theElement) if theElement == getLocalPlayer() then if getElementData(source,"parent") == getLocalPlayer() then return end local player = getPlayerInCol(getElementsWithinColShape ( source, "player" )) if getPedOccupiedVehicle(getLocalPlayer()) then return end isInFirePlace = false if getElementData(source,"player") then showClientMenuItem("Player",getElementData(source,"parent")) setElementData(getLocalPlayer(),"currentCol",source) setElementData(getLocalPlayer(),"loot",false) return end if player then return end if getElementData(source,"patrolstation") then showClientMenuItem("patrol") setElementData(getLocalPlayer(),"currentCol",source) setElementData(getLocalPlayer(),"loot",false) setNewbieInfo(true,"Jerry Can (Empty)","Press '-' or 'middle-mouse' to refill a jerry can! \nREQUIRED: Jerry Can (Empty)",source) return end if getElementData(source,"bottlestation") then showClientMenuItem("Bottle Station") setElementData(getLocalPlayer(),"currentCol",source) setElementData(getLocalPlayer(),"loot",false) setNewbieInfo(true,"Water Bottle","Press '-' or 'middle-mouse' to refill a water bottle ! \nREQUIRED: Empty Water Bottle",source) return end if getElementData(source,"wirefence") then showClientMenuItem("Wirefence") setElementData(getLocalPlayer(),"currentCol",source) setElementData(getLocalPlayer(),"loot",false) setNewbieInfo(true,"Wirefence","Press '-' or 'middle-mouse' to remove the fence! \nREQUIRED: Toolbox",source) return end if getElementData(source,"fireplace") then showClientMenuItem("Fire Place") setElementData(getLocalPlayer(),"currentCol",source) setElementData(getLocalPlayer(),"loot",false) setNewbieInfo(true,"Fire Place","Press '-' or 'middle-mouse' to cook meat! \nREQUIRED: Raw Meat",source) isInFirePlace = true return end if getElementData(source,"deadman") then showClientMenuItem("Dead",getElementData(source,"playername")) setElementData(getLocalPlayer(),"currentCol",source) setElementData(getLocalPlayer(),"loot",true) setElementData(getLocalPlayer(),"lootname","Gear ("..getElementData(source,"playername")..")") setNewbieInfo(true,"Gear","Press J to access the gear menu!",source) return end if getElementData(source,"item") then showClientMenuItem("Take",getElementData(source,"item")) setElementData(getLocalPlayer(),"currentCol",source) setElementData(getLocalPlayer(),"loot",false) setNewbieInfo(true,"Item pickup","Press '-' or 'middle-mouse' to pick this item up!",source) return end if getElementData(source,"helicrash") then showClientMenuItem("Helicrash","helicrash") setElementData(getLocalPlayer(),"currentCol",source) setElementData(getLocalPlayer(),"loot",true) setElementData(getLocalPlayer(),"lootname","Gear (Helicrash)") setNewbieInfo(true,"Gear Helicrash","Press J to access the gear menu!",source) return end if getElementData(source,"hospitalbox") then showClientMenuItem("Hospitalbox","hospitalbox") setElementData(getLocalPlayer(),"currentCol",source) setElementData(getLocalPlayer(),"loot",true) setElementData(getLocalPlayer(),"lootname","Gear (Hospitalbox)") setNewbieInfo(true,"Gear Hospitalbox","Press J to access the gear menu!",source) return end if getElementData(source,"vehicle") then if not getElementData(source,"deadVehicle") then showClientMenuItem("Vehicle",(getVehicleName(getElementData(source,"parent")) or "Tent"),getElementData(source,"parent")) setElementData(getLocalPlayer(),"currentCol",source) setElementData(getLocalPlayer(),"loot",true) setElementData(getLocalPlayer(),"lootname","Gear ("..(getVehicleName(getElementData(source,"parent")) or "Tent")..")") setNewbieInfo(true,"Gear","Press J to acess the gear menu!",source) return end end if getElementData(source,"itemloot") then showClientMenuItem("Gear") setElementData(getLocalPlayer(),"loot",true) setElementData(getLocalPlayer(),"lootname","Gear") setElementData(getLocalPlayer(),"currentCol",source) setNewbieInfo(true,"Gear","Press J to access the gear menu!",source) return
  2. Gracias Tomas me sirvio a mi
  3. Hola quisiera saber como se llama este resource, porque creo que no esta disponible en la comunidad mta es uno de FPS y Ping por milisegundo Gracias de antemano
  4. como defino player con source o theplayer??
  5. Es un GUI WTF oshe alex me ama jajaja Aca esta el GUI function BuyWeaponOnServer(weapon_name,data,value) name = getPlayerName ( source ) if(weapon_name == "Equiparme") then setElementData(source, "MAX_Slots" , 125) setElementData(source, "CZ 550", 1) setElementData(source, "CZ 550 Mag", 25) setElementData(source, "M4", 1) setElementData(source, "M4 Mag", 260) setElementData(source, "Milk", 2) setElementData(source, "Pizza", 2) setElementData(source, "Medic Kit", 2) setElementData(source, "Morphine", 2) setElementData(source, "Blood Bag", 1) setElementData(source, "Infrared Goggles", 1) setElementData(source, "Civilian[F] Clothing", 1) setElementData(source, "Map", 1) setElementData(source, "GPS", 1) setElementData(source, "Toolbox", 1) setElementData(source, "PDW", 1) setElementData(source, "PDW Mag", 100) setElementData(source, "Night Vision Goggles", 1) setElementData(source, "Radio Device", 1) setElementData(source, "Watch", 1) outputChatBox("#FFff00[VIP-#ff0000"..name.."#FFff00] #FFFFFFha usado el Kit de Vip", getRootElement(), 255, 255, 255 , true) end if(weapon_name == "SpawnSanchez") then outputChatBox("#FFFF00[VIP] #FFFFFF Este comando esta #FF0000DESACTIVADO#FFFFFF !", source, 255, 255, 255 , true) end if(weapon_name == "Spawnpatriot") then outputChatBox("#FFFF00[VIP] #FFFFFF Este comando esta #FF0000DESACTIVADO #FFFFFF !", source, 255, 255, 255 , true) end if(weapon_name == "slotsmochila") then setElementData(source, "MAX_Slots", 125) outputChatBox("#FFFF00[VIP] #FFFFFF Ahora su mochila tiene 125 slot !", source, 255, 255, 255 , true) end end addEvent("onClientGiveWeapon", true) addEventHandler("onClientGiveWeapon", getRootElement(), BuyWeaponOnServer)
  6. Puede que sea un error del Dayz, bajatelo de la comunidad en la última versión. Recuerdo que ya avisaron de ese bug en una de las actualizaciones, pero que ya fue fixeado. Edita el archivo weather.lua copia este codigo y pegalo en tu weather.lua local realtime = getRealTime() setTime(realtime.hour, realtime.minute) setMinuteDuration(60000) setSkyGradient(0, 100, 196, 136, 170, 212) setFarClipDistance(1000) setFogDistance(100) function checkSetTime() local realtime = getRealTime() setTime(realtime.hour, realtime.minute) setMinuteDuration(60000) end setTimer(checkSetTime,60000,0) function setWeather2() local number = math.random(1,6) if number == 2 then setWeather ( 7 ) elseif number == 3 then setWeather ( 12 ) elseif number == 4 then setWeather ( 7 ) elseif number == 5 then setWeather ( 4 ) end end setTimer(setWeather2,3600000,0) setWeather2() function setNight (hour,minutes) if hour == 21 then setSkyGradient(0, 100/minutes, 196/minutes, 136/minutes, 170/minutes, 212/minutes) setFarClipDistance(750) setFogDistance(10) elseif hour == 7 then setSkyGradient( 0, 1.6*minutes, 196*3.26, 136*2.26, 170*2.83, 212*3.53 ) setFarClipDistance(220+(minutes*14.6)) setFogDistance(100+(minutes*4.16)) elseif hour == 22 or hour == 23 then setSkyGradient( 0, 0, 0, 0, 0, 0 ) setFarClipDistance(750) setFogDistance(10) elseif hour >= 0 and hour <= 7 then setSkyGradient( 0, 0, 0, 0, 0, 0 ) setFarClipDistance(750) setFogDistance(10) else setSkyGradient(0, 100, 196, 136, 170, 212) setFarClipDistance(1000) setFogDistance(10) end end function setNightTime() if not gameplayVariables["enablenight"] then return end local hour, minutes = getTime() setNight (hour,minutes) end setTimer(setNightTime,60000,0) setNightTime()
  7. Hola, quisiera saber como podria colocarle un tiempo de espera al sacar este objeto desde un panel. Esto vendria siendo la linea del script de la funcion que le da el objeto function VidaeColete() name = getPlayerName ( source ) setElementData(source,"M4 Mag",getElementData(source,"M4 Mag") + 60) outputChatBox("#FFFF00[VIP-#ff0000"..name.."#FFff00] #FFFFFF Ha sacado 60 balas de M4", getRootElement(), 255, 255, 255 , true) end addEvent("M4MAG", true) addEventHandler("M4MAG", getRootElement(), VidaeColete) y como haria para cuando un usuario saque este objeto pueda volver a sacarlo nuevamente dentro de 5 minutos??
  8. 1)_ Tienes que editar los archivos lua "editor_server"y "editor_client" donde dice gameplayVariables["enablenight"] = true cambialo a false en los 2 archivos el el server y en el client. 2)Tienes que Scriptearlos, ya el dayz trae la sanchez, patriot, bobcat quad, regina y dodo de defecto tienes que descargar el resource de VSP Vehicle System Spawn algo asi se llama donde tu podras hacer spawn de autos con los comandos /spawnpatriot 3)Tienes que hacer un mapeo primero y dsp guardarlo y subirlo a tu sv.
  9. setTimer(setElementPosition, 500, 1, source, 6000, 6000, 0) triggerClientEvent(source, "onClientPlayerDeathInfo", source) setAccountData(account, "isDead", true) setElementData(source, "isDead", true) triggerClientEvent("onRollMessageStart", getRootElement(), "#FFFFFF" .. getPlayerName(source) .. " #FFFFFFha muerto", 0, 22, 255, "died") destroyElement(getElementData(source, "playerCol")) setTimer(spawnDayZPlayer, 5000, 1, source) end Lo que hace este codigo es cuando el usuario muere, pierda todo lo que tenga en su inventario por eso esta el desdroy
  10. seguro que si porque en el Debugscritp 3 y en la consola me tira el mismo error
  11. Igual al colocar el string ahora me dice que no puede encontrar al argumento 1 function weaponSwitchBack(previousWeaponID, currentWeaponID) local weapon1 = getElementData(source, "currentweapon_1") if not weapon1 then return end local ammoData1, weapID1 = getWeaponAmmoType(weapon1) local x, y, z = getElementPosition(source) local rx, ry, rz = getElementRotation(source) if previousWeaponID == weapID1 then if elementWeaponBack[source] then setElementID(player, "elementWeaponBack[source]") detachElementFromBone(elementWeaponBack[source]) destroyElement(elementWeaponBack[source]) elementWeaponBack[source] = false end elementWeaponBack[source] = createObject(getWeaponObjectID(weapID1), x, y, z) setObjectScale(elementWeaponBack[source], 0.875) if elementBackpack[source] then attachElementToBone(elementWeaponBack[source], source, 3, 0.19, -0.31, -0.1, 0, 270, -90) else attachElementToBone(elementWeaponBack[source], source, 3, 0.19, -0.11, -0.1, 0, 270, 10) end elseif currentWeaponID == weapID1 then setElementID(player, tostring(elementWeaponBack[source])) detachElementFromBone(elementWeaponBack[source]) destroyElement(elementWeaponBack[source]) elementWeaponBack[source] = false end end
  12. Hola aca yo entiendo que me quiere decir que el elemento "destroyelement" que no especifica el argumento 1 del booleando que tengo que eliminar?.. --[[ #---------------------------------------------------------------# ----* DayZ MTA Script spawn.lua *---- ----*. ----* C.r ----* ga ----* *---- #---------------------------------------------------------------# ]] local spawnPositions = { { -697.66729736328, 1610.0223388672, 1300.044586181641 }, { -699.19360351563, 946.80822753906, 1300.324913978577 }, { 174.79534912109, 148.06318664551, 1300.1025438308716 }, { -1425.1381835938, 2167.8332519531, 1300.843318939209 }, { -278.6669921875, -2882.1572265625, 1300.104232788086 }, { -958.5595703125, -2887.9912109375, 1300.82421875 }, { -1816.9375, -2748.18359375, 1300.7327127456665 }, { -2816.166015625, -2439.0546875, 1300.4004096984863 }, { -2941.5673828125, -1206.2373046875, 1300.7848854064941 }, { -2911.51171875, -895.22265625, 1300.4013109207153 }, { -2185.6669921875, 2957.380859375, 1300.474840164185 }, { 272.2265625, 2928.505859375, 1300.3713493347168 }, { 2803.943359375, 595.9365234375, 1300.7612648010254 }, { 2883.7509765625, -178.4658203125, 1300.2714653015137 }, { -233.46484375, -1735.8173828125, 1300.5520644187927 }, { -1056.8720703125, 2939.068359375, 1300.311294555664 } } local playerDataTable = { {"alivetime"}, {"skin"}, {"MAX_Slots"}, {"bandit"}, {"blood"}, {"food"}, {"thirst"}, { "temperature" }, { "currentweapon_1" }, { "currentweapon_2" }, { "currentweapon_3" }, {"bleeding"}, {"brokenbone"}, {"pain"}, {"cold"}, {"infection"}, {"humanity"}, { "zombieskilled" }, {"headshots"}, {"murders"}, { "banditskilled" }, {"Wood Pile"}, {"Bandage"}, { "Bouteille" }, {"Pasta Can"}, {"Beans Can"}, {"Burger"}, { "Box of Matches" }, {"M1911 Mag"}, {"M9 SD Mag"}, { "Desert Eagle Mag" }, {"M1911"}, {"M9 SD"}, { "Winchester 1866" }, {"PDW"}, { "Hunting Knife" }, {"Hatchet"}, {"Pizza"}, {"Morphine"}, { "Soda Bottle" }, { "Empty Gas Canister" }, { "Full Gas Canister" }, {"Roadflare"}, {"Milk"}, {"PDW Mag"}, {"MP5A5 Mag"}, {"AK Mag"}, {"M4 Mag"}, {"Tear Gas"}, {"Grenade"}, { "Desert Eagle" }, { "Sawn-Off Shotgun" }, { "SPAZ-12 Combat Shotgun" }, {"MP5A5"}, {"Watch"}, {"Medic Kit"}, {"Heat Pack"}, { "Lee Enfield" }, {"PDW"}, {"AK-47"}, {"Blood Bag"}, {"GPS"}, {"Map"}, {"Toolbox"}, {"Wire Fence"}, {"Tire"}, {"Engine"}, {"Tank Parts"}, {"CZ 550 Mag"}, { "Lee Enfield Mag" }, {"M4"}, {"CZ 550"}, {"Satchel"}, { "Infrared Goggles" }, { "Night Vision Goggles" }, {"Tent"}, {"Raw Meat"}, { "Cooked Meat" }, { "Camouflage Clothing" }, { "Ghillie Suit" }, { "Ghillie[F] Suit" }, { "Civilian Clothing" }, { "Civilian[F] Clothing" }, { "Survivor Clothing" }, { "Survivor[F] Clothing" }, {"Painkiller"}, { "Empty Water Bottle" }, { "Empty Soda Cans" }, { "Scruffy Burgers" }, {"1866 Slug"}, {"2Rnd. Slug"}, { "SPAZ-12 Pellet" }, {
  13. Este Seria editado con la cadena de tostring Tomas??
  14. Hola a todos, quisiera saber a que viene este Problemita en la Game Mode de Dayz y como podria solucionarlo ya que esto me consume mucha ram del hosting. function weaponSwitchBack(previousWeaponID, currentWeaponID) local weapon1 = getElementData(source, "currentweapon_1") if not weapon1 then return end local ammoData1, weapID1 = getWeaponAmmoType(weapon1) local x, y, z = getElementPosition(source) local rx, ry, rz = getElementRotation(source) if previousWeaponID == weapID1 then if elementWeaponBack[source] then setElementID(player, "elementWeaponBack[source]") detachElementFromBone(elementWeaponBack[source]) destroyElement(elementWeaponBack[source]) elementWeaponBack[source] = false end elementWeaponBack[source] = createObject(getWeaponObjectID(weapID1), x, y, z) setObjectScale(elementWeaponBack[source], 0.875) if elementBackpack[source] then attachElementToBone(elementWeaponBack[source], source, 3, 0.19, -0.31, -0.1, 0, 270, -90) else attachElementToBone(elementWeaponBack[source], source, 3, 0.19, -0.11, -0.1, 0, 270, 10) end elseif currentWeaponID == weapID1 then setElementID(player, elementWeaponBack[source]) detachElementFromBone(elementWeaponBack[source]) destroyElement(elementWeaponBack[source]) elementWeaponBack[source] = false end end desde ya muchas Gracias
  15. Hola alguien sabe sobre este problema que no falla el scipts de DayZ
  16. Hola buenas Tardes, quisiera saber como solucionar el BUG de animación que tengo en mi servidor de DayZ Osea al usar Bendage, Painkiller, Morfina y Medikit se quedan bugueado repitiendo la misma Animación de forma que se desbuguea con la animacion "Default" la (L, la coma y el punto). Que Archivo tengo que reparar para eliminar esas varias repeticiones de Animaciones? Muchas Gracias
  17. Ese mismo estoy usando VPS Windows Server 2008, pero tengo problemas con lag, no se si es mi sv o El Problema de Latenci del host
  18. Ok, puede ser porque tengo problemas con el host estube en Game Hosting, me pase a VPS Windows y me dicen que pruebe con Linux Debian 64 bits para ver como es la conexion del servidor
  19. Hola quisiera saber como reparar este problema del servidor de un mta Error CD16 Disconnected: connection to the server was lost Gracias por su ayuda
  20. Hola a todos soy nuevo en la comunidad de MTA. Primero que nada Un gusto conocerlo, me podrian ayudar a como montar un server de Mta DayZ a un VPS GNU/Linux, porque yo tengo montado el server en VPS Windows y la verdad que el linux cambia mucho con el tema de la consola.. Necesitaria su ayuda de alguna pagina que expliquen o tutoriales que me ayuden a familiarizarme con los codigos SSH. Gracias un Saludo a Todos El Host lo estoy comprando de BBhosting.net
×
×
  • Create New...