Jump to content

[BUG] Help, how to fix this bug?


Tokio

Recommended Posts

i have this code:

addEvent( "eszakirablas", true ) 
addEventHandler( "eszakirablas", root,
function (thePlayer)
		if ( idozito [ thePlayer ] ~= nil ) then
			outputChatBox ( "#01AC41[SuperFun] #FFffFFA következő széfrablásig várnod kell #01AC41".. math.floor ( getTimerDetails ( idozito [ thePlayer ] ) / 60000+1 ) .." percet.", thePlayer, 255, 0, 0, true );
		else
		setElementFrozen(thePlayer, true)
		setPedAnimation(thePlayer , "rob_bank", "cat_safe_rob", 10000, true, true, true, false)
		setTimer(setElementFrozen,10000,1,thePlayer,false)
		randomM = math.random(500000,1500000)
		setTimer(function()
		givePlayerMoney(thePlayer,randomM)
		end,10000,1)
		setTimer(outputChatBox, 10000,1,"#01AC41[SuperFun] #FFffFFÖsszesen raboltál #01AC41"..randomM.." #ffffffforintot.",thePlayer,255,255,255,true)
		setTimer(outputChatBox, 900000, 1,"#01AC41[SuperFun - #8C8C8CÉszaki] #FFffFFAz #01AC41északin #FFffFFújra kirabolhatod a széfet! #01AC41(/eszaki)",thePlayer,255,255,255,true)
		setTimer(Boltrablas,900000,1)
		idozito [ thePlayer ] = setTimer ( function ( thePlayer )
				idozito [ thePlayer ] = nil;
		end, 900000, 1, thePlayer);
	end
end
) 

and when the animation stop, and i change my skin, start off the animation.. :S how to fix this bug??

Link to comment
addEvent( "eszakirablas", true ) 
addEventHandler( "eszakirablas", root,
  function (thePlayer)
    if ( idozito [ thePlayer ] ~= nil ) then
      outputChatBox ( "#01AC41[SuperFun] #FFffFFA következő széfrablásig várnod kell #01AC41".. math.floor ( getTimerDetails ( idozito [ thePlayer ] ) / 60000+1 ) .." percet.", thePlayer, 255, 0, 0, true );
    else
      setElementFrozen(thePlayer, true)
      setPedAnimation(thePlayer , "rob_bank", "cat_safe_rob", 10000, true, true, true, false)
      setTimer(setElementFrozen,10000,1,thePlayer,false)
      setTimer(setPedAnimation,10000,1,thePlayer)
      randomM = math.random(500000,1500000)
      setTimer(function()
          givePlayerMoney(thePlayer,randomM)
        end,10000,1)
      setTimer(outputChatBox, 10000,1,"#01AC41[SuperFun] #FFffFFÖsszesen raboltál #01AC41"..randomM.." #ffffffforintot.",thePlayer,255,255,255,true)
      setTimer(outputChatBox, 900000, 1,"#01AC41[SuperFun - #8C8C8CÉszaki] #FFffFFAz #01AC41északin #FFffFFújra kirabolhatod a széfet! #01AC41(/eszaki)",thePlayer,255,255,255,true)
      setTimer(Boltrablas,900000,1)
      idozito [ thePlayer ] = setTimer ( function ( thePlayer )
          idozito [ thePlayer ] = nil;
        end, 900000, 1, thePlayer);
    end
  end
) 

 

  • Thanks 1
Link to comment
7 minutes ago, Mr.Loki said:

addEvent( "eszakirablas", true ) 
addEventHandler( "eszakirablas", root,
  function (thePlayer)
    if ( idozito [ thePlayer ] ~= nil ) then
      outputChatBox ( "#01AC41[SuperFun] #FFffFFA következő széfrablásig várnod kell #01AC41".. math.floor ( getTimerDetails ( idozito [ thePlayer ] ) / 60000+1 ) .." percet.", thePlayer, 255, 0, 0, true );
    else
      setElementFrozen(thePlayer, true)
      setPedAnimation(thePlayer , "rob_bank", "cat_safe_rob", 10000, true, true, true, false)
      setTimer(setElementFrozen,10000,1,thePlayer,false)
      setTimer(setPedAnimation,10000,1,thePlayer)
      randomM = math.random(500000,1500000)
      setTimer(function()
          givePlayerMoney(thePlayer,randomM)
        end,10000,1)
      setTimer(outputChatBox, 10000,1,"#01AC41[SuperFun] #FFffFFÖsszesen raboltál #01AC41"..randomM.." #ffffffforintot.",thePlayer,255,255,255,true)
      setTimer(outputChatBox, 900000, 1,"#01AC41[SuperFun - #8C8C8CÉszaki] #FFffFFAz #01AC41északin #FFffFFújra kirabolhatod a széfet! #01AC41(/eszaki)",thePlayer,255,255,255,true)
      setTimer(Boltrablas,900000,1)
      idozito [ thePlayer ] = setTimer ( function ( thePlayer )
          idozito [ thePlayer ] = nil;
        end, 900000, 1, thePlayer);
    end
  end
) 

 

Thank you!:D

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

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