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

Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

RoutineManager.PreferedRoutine is ignored

Suspicioso

New Member
Joined
Aug 19, 2016
Messages
3
I'm trying to make a plugin that automatically sets the combat routine so the dialog box doesn't appear. It doesn't matter where I put RoutineManager.PreferedRoutine, it's never used. I've verified the name of the CR is correct, I've also debugged and verified the PreferedRoutine field is being updated correctly, but it's still being ignored.

Example.

Code:
public CombatRoutine()
        {
            RoutineManager.PickRoutineFired += RoutineManager_PickRoutineFired;
        }
private static void RoutineManager_PickRoutineFired(object sender, EventArgs e)
        {
            switch (Core.Player.CurrentJob)
            {
                case ClassJobType.DarkKnight:
                    RoutineManager.PreferedRoutine = DefaultRoutine = "Kefka";
                    break;
                case ClassJobType.Astrologian:
                    RoutineManager.PreferedRoutine = DefaultRoutine = "Orran";
                    break;
                default:
                    RoutineManager.PreferedRoutine = DefaultRoutine = "Ultima";
                    break;
            }
        }

I've even tried creating a task and setting the preferred routine every 100ms, the dialog box still appears.


Edit: Unrelated. Is there a way to prevent RB from compiling libraries each time it's launched? I feel like it needlessly extends start up and wastes away disk lifetimes for those of us using SSDs.
 
Last edited:
I'm trying to make a plugin that automatically sets the combat routine so the dialog box doesn't appear. It doesn't matter where I put RoutineManager.PreferedRoutine, it's never used. I've verified the name of the CR is correct, I've also debugged and verified the PreferedRoutine field is being updated correctly, but it's still being ignored.

Example.

Code:
public CombatRoutine()
        {
            RoutineManager.PickRoutineFired += RoutineManager_PickRoutineFired;
        }
private static void RoutineManager_PickRoutineFired(object sender, EventArgs e)
        {
            switch (Core.Player.CurrentJob)
            {
                case ClassJobType.DarkKnight:
                    RoutineManager.PreferedRoutine = DefaultRoutine = "Kefka";
                    break;
                case ClassJobType.Astrologian:
                    RoutineManager.PreferedRoutine = DefaultRoutine = "Orran";
                    break;
                default:
                    RoutineManager.PreferedRoutine = DefaultRoutine = "Ultima";
                    break;
            }
        }

I've even tried creating a task and setting the preferred routine every 100ms, the dialog box still appears.


Edit: Unrelated. Is there a way to prevent RB from compiling libraries each time it's launched? I feel like it needlessly extends start up and wastes away disk lifetimes for those of us using SSDs.

Really need more then what you've provided as I can set it and it works fine from a plugin.

As for ssd's, the fears of ssd wear were largely exaggerated and is not something that you need to worry about during normal use. Personally my machine is all SSD for many years now.
 
Suspicioso,

PreferredRoutine isn't being ignored, it's being overwritten. There's a setting in Ultima that is setting itself as the preferred routine for all classes. Try turning that setting off and see if it works for you. Or just try removing Ultima altogether. It boils down to scope creep from a CR that's trying to make sure it is the only routine used when it really shouldn't do that.
 
The Default CR option was put into Ultima on 6/2/15 and at the time it was basically the only CR available (YRB had only just appeared a couple weeks before that). It also being an AIO just meant you either checked "Default CR" in Ultima or in YRB. So the design worked perfectly fine at the time of development (especially since the feature was only recently available and usage was basically experimental at the time).

It only became an issue when **ORLY was created on 6/9/15 and individual CRs started being sold shortly after. I stopped releasing updates around that point and the "Default CR" design in Ultima has remained since. I would hesitate to call it "scope creep" when it was perfectly reasonable at the time of design.

At this point, would it be better to make a "Default CR" plugin or instead just bake it into the bot itself (although the latter is more work for mastahg)? All it comes down to is a form and a giant switch statement in the end.
 
Back
Top