Jump to content

Chaos

Members
  • Posts

    300
  • Joined

  • Last visited

Everything posted by Chaos

  1. all working fine but there is a problem some zombies kill you with just one hit it looks like knife
  2. function stopDamage ( ) addEventHandler ( "onClientPlayerDamage", getLocalPlayer(), stopMinigunDamage ) end function stopMinigunDamage() player = getLocalPlayer() setElementHealth (player,getElementHealth (player) +25) end I think you mean that is that correct and if correct is there a shortcut?
  3. So is it possible to get anti damage by zombies?
  4. yh it's working if i want to add button to disable that removeEventHandler ( "onClientPlayerDamage", getLocalPlayer(), cancelEvent ) ? and why when the zombies attacking me i will die?
  5. addEventHandler ( "onClientGUIClick", pilot, pilott,false) addEventHandler ( "onClientPlayerDamage", getLocalPlayer(), cancelEvent ) it's just 2 only
  6. well it's working but there is something wrong
  7. I know it's stupid question but I'm really confused when I set it to 100 the server lag as hell and when I set to 50 the Players complain of lack of zombies.
  8. it's working but the problem it's working only 1 time then if i change my skin and press the button again will not works
  9. client side: GUIEditor = { button = {}, window = {}, label = {} } addEventHandler("onClientResourceStart", resourceRoot, function() okno = guiCreateWindow(553, 303, 493, 466, "Skin System || Copyright by Ciastko", false) guiWindowSetSizable(okno, false) guiWindowSetMovable(okno, false) cj = guiCreateButton(36, 201, 126, 66, "CJ", false, okno) guiSetProperty(cj, "NormalTextColour", "FFAAAAAA") addEventHandler ( "onClientGUIClick", cj, cjj,false) end ) function gui() if (guiGetVisible (okno) == false) then guiSetVisible(okno, true) showCursor(true) else guiSetVisible(okno, false) showCursor(false) end end bindKey ("F2", "down", gui) function cjj() triggerServerEvent ("cj", getLocalPlayer()) end server side : addEvent ( "cj", true ) addEventHandler ( "cj", getRootElement(), function () local zombiekills = getElementData(source,"Zombie kills") if (zombiekills >= 20) then setElementModel ( source, 0) else outputChatBox ( "get level 2 first !", source, 255, 0, 0 ) end end ) well im trying to make when the player kills 20 zombies and more then he can select cj skin button but it's working only 1 time then if i change my skin and press the button again will not works
  10. it's not working WARNING: adminpanel\c.lua:125: Bad argument @ 'addEventHandler' [Expected function at argument 3,got nil]
  11. Where is the cancelevent ()?
  12. addEventHandler ( "onClientGUIClick", unlimited,stopMinigunDamage, false) already did that but when I press the button all wont die
  13. Thanks mate I want to add another button called unlimited health but the problem is when I press it all will have unlimited health function stopMinigunDamage ( ) cancelEvent() --cancel the event end addEventHandler ( "onClientPlayerDamage", getLocalPlayer(), stopMinigunDamage )
  14. GUIEditor = { button = {}, window = {}, label = {} } addEventHandler("onClientResourceStart", resourceRoot, function() okno = guiCreateWindow(553, 303, 494, 466, "Admin Panel by Chaos", false) guiWindowSetSizable(okno, false) guiWindowSetMovable(okno, false) guiSetVisible(okno, false) szeryf = guiCreateButton(181, 109, 126, 65, "Give Me Minigun", false, okno) guiSetProperty(szeryf, "NormalTextColour", "FFAAAAAA") lekarz = guiCreateButton(180, 199, 127, 68, "Full Health", false, okno) guiSetProperty(lekarz, "NormalTextColour", "FFAAAAAA") robotnik = guiCreateButton(182, 293, 125, 67, "Clear The Main Chat", false, okno) guiSetProperty(robotnik, "NormalTextColour", "FFAAAAAA") strazak = guiCreateButton(325, 109, 133, 65, "Give me infernus", false, okno) guiSetProperty(strazak, "NormalTextColour", "FFAAAAAA") mechanik = guiCreateButton(326, 201, 132, 66, "Nitro", false, okno) guiSetProperty(mechanik, "NormalTextColour", "FFAAAAAA") pilot = guiCreateButton(325, 293, 133, 67, "Fix My Vehicle", false, okno) guiSetProperty(pilot, "NormalTextColour", "FFAAAAAA") addEventHandler ( "onClientGUIClick", lekarz, lekarzz) addEventHandler ( "onClientGUIClick", strazak, strazakk) addEventHandler ( "onClientGUIClick", szeryf, szeryff) addEventHandler ( "onClientGUIClick", pilot, pilott) addEventHandler ( "onClientGUIClick", mechanik, mechanikk) addEventHandler ( "onClientGUIClick", robotnik, robotnikk) end ) function gui() triggerServerEvent ("checkforadmins", getLocalPlayer()) end bindKey ("F2", "down", gui) addEvent ( "ok", true ) addEventHandler ( "ok", getRootElement(), function () if (guiGetVisible (okno) == false) then guiSetVisible(okno, true) showCursor(true) else guiSetVisible(okno, false) showCursor(false) end end )
  15. it's ok now but i have more questions why when i click on window some buttons will pressed and another question is that correct ? triggerServerEvent ("minigun", getLocalPlayer())
  16. addEvent ( "checkforadmins", true ) addEventHandler ( "checkforadmins", getRootElement(), function () local accName = getAccountName ( getPlayerAccount ( source ) ) if isObjectInACLGroup ("user."..accName, aclGetGroup ( "Admin" ) ) then triggerClientEvent ("ok", source) end end )
  17. function gui() triggerServerEvent ("checkforadmins", getLocalPlayer()) end bindKey ("F2", "down", gui) addEvent ( "ok", true ) addEventHandler ( "ok", getRootElement(), function () if (guiGetVisible (okno) == false) then guiSetVisible(okno, true) showCursor(true) else guiSetVisible(okno, false) showCursor(false) end end ) why the window will show for all players when some one press f2 i need it appear for one player only
  18. thanks man nemesi bot is on the team Nemsis but they will not kill each others right?
  19. debug said unexpected symbol near ","
  20. nemesi bot is not in a team.
  21. Chaos

    about Compilers

    try this http://mta.dzek.eu/compiler/
×
×
  • Create New...