Jump to content

dewu

Members
  • Posts

    171
  • Joined

  • Last visited

Everything posted by dewu

  1. Witam. Od jakiegoś czasu borykam się z problemem klatek na sekundkę w MTA. Przeniosłem się z laptopa, bo ten ze zintegrowaną grafiką ledwo uciągał 15 FPS na low detalach w MTA: DayZ. Komputer na który się przeniosłem, to: CPU: Intel Pentium 4 @ 2.4 GHz GPU: NVIDIA FX 5200 128mb/128bit RAM: 1 GB HDD: 40 GB Łącze: 512kb/s Aero2 (Ping ~80) System: Windows XP Professional Nie jest to jakiś rewelacyjny sprzęt, powiedziałbym antyk wręcz - ale spełnia rekomendowane wymagania do gry w MTA i ma dedykowaną kartę graficzną. Mimo to ilość FPS jaką osiągam, to: min.8/max.28/avg.20 Zainstalowane najlepiej zoptymalizowane sterowniki do serii FX (Vstudios 71.24), w panelu NVIDIA powyłączane wszystkie pierdoły, ustawiona wysoka wydajność, taktowanie karty zwiększone z 250/300 na 280/350. Komputer wyszyczony z kurzu, nałożona nowa pasta na procka i grafę oraz przeczyszczony system. Ustawione najniższe detale w MTA, wysoki priorytet, max. streaming memory, 800x600x16. Podmienione modele efektów 3D (/models/effects.fxp i particle.txd) oraz wgrany GTA San Andreas Low-End Patch v0.9. Wynik w 3DMark 2001 SE przed optymalizacją (na czysto): 5582 Wynik po optymalizacji (aktualnie): 6670 Szkoda, że w MTA wzrost tylko o jakieś 2-3 FPS. Dodatkowo powiem, że na lapku w Counter-Strike osiągałem ~30 FPS, na stacjonarce osiągam ~100, tylko z MTA jest duży problem. Próbowałem GameBoostera - pic na wodę fotomontaż. Póki co nie mam możliwości załatwienia/kupna nowej-starej karty graficznej, chcę wycisnąć wszystko co się da z tego zestawu. Jeżeli nie będzie wyjścia użyję GTA Shrinkera aby skompresować tekstury gry, choć i tak już teraz gra wygląda brzydko. Póki co, liczę na wasze sugestie - co mogę jeszcze zrobić?
  2. dewu

    Mask on face

    Hi guys. I want add Anonymous Masks into my server. Is this possible to do?
  3. Problem resolved, thanks for "help".
  4. Refresh Also i've tried by use setWeaponProperty: function doammo() setWeaponProperty(29, "pro", "maximum_clip_ammo", 1) setWeaponProperty(29, "std", "maximum_clip_ammo", 1) setWeaponProperty(29, "poor", "maximum_clip_ammo", 1) end addEventHandler("onClientResourceStart", getResourceRootElement(), doammo) nothing.
  5. Yeah, I've tried and I'm still learing from few days. But not understand how can I use setWeaponProperty to receive the desired effect. I asked for whole of that script, because my scripts don't works. And when I asked what's wrong in that what i wrote, but there where people helps other - you tell me to Learn the LUA If I had no had problems with it, i was never wrote there. Also, i've tried that: addEventHandler('onClientPlayerWeaponFire', localPlayer, function(weapon) if (getPedAmmoInClip == -1 ) then if( weapon == 29 ) then reloadPedWeapon ( weapon ) end end end) and it's too not works.
  6. I don't understand. How?
  7. I write something like that, but's not works, why? function rWep(source) local ammo = onClientPlayerWeaponFire ( source ) local wep = getPedWeapon( source ) if wep == 29 then if ammo then reloadPedWeapon ( source ) end end end end
  8. Just learn LUA, don't be lazy Thanks.
  9. Could you give me whole of script? I am newbie
  10. Hi guys. I was added new weapon (Crossbow) and now i want to set reload after one shot, is this possible? Weapon ID: 29 (MP5 in GTA).
  11. So, how to add new Weapon ID? If not, , maybe is way to duplicate Weapon ID (ex. 33 - Country Rifle) for ex. 32 (Tec-9)? I don't use Tec-9 ID and i want to have the same animation effects ingame like in Country-Rifle.
  12. dewu

    Flashlight bind

    Ok, works, thanks. Is this way to control the light ingame? I want to steer flashlight shader.
  13. I use weaponTXD = engineLoadTXD("items/crossbow.txd") engineImportTXD(weaponTXD, 372) weaponDFF = engineLoadDFF("items/crossbow.dff", 372) engineReplaceModel(weaponDFF, 372) weaponTXD = engineLoadTXD("items/lee_enfield.txd") engineImportTXD(weaponTXD, 357) weaponDFF = engineLoadDFF("items/lee_enfield.dff", 357) engineReplaceModel(weaponDFF, 357) it's really hard to explain, but I want to use one weapon ID to both. Please about some easier instructions
  14. So, what i should use it?
  15. Hi guys. I got the question, is this way to use one weapon ID to two Model ID's? Expample: {weapon id, model id}, {33, 357}, and i want: {33, 357 and 372}, I want to use same weapon ID's in two models of weapons. I'm newbie in LUA scriptering
  16. dewu

    Flashlight bind

    Yes! It is that what i mean but, don't know why it's not working. I've changed: -- start or stop using flashlight function toggleFlashLight() if flashLiTable.flModel[getLocalPlayer()] then outputChatBox('You have disabled the flashlight',0,255,0) triggerServerEvent("onSwitchLight",getLocalPlayer(),false) triggerServerEvent("onSwitchEffect",getLocalPlayer(),false) isLightOn = false unbindKey(switch_key,"down",toggleLight) else outputChatBox('You have enabled the flashlight',0,255,0) triggerServerEvent("onSwitchLight",getLocalPlayer(),false) triggerServerEvent("onSwitchEffect",getLocalPlayer(),true) bindKey(switch_key,"down",toggleLight) end end --------------------------------------------------------------------------------------------------- addEventHandler("onClientResourceStart", getResourceRootElement( getThisResource()), function() local ver = getVersion ().sortable local build = string.sub( ver, 9, 13 ) if build<"04938" or ver < "1.3.1" then outputChatBox('The resource is not compatible with this client version!',255,0,0) return end local isEffectValid if (vCardPSVer()~="3") then outputChatBox('Flashlight: Shader Model 3 not supported',255,0,0) isFullShader = false isEffectValid = createWorldLightShader(0) else isFullShader = true isEffectValid = createWorldLightShader(2) end if not isEffectValid then outputChatBox('Flashlight effect failed to start!',255,0,0) return else outputChatBox('Shader flashlight test ver 1.06 has started.',255,255,0) end engineImportTXD( engineLoadTXD( "objects/flashlight.txd" ), objID ) engineReplaceModel ( engineLoadDFF( "objects/flashlight.dff", 0 ), objID,true) triggerServerEvent("onPlayerStartRes",getLocalPlayer()) if autoEnableFL then toggleFlashLight() else outputChatBox('Type /flashlight to enable the flashlight ',255,255,0) end outputChatBox('Hit '..switch_key..' to turn on/off the flashlight',255,255,0) addCommandHandler("flashlight",toggleFlashLight) end ) to -- start or stop using flashlight function toggleFlashLight() if flashLiTable.flModel[getLocalPlayer()] then outputChatBox('You have disabled the flashlight',0,255,0) triggerServerEvent("onSwitchLight",getLocalPlayer(),false) triggerServerEvent("onSwitchEffect",getLocalPlayer(),false) isLightOn = false unbindKey("b","down",toggleLight) else outputChatBox('You have enabled the flashlight',0,255,0) triggerServerEvent("onSwitchLight",getLocalPlayer(),false) triggerServerEvent("onSwitchEffect",getLocalPlayer(),true) bindKey("b","down",toggleLight) end end --------------------------------------------------------------------------------------------------- addEventHandler("onClientResourceStart", getResourceRootElement( getThisResource()), function() local ver = getVersion ().sortable local build = string.sub( ver, 9, 13 ) if build<"04938" or ver < "1.3.1" then outputChatBox('The resource is not compatible with this client version!',255,0,0) return end local isEffectValid if (vCardPSVer()~="3") then outputChatBox('Flashlight: Shader Model 3 not supported',255,0,0) isFullShader = false isEffectValid = createWorldLightShader(0) else isFullShader = true isEffectValid = createWorldLightShader(2) end if not isEffectValid then outputChatBox('Flashlight effect failed to start!',255,0,0) return else outputChatBox('Shader flashlight test ver 1.06 has started.',255,255,0) end engineImportTXD( engineLoadTXD( "objects/flashlight.txd" ), objID ) engineReplaceModel ( engineLoadDFF( "objects/flashlight.dff", 0 ), objID,true) triggerServerEvent("onPlayerStartRes",getLocalPlayer()) if autoEnableFL then toggleFlashLight() else outputChatBox('Type /flashlight to enable the flashlight ',255,255,0) end outputChatBox('Hit '..switch_key..' to turn on/off the flashlight',255,255,0) end ) Also I deleted line with addCommandHandler
  17. dewu

    Flashlight bind

    Hmm.. so maybe is way to auto-exucute command when log-in?
  18. dewu

    Flashlight bind

    I create MTA: DayZ Server. I don't want to use it in single, but on my server where players to turn on/off light just must use a key without earlier binding.
  19. dewu

    Flashlight bind

    I don't mean command. I mean when i click ex. "B" button on the keyboard, flashlight will be turn on/off. In this res first i must type /flashlight command to enable.
  20. dewu

    Flashlight bind

    Hi guys, i got the question: How to set bind to turn on/off the flashlight, without use /flashlight command? https://community.multitheftauto.com/ind ... ls&id=6858 can be another script, but with bind function and without command runs.
  21. Hi guys. I create MTA: DayZ server and i have strange problem with playSound ingame. This script works and play mp3: if loot and not getElementData(loot, "itemloot") and getElementType(getElementData(loot, "parent")) == "vehicle" and itemName == "Full Gas Canister" then if getElementData(loot, "fuel") + 20 < getVehicleMaxFuel(loot) then addingfuel = 20 elseif getElementData(loot, "fuel") + 20 > getVehicleMaxFuel(loot) + 15 then triggerEvent("displayClientInfo", getLocalPlayer(), "Vehicle", "The fuel tank is 100% full up.", 255, 22, 0) return else addingfuel = getVehicleMaxFuel(loot) - getElementData(loot, "fuel") end setElementData(loot, "fuel", getElementData(loot, "fuel") + addingfuel) setElementData(getLocalPlayer(), itemName, getElementData(getLocalPlayer(), itemName) - itemPlus) setElementData(getLocalPlayer(), "Empty Gas Canister", (getElementData(getLocalPlayer(), "Empty Gas Canister") or 0) + itemPlus) triggerEvent("displayClientInfo", getLocalPlayer(), "Vehicle", "You filled a few liters of fuel into the vehicle!", 22, 255, 0) playSound("sounds/refuel.mp3") return end but that's not: function hideRightClickInventoryMenu() guiSetVisible(rightclickWindow, false) end function onPlayerClickOnRightClickMenu(button, state) if button == "left" then local itemName, itemInfo = getElementData(rightclickWindow, "iteminfo")[1], getElementData(rightclickWindow, "iteminfo")[2] hideRightClickInventoryMenu() playerUseItem(itemName, itemInfo) end end addEventHandler("onClientGUIClick", headline.rightclickmenu, onPlayerClickOnRightClickMenu, false) local playerFire = {} local fireCounter = 0 function playerUseItem(itemName, itemInfo) if itemInfo == "Drink" then triggerServerEvent("onPlayerRequestChangingStats", getLocalPlayer(), itemName, itemInfo, "thirst") playSound("sounds/drink.mp3") elseif itemInfo == "Eat" then triggerServerEvent("onPlayerRequestChangingStats", getLocalPlayer(), itemName, itemInfo, "food") playSound("sounds/eat.mp3") elseif itemInfo == "Use Skin" then triggerServerEvent("onPlayerChangeSkin", getLocalPlayer(), itemName) playSound("sounds/wear.mp3") elseif itemName == "Empty Water Bottle" then triggerServerEvent("onPlayerRefillWaterBottle", getLocalPlayer(), itemName) playSound("sounds/fill.mp3") elseif itemName == "Tent" then triggerServerEvent("onPlayerPitchATent", getLocalPlayer(), itemName) playSound("sounds/tent.mp3") elseif itemInfo == "Place Wire Fence" then triggerServerEvent("onPlayerBuildAWireFence", getLocalPlayer(), itemName) playSound("sounds/fence.mp3") elseif itemName == "Roadflare" then triggerServerEvent("onPlayerPlaceRoadflare", getLocalPlayer(), itemName) playSound("sounds/flare.mp3") elseif itemInfo == "Set fire" then triggerServerEvent("onPlayerMakeAFire", getLocalPlayer(), itemName) playSound("sounds/fire.mp3") elseif itemInfo == "Use" then triggerServerEvent("onPlayerUseMedicObject", getLocalPlayer(), itemName) playSound("sounds/bandage.mp3") elseif itemName == "Bandage" then triggerServerEvent("onPlayerUseMedicObject", getLocalPlayer(), itemName) playSound("sounds/bandage.mp3") elseif itemInfo == "Use Googles" then triggerServerEvent("onPlayerChangeView", getLocalPlayer(), itemName) elseif itemInfo == "Equip Primary Weapon" then triggerServerEvent("onPlayerRearmWeapon", getLocalPlayer(), itemName, 1) playSound("sounds/primary.mp3") elseif itemInfo == "Equip Secondary Weapon" then triggerServerEvent("onPlayerRearmWeapon", getLocalPlayer(), itemName, 2) playSound("sounds/secondary.mp3") elseif itemInfo == "Equip Special Weapon" then triggerServerEvent("onPlayerRearmWeapon", getLocalPlayer(), itemName, 3) playSound("sounds/specially.mp3") end end What i was do wrong? I am amateur scripter, i learns LUA alone.
×
×
  • Create New...