to next layout when ALL monsters are destroyed

For questions about using Classic.

Post » Wed May 05, 2010 12:25 am

I am brand new to Construct and i must say it is fun.
i have been using the ghost shooter tutorial and succesfully made the game. to get used to the program more, i tried doing some modding.
so what i did was i said if monster private variable "hit count" is greater or equal to 5, than destroy monster and go to next layout. However, it goes to the next layout after destroying one monster. how do i make it go to the next layout after destroying ALL monsters?

also is 3D possible with construct?
B
1
G
2
Posts: 5
Reputation: 635

Post » Wed May 05, 2010 12:56 am

Welcome to the forum!!

[quote="abkarch":3w2lnrji]if monster private variable "hit count" is greater or equal to 5, than destroy monster and go to next layout. However, it goes to the next layout after destroying one monster.[/quote:3w2lnrji]
It sounds like your events are working exactly how you programmed them based on your first sentence! If you want to make it go to the next layout after killing all monsters then use a global variable or a player private variable to keep track of how many monsters killed (killCount). If you have 5 total monsters then have an event:

Event: global('killCount') >= 5:
Action: goto next layout

[quote="abkarch":3w2lnrji]also is 3D possible with construct?[/quote:3w2lnrji]
If you want a full blown 3D game you should try something other than Construct. However, you can have 3D elements in your game such as 3D box and look at some of the Mode7 examples on the forum.
B
8
S
3
G
7
Posts: 835
Reputation: 5,313

Post » Wed May 05, 2010 1:11 am

ok. so i created a global variable called killcount with an initial value of 0. i WANT to create an action that says on collision between BULLET and MONSTER add 1 to kill count. How do i do this, the only action i see can be used with private variables only? and i added an event that said global('killcount') >= 25: and added an action that said go to layout 2.

also, do you know anything like construct that can import 3d models?
B
1
G
2
Posts: 5
Reputation: 635

Post » Wed May 05, 2010 1:21 am

[quote="abkarch":2ccd2x7p]i WANT to create an action that says on collision between BULLET and MONSTER add 1 to kill count.[/quote:2ccd2x7p]

There is a system action that allows you to modify global variables.
B
8
S
3
G
7
Posts: 835
Reputation: 5,313

Post » Wed May 05, 2010 2:52 am

Another easy way to do it is to just go:

System Compare: monster.count is less or equal to 0
-> Go to next layout

Obviously make monster the name of your monster.

OR if you have two types of monsters for example a ghost and a chicken... you could put them into a family called "enemies" and then make it enemies.count.

Hope this helps.
B
7
S
2
G
4
Posts: 164
Reputation: 2,418

Post » Wed May 05, 2010 3:24 am

[quote="Citnarf":1t1nmwwv]
OR if you have two types of monsters for example a ghost and a chicken... you could put them into a family called "enemies" and then make it enemies.count.[/quote:1t1nmwwv]

OR...
System Compare: ghost.count+chicken.count is less or equal to 0
-> Go to next layout

theres no "right" way just do what ever you feel works best for you :P

[quote:1t1nmwwv]3d etc. etc.[/quote:1t1nmwwv]

Yes, but seeing as you've just started construct i say practice a lot of other stuff before you go anywhere near 3d, Besides basic 3d box stuff and Z elevation. its not a straightforward process and is would pretty much be considered an ADVANCED "technique", there are .cap files on the forums available demonstrating a multitude of ways to do 3D stuff as scidave said feel free to check them out yourself :P.

viewtopic.php?f=16&t=6224
viewtopic.php?f=4&t=4763
viewtopic.php?f=16&t=1832&hilit=wolfenstein
B
52
S
7
G
6
Posts: 1,945
Reputation: 7,610

Post » Wed May 05, 2010 9:09 pm

EDIT: nvm, i got it working!
B
1
G
2
Posts: 5
Reputation: 635


Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: No registered users and 4 guests