GamerzPlanet - For All Your Online Gaming Needs!!  

Go Back   GamerzPlanet - For All Your Online Gaming Needs!! > Online Gaming > FlyFF Discussion



Auto Loot Script

FlyFF Discussion


Reply
 
Thread Tools Display Modes
Old 06-27-2008, 05:51 AM   #1
Registered User
 
Last Online: 08-27-2008 11:42 AM
Join Date: May 2008
Posts: 28
Thanks: 20
Thanked 15 Times in 10 Posts
wkimisan is an unknown quantity at this point
iTrader: 0 / 0%
Points: 428.00
Bank: 9,366.50
Total Points: 9,794.50
Auto Loot Script

Problem solved. Please close this thread.
Thanks.

Ok I modified the auto grind to make it auto loot in example.atmt. I almost have it but a few problem:
When i @startlooting, it moves to the item but don't collect and i need to @stoplooting then @startlooting to where the item is to make it collect.
Could someone please help me?

In OnTick Event:
Code:
if ( LastTarget == nil ) then
        local Best = { Drop = nil, Distance = nil }
        local Drops = GetDrops ()
        for k, Drop in pairs (Drops) do
            local DPos = Drop:Get ( "Position" )
            if ( not IsPlayer ( Drop ) )then
            local Dist = Distance ( PPos, DPos ) 
            if ( Best.Distance == nil ) or ( Best.Distance > Dist ) then
            Best.Distance = Dist
            Best.Drop = Drop
        end
    end
end

        if ( Best.Drop ~= nil ) then
            LastTarget = Best.Drop
            LogF ( "Got %s!", LastTarget:Get ( "Type" ) )
            local Position = LastTarget:Get ( "Position" )
            Move ( Position.x, Position.y, Position. z )
 if(gdist == 0) or (Distance ( PPos, Position ) < gdistance) then
            Collect ( LastTarget )
end
    else
if ( LastTarget:Get ( "Destroyed" ) ) then
            LastTarget = nil
            LastCycle = LastCycle + DeltaTime
            if ( LastCycle > CycleInterval ) then
            local Position = LastTarget:Get ( "Position" )
            Move ( Position.x, Position.y, Position.z )
if(gdist == 0) or (Distance ( PPos, Position ) < gdistance) then
Collect ( LastTarget )
end
                LastCycle = 0
            end
        end
    end
end

end

Last edited by wkimisan; 06-27-2008 at 06:04 PM. Reason: Problem solved.
wkimisan is offline   Reply With Quote
The Following User Says Thank You to wkimisan For This Useful Post:
Mostiko (07-21-2008)
Sponsored Links
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off

All times are GMT -7. The time now is 01:38 PM.


Powered by: vBulletin
Copyright ©2008, GamerzPlanet.Net
SEO by vBSEO 3.2.0 RC5 ©2008, Crawlability, Inc.
Network: GamerzPlanet | ForumzPlanet | GzPUpload | GzPArcade | GzP Host | Poker Tips | Visits: