What's new
  • Visit Rebornbuddy
  • Visit Panda Profiles
  • Visit LLamamMagic
  • Visit Resources
  • Visit Downloads
  • Visit Portal

Auto Assist

Status
Not open for further replies.

loukaseco

New Member
Joined
Oct 1, 2014
Messages
14
Reaction score
0
i want help with auto roll when i am in raid or a party
i have this code
Code:
while (bestMob != null && !isAlive(bestMob) && isExists(bestMob) && bestMob.type == BotTypes.Npc && ((Npc)bestMob).dropAvailable && GetGroupStatus("autoexp") && isAlive())
                            {
                                if (me.dist(bestMob) > 3)
                                   ComeTo(bestMob, 1);
                                PickupAllDrop(bestMob);   
                                BlockClientDice(true); 
                                            while (true) 
                                            { 
                                                foreach (var item in me.getDiceItems()) 
                                                { 
                                                    item.Dice(true);                          
                                                    Thread.Sleep(200);                                                 
                                                } 
                                            Thread.Sleep(100); 
                                            break; 
                                            } 
 
                            }
the problem is when the other players dont roll fast i stay still and i dont hit the next monster
 
Last edited:
i tried but i cant find the solution
i wrote the code above to help me
 
The problem is you run to the mob and loot, then wait around for the loot to be gone because its still there, till everyone hit roll.

i modified a script by iGM to enable widget checkboxes for both functions, either loot a corpse thats near you, and roll on items.

also it dont run to corspes to loot, but loots anythiung within a few meters of you, if there is stuff to loot, i only noticed it getting stuck on quest items that might drop that i allready have.

but then you just jump and move away
and you can continue with your buisness.

also for now the roll checkbox is untested but should work.

PHP:
using System;
using System.Drawing;
using System.Windows.Forms;
using System.Threading;
using System.Collections.Generic;
using System.Linq;
using ArcheBuddy.Bot.Classes;

namespace AutoLoot {
    public class AutoLoot : Core {
        public static string GetPluginAuthor() { return "iGM"; }
        public static string GetPluginVersion() { return "0.1.1"; }
        public static string GetPluginDescription() { return "Auto looting plugin"; }
        bool Roll, Corpses;
        // 0.1.1 Added widget options - RM Auto Loot Roll and Auto Loot Corpses -- Remark
        
        public void PluginRun() {
            ClearLogs();
            SetGroupStatus("Auto Loot - roll",true);
            SetGroupStatus("Auto Loot - Corpses",true);
            BlockClientDice(true);
            onLootDice += item => item.Dice(true);
            onWidgetGroupStatusChanged += StatusChanged;
            while(true) {
                Pulse();
                Thread.Sleep(100);
            }
        }

        
       public void PluginStop(){
           BlockClientDice(false);
           DelGroupStatus("Auto Loot - roll");
           DelGroupStatus("Auto Loot - Corpses");           
        
       }        

        void StatusChanged(string name, bool newState) {
            Corpses = GetGroupStatus("Auto Loot - Corpses");
            Roll    = GetGroupStatus("Auto Loot - Roll");
            
            if(!Roll){
                BlockClientDice(true);
                onLootDice += item => item.Dice(true);
            }
            else{
                BlockClientDice(false);
                onLootDice += item => item.Dice(false);
            }
           
        }
        
        public void Pulse() {
            if(Corpses){
            //Log("Pulse loot: "+Corpses.ToString());    
                try {
                    foreach (var obj in getCreatures()) {
                        if (obj.dropAvailable && me.dist(obj) < 4) PickupAllDrop(obj);
                        }
                    } catch {}
                }
        }
    }
}
 
Status
Not open for further replies.
Back
Top