How do I make my boss appear and attack?

Get help using Construct 2

Post » Thu Mar 26, 2015 7:12 pm

Hey guys! Does anyone know how to make a boss appear at a certain point/section? I'm using like 13 sections total for my background but in the demo it's like only gonna be 5 sections so I want the boss to show up at the 5th section of the background and after a few seconds start it's attack pattern against the player. Not sure yet how attack patterns work yet. I see how the normal attacks work but multiple is kinda tricky so if anyone can help that would be great, thanks :)
B
10
S
1
Posts: 68
Reputation: 600

Post » Thu Mar 26, 2015 7:40 pm

not sure what you mean by "section". what has to happen in the game for the player to trigger a boss?

The simplest way to make code happen only when you want it to is with a "flag". So make a global variable called "BossFlag=0"

whenever you want the boss to come out Set BossFlag to 1.

then in an event make IF BossFlag=1 and add actions, add Trigger Once to the condition if it's the kind of code you only want triggered once.. like Create BossSprite. Otherwise if it's attack patterns you want to have then you need another event that will trigger every tick. So in that event It would say: IF BossFlag (without the Trigger Once) then add your code that will make the boss do what you want it to do (every tick). You could also make a group that you active or deactivate. I like those for top-level events like: Boss.Turret.OnShoot -> Action..etc
B
59
S
15
G
7
Posts: 939
Reputation: 8,825

Post » Thu Mar 26, 2015 8:26 pm

Thanks for the info and for a good example of what I mean is like the topdown space shooter demo they have that lets you learn how to do a space shooter... You know how they have 4 background sections? Say I want the boss to appear at that last background which I believe in that demo is background 4. That's what I'm trying to work on and your info for sure help once I figure out that part to make him appear in the correct background section
B
10
S
1
Posts: 68
Reputation: 600

Post » Thu Mar 26, 2015 10:02 pm

create object boss at layer (your main layer number , where you player currently is)you must have the boss somewhere outside of visible layer(margins) on start of layout so it can be triggered )
B
5
S
1
Posts: 4
Reputation: 287

Post » Fri Mar 27, 2015 9:56 pm

oh, how do you spawn your stuff on your top down shooter?

even so.. once you hit background 5 (5th section) - you are probably changing somewhere those sections - spawn boss.
also there's an option to make a variable global with number starting from 1, and increasing on each change of section. once that variable hits 5, spawn boss.
Sea Monsters template - Isometric
Also includes 40 pages PDF of optimizations and "how-to" for your games, and how the "sea monsters" template was built. Follow link for details :)

sea-monsters-templates-and-assets_t162705
B
30
S
10
G
11
Posts: 603
Reputation: 8,290

Post » Sat Mar 28, 2015 9:36 pm

Yeah for some reason when my player gets to the 5th section it starts to get all blurry. I think that's because I haven't figured out how to make the background to stop scrolling. I'm using the Space Blaster game to build off of and use all my own graphics and stuff so in that demo the background is already scrolling but I want it to stop at the 5th section of my background and spawn a boss. I already learned how to make a new missile attack but stopping the scrolling background where I want and making a boss appear using this demo is kinda hard. I'm really trying not start from scratch and just adjust stuff in the Space Blaster game and make it my own with all new stuff
B
10
S
1
Posts: 68
Reputation: 600

Post » Sun Mar 29, 2015 11:48 pm

Thanks guys for all the help. I pretty much got the boss appearing stuff to work. Just gotta tweek some things. Other then that I just now gotta make the background stop scrolling, switch the music to some cool boss music and have boss attack player
B
10
S
1
Posts: 68
Reputation: 600

Post » Mon Mar 30, 2015 4:58 am

In Capt. J. Doe saves the Universe I have a mini boss at wave 25, 50, and 75 plus a final boss at wave 100.
Since CJDstU is only one continual level I had to spawn them based on units of time, thus my wave system. Each "wave" is really nothing more than a timer that I can set that changes the wave (level) variable each pass.
My enemy spawners, and the wave clock are all set to shut off at those specific levels and restart when the boss is destroyed.
The key is finding what works best for your game and duct taping the heck out of it. :)
B
39
S
8
G
3
Posts: 541
Reputation: 5,050


Return to How do I....?

Who is online

Users browsing this forum: dcadjust, Husui, mantap100, Yahoo [Bot] and 24 guests