Jump to content

Kenix

Retired Staff
  • Posts

    4,121
  • Joined

  • Last visited

  • Days Won

    2

Everything posted by Kenix

  1. wtf line 7 ...... ololol setTimer (clear1,60000,1, false)
  2. они нубы просто и всё что тут думать (нормальные люди перебираются в мта)
  3. 1.use https://wiki.multitheftauto.com/wiki/SetSoundVolume 2.0 not work only works up to 1 volume 2.use setTimer (clear1,60000,1, false) 3.use https://wiki.multitheftauto.com/wiki/GetElementsByType
  4. Interstate 69 is deprecated use command upgrade for it
  5. https://community.multitheftauto.com/index.php?p= ... ls&id=1655 https://community.multitheftauto.com/index.php?p= ... ls&id=1654 https://community.multitheftauto.com/index.php?p= ... ls&id=1653
  6. Kenix

    script bad work

    Thanks but as if to fix server side?
  7. problem with the definition of a player from any team. is a question of how to make that sound is played only once and stopped without timers? server side ------------------- sound events --------------------------------- ------------------- when zombies die ----------------------------- addEventHandler( "onPlayerWasted", getRootElement( ), function() if getElementType(player) == "player" then local team = getPlayerTeam" class="kw2">getPlayerTeam" class="kw2">getPlayerTeam(player) if team and getTeamName(team) == "Zombies" then triggerClientEvent (source,"onzombiedie", source) end end end) ------------------- when the survivor died ----------------------- addEventHandler( "onPlayerWasted", getRootElement( ), function() if getElementType(player) == "player" then local team = getPlayerTeam" class="kw2">getPlayerTeam(player) if team and getTeamName(team) == "Survivors" then triggerClientEvent (source,"onsurvivorsdie", source) end end end) ------------------ when zombie killed survivor -------------------- function zombiekilling () if killer ~= nil and killer ~= false and getElementType(player) == "player" then local team = getPlayerTeam" class="kw2">getPlayerTeam" class="kw2">getPlayerTeam(player) if team and getTeamName(team) == "Zombies" then triggerClientEvent (source,"onzombiekill", source) end end end ----------------- when the survivor has killed the zombie ------------------------ function survivorskilling () if killer ~= nil and killer ~= false and getElementType(player) == "player" then local team = getPlayerTeam" class="kw2">getPlayerTeam(player) if team and getTeamName(team) == "Survivors" then triggerClientEvent (source,"onSurvivorskill", source) end end end client side local x,y,z = getElementPosition() addEvent("onzombiedie",true) addEventHandler( "onzombiedie", getLocalPlayer(), function( ) zombiediesounds = playSound( "sounds/zombies/die" .. tostring( math.random( 1, 3 ) ) .. ".mp3", x,y,z, true ) setSoundVolume(zombiediesounds, 0.9) setSoundMaxDistance(zombiediesounds, 10) setTimer(function() stopSound( zombiediesounds ) end, 3000, 1) end) addEvent("onsurvivorsdie",true) addEventHandler( "onsurvivorsdie", getLocalPlayer(), function( ) survivordiesounds = playSound( "sounds/humans/dead" .. tostring( math.random( 1, 4 ) ) .. ".mp3", x,y,z, true ) setSoundVolume(survivordiesounds, 0.9) setSoundMaxDistance(survivordiesounds, 10) setTimer(function() stopSound( survivordiesounds ) end, 3000, 1) end) addEvent("onzombiekill",true) addEventHandler( "onzombiekill", getLocalPlayer(), function( ) zombiekillsounds = playSound( "sounds/zombies/attack" .. tostring( math.random( 1, 5 ) ) .. ".mp3", x,y,z, true ) setSoundVolume(zombiekillsounds, 0.9) setSoundMaxDistance(zombiekillsounds, 10) setTimer(function() stopSound( zombiekillsounds ) end, 3000, 1) end) addEvent("onsurvivorskill",true) addEventHandler( "onsurvivorskill", getLocalPlayer(), function( ) survivorkillsounds = playSound( "sounds/humans/attack" .. tostring( math.random( 1, 4 ) ) .. ".mp3", x,y,z, true ) setSoundVolume(survivorkillsounds, 0.9) setSoundMaxDistance(survivorkillsounds, 10) setTimer(function() stopSound( survivorkillsounds ) end, 3000, 1) end)
  8. https://community.multitheftauto.com/index.php?p= ... ls&id=1650 https://community.multitheftauto.com/index.php?p= ... ls&id=1651 https://community.multitheftauto.com/ind ... ls&id=1649 car mods
  9. Kenix

    Mission question

    Thank you cool dude:)
  10. Kenix

    Mission question

    I wanted to do for the mission checkpoints example: but it does not work. local localplayer = getLocalPlayer() function Markers ( hitElement, matchingDimension ) local testnum = getElementData ( localPlayer, "test" ) destroyElement ( test ) if testnum == 1 then test = createMarker ( 1058.8583984375,1375.248046875,10.446697235107, "checkpoint" ) end if testnum == 2 then test = createMarker ( 1005.3486328125,1334.0693359375,10.419406890869, "checkpoint" ) end if testnum == 3 then test = createMarker ( 1029.42578125,1190.646484375,10.588260650635, "checkpoint" ) end setElementData ( localPlayer, "test", testnum + 1 ) addEventHandler( "onClientMarkerHit", test, Markers ) end
  11. how to make the mission without a single marker and more?
  12. Kenix

    Math Money

    You can use this way. local money ={} money[0] = { "10"} -- amount of money money[1] = { "20"} money[2] = {"100"}
  13. open console and add command debugscript 3 (1-3 0-off) if you are admin
  14. My script does not like do not fix it?
  15. nothing works more than one class is not noheadzombies not speedzombies etc. debugscript 1-3 did not write errors and outputChatBox("1") -- does not work does not operate below 6 line
  16. fix it,but still not working client side addEvent("onbronezombies",true) addEventHandler( "onbronezombies", getLocalPlayer(), function(zombie) setGameSpeed (1) end ) addEvent("onspeedzombies",true) addEventHandler( "onspeedzombies", getLocalPlayer(), function(zombie) setGameSpeed (1.2) end ) server side function zombieclasses ( zombie ) if not zombie then return end local skinID = getElementModel(zombie) if not skinID then return end if table.have( bronezombies, skinID ) then triggerClientEvent (source,"onbronezombies", source) setPedGravity (zombie,0.008) elseif table.have( noheadzombies, skinID ) then setPedHeadless( zombie, true ) elseif table.have( speedzombies, skinID ) then triggerClientEvent (source,"onspeedzombies", source) setPedStat ( zombie, 24, 500 ) -- но меньше жизек setElementHealth (zombie, 1000-(500-getElementHealth(zombie))) elseif table.have( firezombies, skinID ) then setPedOnFire ( zombie, true ) end end
  17. so I did as told SDK but it still does not work. server side bronezombies = { 167, 277, 264 } -- бронерованные зомби noheadzombies = { 70, 108, 128, 188, 259 } -- без головные зомби speedzombies = { 92, 162, 206, 209, 212, 229, 230 } -- скоростные зомби firezombies = { 105, 107, 127, 280, 287 } -- огненные зомби function table.have ( t, value ) if type(t) ~= "table" then return false end for k, v in pairs ( t ) do if ( v == value ) then return true end end return false end function zombieclasses ( zombie ) if not zombie then return end -- если не указано значение - выход local skinID = getElementModel(zombie) if not skinID then return end -- если не удалось узнать скин - выход if table.have( bronezombies, skinID ) then triggerClientEvent (source,"onbronezombies", source) elseif table.have( noheadzombies, skinID ) then elseif not setPedHeadless( zombie, false ) then triggerClientEvent ("onnoheadzombies", getRootElement()) elseif table.have( speedzombies, skinID ) then triggerClientEvent (source,"onspeedzombies", source) setPedStat ( zombie, 24, 500 ) -- но меньше жизек setElementHealth (zombie, 1000-(500-getElementHealth(zombie))) elseif table.have( firezombies, skinID ) then elseif not setPedOnFire ( zombie, false ) then triggerClientEvent ("onfirezombies", getRootElement()) end end client side addEvent("onbronezombies",true) addEventHandler( "onbronezombies", getLocalPlayer(), function(zombie) setGameSpeed (1); setGravity (0.1); end ) addEvent("onspeedzombies",true) addEventHandler( "onspeedzombies", getLocalPlayer(), function(zombie) setGameSpeed (1.2) end ) addEvent("onnoheadzombies",true) addEventHandler( "onnoheadzombies", getRootElement(), function(zombie) setPedHeadless( getRootElement(), true ) end ) addEvent("onfirezombies",true) addEventHandler( "onfirezombies", getRootElement(), function(zombie) setPedOnFire( getRootElement(), true ) end )
  18. Released MTA 1.1 will be in February? approximately? I can not wait when it comes out
  19. jij - should not be repeated in all the spawn. i fix it function warptoRacoon() j1 = getLocalPlayer() setElementPosition(j1, -1964.1522216797, 137.70756530762, 9.5, 0 ) setElementRotation(j1, 0, 0, 92.309692382813) setElementInterior (j1, 0 ) setElementHealth(j1, 100) guiSetVisible(spawnWindow, false) showCursor(false) end function warptoMehico() j2 = getLocalPlayer() setElementPosition(j2, -169.74603271484, 1118.3814697266, 27.694049835205, 0 ) setElementRotation(j2, 0, 0, 358.806640625) setElementHealth(j2, 100) setElementInterior (j2, 0 ) guiSetVisible(spawnWindow, false) showCursor(false) end function warptoMercy() j3 = getLocalPlayer() setElementPosition(j3, 1184.7172851563, -1323.6173095703, 13.573800086975, 0 ) setElementRotation(j3, 0, 0, 270.24758911133) setElementHealth(j3, 100) setElementInterior (j3, 0 ) guiSetVisible(spawnWindow, false) showCursor(false) end edit and use degugscript command console: /debugscript 1-3
×
×
  • Create New...