❓ Parameters for Enemy Behaviors

Posts 1–13 of 13 · Page 1 of 1
❓ Parameters for Enemy Behaviors
Hello! I am currently working on behaviors for Lord of the Lost Lands Event and this one part is literally killing me.

Code:
Cooldown.Instance(400, MultiAttack.Instance(10, 210 * (float)Math.PI / 330, 20, projectileIndex: 0)),
                        Cooldown.Instance(370, MultiAttack.Instance(10, 30 * (float)Math.PI / 150, 20, projectileIndex: 0))
I am trying to achieve the LotLL's main shot but all I get is this:



I would love it if someone could explain the parameters of the MultiAttack logic (and other attack logics if you know them). Thanks!
I can't help u with this but I have a LotLL code. This is the normal attack from him...

namespace wServer.logic
{
partial class BehaviorDb
{
static _ LotLL = Behav()

.Init(0x0d50, Behaves("Lord of the Lost Lands",
new RunBehaviors(
SimpleWandering.Instance(2f, 2f),
Cooldown.Instance(800, MultiAttack.Instance(200, 20 * (float)Math.PI / 360, 10, 0, projectileIndex: 0)),
Cooldown.Instance(800, MultiAttack.Instance(200, 20 * (float)Math.PI / 360, 10, 3, projectileIndex: 0))
),
loot: new LootBehavior(LootDef.Empty,
Tuple.Create(100, new LootDef(0, 3, 0, 8,
Tuple.Create(0.03, (ILoot)new ItemLoot("Shield of Ogmur"))
)))));
}
}
When you want a attack (MultiAttack) then look in the wServer/logic/attack/MultiAttack.cs and there you can find all what you need
Code:
public static MultiAttack Instance(float radius, float angle, int numShot, float offset = 0, int projectileIndex = 0)
@ossimc82 I tried checking out MultiAttack.cs but I have no idea what angle references to. (starting angle? entire shot angle? angle to player?)
angel is the free space between the shoots
So Offset would be the angle correction?
Quote Originally Posted by Stellar Spark View Post
So Offset would be the angle correction?
yes, when you have a 180 offset the enemy shoots away from you
(facepalm) why did I not think of it...

Thanks for the help!
One more problem...
The LotLL has been going great! I just got minions done (after an accidental file deletion)! My last question is how to make the QueuedBehavior.Instance run properly. I try to insert "CooldownExact.Instance"s into the QueuedBehavior to represent delays, but when I test it, only the first action is executed.

Code:
new QueuedBehavior(
                                CooldownExact.Instance(200),
                                TossEnemy.Instance(40 * (float)Math.PI / 180, 5, 0x0d53),
                                CooldownExact.Instance(200),
                                TossEnemy.Instance(80 * (float)Math.PI / 180, 5, 0x0d53),
                                CooldownExact.Instance(200),
                                TossEnemy.Instance(120 * (float)Math.PI / 180, 5, 0x0d53),
                                CooldownExact.Instance(200),
                                TossEnemy.Instance(160 * (float)Math.PI / 180, 5, 0x0d53),
                                CooldownExact.Instance(200),
                                TossEnemy.Instance(200 * (float)Math.PI / 180, 5, 0x0d53),
                                CooldownExact.Instance(200),
                                TossEnemy.Instance(240 * (float)Math.PI / 180, 5, 0x0d53),
                                CooldownExact.Instance(200),
                                TossEnemy.Instance(280 * (float)Math.PI / 180, 5, 0x0d53),
                                CooldownExact.Instance(200),
                                TossEnemy.Instance(320 * (float)Math.PI / 180, 5, 0x0d53),
                                CooldownExact.Instance(200),
                                TossEnemy.Instance(360 * (float)Math.PI / 180, 5, 0xd53)
                                            )
This is one of the codes I need to execute with QueuedBehavior. I have looked at Lich, Sphinx, and Ghost King behaviors for reference on the behavior, but to no avail.
Quote Originally Posted by Stellar Spark View Post
The LotLL has been going great! I just got minions done (after an accidental file deletion)! My last question is how to make the QueuedBehavior.Instance run properly. I try to insert "CooldownExact.Instance"s into the QueuedBehavior to represent delays, but when I test it, only the first action is executed.

Code:
new QueuedBehavior(
                                CooldownExact.Instance(200),
                                TossEnemy.Instance(40 * (float)Math.PI / 180, 5, 0x0d53),
                                CooldownExact.Instance(200),
                                TossEnemy.Instance(80 * (float)Math.PI / 180, 5, 0x0d53),
                                CooldownExact.Instance(200),
                                TossEnemy.Instance(120 * (float)Math.PI / 180, 5, 0x0d53),
                                CooldownExact.Instance(200),
                                TossEnemy.Instance(160 * (float)Math.PI / 180, 5, 0x0d53),
                                CooldownExact.Instance(200),
                                TossEnemy.Instance(200 * (float)Math.PI / 180, 5, 0x0d53),
                                CooldownExact.Instance(200),
                                TossEnemy.Instance(240 * (float)Math.PI / 180, 5, 0x0d53),
                                CooldownExact.Instance(200),
                                TossEnemy.Instance(280 * (float)Math.PI / 180, 5, 0x0d53),
                                CooldownExact.Instance(200),
                                TossEnemy.Instance(320 * (float)Math.PI / 180, 5, 0x0d53),
                                CooldownExact.Instance(200),
                                TossEnemy.Instance(360 * (float)Math.PI / 180, 5, 0xd53)
                                            )
This is one of the codes I need to execute with QueuedBehavior. I have looked at Lich, Sphinx, and Ghost King behaviors for reference on the behavior, but to no avail.
I also tried using Cooldown.Instance(x), but it didn't work.
yo pro i will do sprites for ur pserver,
Quote Originally Posted by powerfruitcake View Post
yo pro i will do sprites for ur pserver,
I will tell you on your page what sprites I need created.
Quote Originally Posted by Stellar Spark View Post
I also tried using Cooldown.Instance(x), but it didn't work.
try
Code:
                    Cooldown.Instance(200),
                      new RunBehaviors(
                          TossEnemy.Instance(40 * (float)Math.PI / 180, 5, 0x0d53)
                    ),
                    Cooldown.Instance(200),
                      new RunBehaviors(
                          TossEnemy.Instance(80 * (float)Math.PI / 180, 5, 0x0d53)
                    ),
                    Cooldown.Instance(200),
                      new RunBehaviors(
                          TossEnemy.Instance(120 * (float)Math.PI / 180, 5, 0x0d53)
                    ),
...
Posts 1–13 of 13 · Page 1 of 1

Post a Reply

Similar Threads

Tags for this Thread

None

Talk with us