Jump to content

nemesis


Jacobob14

Recommended Posts

Alguien me ayuda a que nemesis spawne automaticamente y no tenga necesidad de ejecutar un comando :cry:

function Nemesisbymanawydan ( thePlayer)   
local AclNome = getAccountName ( getPlayerAccount ( thePlayer ) )  
     if isObjectInACLGroup ("user."..AclNome, aclGetGroup ( "Admin" ) ) then  
       baz = createObject ( 360, -1935.5480957031, 665.44055175781, 48, 0, 0, 0 ) 
       nemesi = exports [ "slothBot" ]:spawnBot ( 1079.5283203125, 1064.6181640625, 10.8359375, 90,  math.random ( 300, 303 ), 0, 0, Nemesis, 38,         "hunting", true ) 
      setElementModel ( nemesi, 107 ) 
      outputChatBox ("#0000Ff|ALERT|#c0c0c0 Se Detecto Un Nemesis en las Vegas !!",getRootElement(), 255, 255, 255, true ) 
BlipNemesis = createBlipAttachedTo ( nemesi, 0 ) 
      attachElements ( baz, nemesi, 0.2, 0.1, 0.5, 0, 90, 0 ) 
      triggerClientEvent ( "nsound", root )     
      setElementData(nemesi, "nemesis",true) 
if nemesi then 
 exports.extra_health:setElementExtraHealth ( nemesi, 500 ) 
         end 
      end 
end 
addCommandHandler("nemesis",  Nemesisbymanawydan)   
  
addEvent("onBotWasted",true) 
addEventHandler("onBotWasted",getRootElement(), 
function (killer) 
if (source == nemesi) then 
givePlayerMoney(killer,math.random(4000,5000))  
outputChatBox ( getPlayerName ( killer ) .. " #888888Acabo con un Nemesis gana #ACFA58 $ 5.000 and exp : 600 !!",getRootElement(), 255, 255, 255, true ) 
 exports.exp_system:addPlayerEXP ( killer, 600 )  
destroyElement(BlipNemesis) 
end 
end) 
  

Link to comment

tienta

function Nemesisbymanawydan ()   
       baz = createObject ( 360, -1935.5480957031, 665.44055175781, 48, 0, 0, 0 ) 
       nemesi = exports [ "slothBot" ]:spawnBot ( 1079.5283203125, 1064.6181640625, 10.8359375, 90,  math.random ( 300, 303 ), 0, 0, Nemesis, 38,         "hunting", true ) 
      setElementModel ( nemesi, 107 ) 
      outputChatBox ("#0000Ff|ALERT|#c0c0c0 Se Detecto Un Nemesis en las Vegas !!",getRootElement(), 255, 255, 255, true ) 
BlipNemesis = createBlipAttachedTo ( nemesi, 0 ) 
      attachElements ( baz, nemesi, 0.2, 0.1, 0.5, 0, 90, 0 ) 
      triggerClientEvent ( "nsound", root )     
      setElementData(nemesi, "nemesis",true) 
if nemesi then 
 exports.extra_health:setElementExtraHealth ( nemesi, 500 ) 
         end 
end 
setTimer(Nemesisbymanawydan,1000,1) 
  
addEvent("onBotWasted",true) 
addEventHandler("onBotWasted",getRootElement(), 
function (killer) 
if (source == nemesi) then 
givePlayerMoney(killer,math.random(4000,5000)) 
outputChatBox ( getPlayerName ( killer ) .. " #888888Acabo con un Nemesis gana #ACFA58 $ 5.000 and exp : 600 !!",getRootElement(), 255, 255, 255, true ) 
 exports.exp_system:addPlayerEXP ( killer, 600 ) 
destroyElement(BlipNemesis) 
-- respawn 
setTimer(Nemesisbymanawydan,60000,1) -- 60000 = 1 min 
end 
end) 

Link to comment
tienta
function Nemesisbymanawydan ()   
       baz = createObject ( 360, -1935.5480957031, 665.44055175781, 48, 0, 0, 0 ) 
       nemesi = exports [ "slothBot" ]:spawnBot ( 1079.5283203125, 1064.6181640625, 10.8359375, 90,  math.random ( 300, 303 ), 0, 0, Nemesis, 38,         "hunting", true ) 
      setElementModel ( nemesi, 107 ) 
      outputChatBox ("#0000Ff|ALERT|#c0c0c0 Se Detecto Un Nemesis en las Vegas !!",getRootElement(), 255, 255, 255, true ) 
BlipNemesis = createBlipAttachedTo ( nemesi, 0 ) 
      attachElements ( baz, nemesi, 0.2, 0.1, 0.5, 0, 90, 0 ) 
      triggerClientEvent ( "nsound", root )     
      setElementData(nemesi, "nemesis",true) 
if nemesi then 
 exports.extra_health:setElementExtraHealth ( nemesi, 500 ) 
         end 
end 
setTimer(Nemesisbymanawydan,1000,1) 
  
addEvent("onBotWasted",true) 
addEventHandler("onBotWasted",getRootElement(), 
function (killer) 
if (source == nemesi) then 
givePlayerMoney(killer,math.random(4000,5000)) 
outputChatBox ( getPlayerName ( killer ) .. " #888888Acabo con un Nemesis gana #ACFA58 $ 5.000 and exp : 600 !!",getRootElement(), 255, 255, 255, true ) 
 exports.exp_system:addPlayerEXP ( killer, 600 ) 
destroyElement(BlipNemesis) 
-- respawn 
setTimer(Nemesisbymanawydan,60000,1) -- 60000 = 1 min 
end 
end) 

Gracias me funciono muy bien :D

Link to comment
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...