All pastes #964418 Raw Edit

Someone

public text v1 · immutable
#964418 ·published 2008-03-31 06:12 UTC
rendered paste body
	method MoveToCurrentPOI()
	{
		This.POIStr:Set[${POI.Str}]

		if ${This.IsMovingToCurrentPOI}
		{
			;------------------------------------------
			;Generate a path to POI
			;------------------------------------------
			
			This:MoveToLoc[${POI.X},${POI.Y},${POI.Z}]
			
			;---------------------------------------------------------------------
			;If we already generated a path but are not moving generate a new one
			;---------------------------------------------------------------------		
			
			if ${State.CurrentSubState} != 408
			{
				if ${nmcount:Inc} == 20
				{
					;echo UNSTUCK ME
					nmcount:Set[0]
					move forward 2000
					This:MoveToLoc2[${POI.X},${POI.Y},${POI.Z}]
				}
			}
			else
			{
				;echo LOOTING
				if ${nmcount2:Inc} == 50
				{
					;echo UNSTUCK ME
					nmcount2:Set[0]
					move forward 2000
					This:MoveToLoc2[${POI.X},${POI.Y},${POI.Z}]
				}
			}	
		}
		else
		{

			;------------------------------------------
			;We are moving reset our counter for check
			;------------------------------------------

			nmcount:Set[0]
			nmcount2:Set[0]
		}

	}

	
	member IsMovingToCurrentPOI()
	{
		This.POIStr:Set[${POI.Str}]

		if ${This.POIStr.Equal[${POI.Str}]}
		{
			if ${Me.StandingStill}
			{
				return TRUE
			}
		}
		return FALSE
	}