Angully
Member
- Joined
- Sep 19, 2010
- Messages
- 764
- Reaction score
- 1
I was wondering if it was possible for someone to clean an edit i made to the Exile Code
private void RegisterSummons()
{
RegisterSummon("Raise Zombie", () => NumZombies, () => MaxZombies, true);
RegisterSummon("Raise Spectre", () => NumSpectres, () => MaxSpectres, true); // TODO: add spectre selection logic
RegisterSummon("Summon Skeletons",
() => NumSkeletons,
() => MaxSkeletons,
false,
extraReqs: o => NumberOfMobsNear(BestTarget, 20, 1) || BestTarget.Rarity >= Rarity.Normal);
I changed the rarity to normal and the mobs near to 20, 1. It does exactly what i want it to however it causes a syntax error
Error during bot tick: Buddy.Coroutines.CoroutineException: Exception was thrown by coroutine ---> System.NullReferenceException: Object reference not set to an instance of an object.
at ExileRoutine.Exile.<>c__DisplayClass60.<RegisterSummon>b__5d(Object ctx) in d:\Desktop\EB\Routines\Exile\Exile.cs:line 492
at Loki.Bot.SpellManager..(Object )
at Loki.TreeSharp.Action.RunAction(Object context)
at Loki.TreeSharp.Action..()
at Loki.TreeSharp.Composite.Tick(Object context)
at Loki.TreeSharp.Decorator..()
at Loki.TreeSharp.Composite.Tick(Object context)
at Loki.TreeSharp.PrioritySelector..()
at Loki.TreeSharp.Composite.Tick(Object context)
at Loki.TreeSharp.PrioritySelector..()
at Loki.TreeSharp.Composite.Tick(Object context)
at Loki.Bot.v2.LokiCoroutine..()
at Buddy.Coroutines.Coroutine.Resume(Object& value)
--- End of inner exception stack trace ---
at Buddy.Coroutines.Coroutine.Resume(Object& value)
at Loki.Bot.v2.LokiCoroutine.Tick(Coroutine coroutine)
at Loki.Bot.v2.ActionRunCoroutine.Run(Object context)
at Loki.TreeSharp.Action.RunAction(Object context)
at Loki.TreeSharp.Action..()
at Loki.TreeSharp.Composite.Tick(Object context)
at Loki.Bot.BotMain.()
Its not a massive issue but it would be nice if someone could tell me how to fix this so i can learn to edit more things.
Thanks in advance.
-Angully A.k.a Dwink
private void RegisterSummons()
{
RegisterSummon("Raise Zombie", () => NumZombies, () => MaxZombies, true);
RegisterSummon("Raise Spectre", () => NumSpectres, () => MaxSpectres, true); // TODO: add spectre selection logic
RegisterSummon("Summon Skeletons",
() => NumSkeletons,
() => MaxSkeletons,
false,
extraReqs: o => NumberOfMobsNear(BestTarget, 20, 1) || BestTarget.Rarity >= Rarity.Normal);
I changed the rarity to normal and the mobs near to 20, 1. It does exactly what i want it to however it causes a syntax error
Error during bot tick: Buddy.Coroutines.CoroutineException: Exception was thrown by coroutine ---> System.NullReferenceException: Object reference not set to an instance of an object.
at ExileRoutine.Exile.<>c__DisplayClass60.<RegisterSummon>b__5d(Object ctx) in d:\Desktop\EB\Routines\Exile\Exile.cs:line 492
at Loki.Bot.SpellManager..(Object )
at Loki.TreeSharp.Action.RunAction(Object context)
at Loki.TreeSharp.Action..()
at Loki.TreeSharp.Composite.Tick(Object context)
at Loki.TreeSharp.Decorator..()
at Loki.TreeSharp.Composite.Tick(Object context)
at Loki.TreeSharp.PrioritySelector..()
at Loki.TreeSharp.Composite.Tick(Object context)
at Loki.TreeSharp.PrioritySelector..()
at Loki.TreeSharp.Composite.Tick(Object context)
at Loki.Bot.v2.LokiCoroutine..()
at Buddy.Coroutines.Coroutine.Resume(Object& value)
--- End of inner exception stack trace ---
at Buddy.Coroutines.Coroutine.Resume(Object& value)
at Loki.Bot.v2.LokiCoroutine.Tick(Coroutine coroutine)
at Loki.Bot.v2.ActionRunCoroutine.Run(Object context)
at Loki.TreeSharp.Action.RunAction(Object context)
at Loki.TreeSharp.Action..()
at Loki.TreeSharp.Composite.Tick(Object context)
at Loki.Bot.BotMain.()
Its not a massive issue but it would be nice if someone could tell me how to fix this so i can learn to edit more things.
Thanks in advance.
-Angully A.k.a Dwink