Bug with private varaibles

For questions about using Classic.

Post » Wed Sep 12, 2012 9:57 am

Hi everyone! In my game there's a family called "red". It's the family for different types of projectiles my hero shoots. There are varaibles called "explosive" and "ghost". If the first one is equal to 1 bullet has to spawn explosion object on collision with solid object or enemy. Varaible "ghost" has another function. If it is equal to 0 bullet has to be destroyed on any collision. If it is equal to 1 it has to go through enemies but not through solids. If it is equal to 2 it has to go through any object. And here's my problem: my event sheet has to look like this, but explosive bullets spawn explosions only on collision with solid objects.

But if it looks like this it works fine. Why?
Wolod2012-09-12 11:01:20
B
54
S
11
G
4
Posts: 250
Reputation: 5,074

Post » Tue Sep 18, 2012 11:49 pm

Any suggestions?
B
54
S
11
G
4
Posts: 250
Reputation: 5,074

Post » Wed Sep 19, 2012 7:40 am

I think you'll need to put the enemy family conditions inside a "For each Family object" loop, not sure though. I've come to realize family objects are very buggy
"Construct 4 lets YOU make advanced games! (maybe)" Construct Classic - Examples Kit
B
86
S
28
G
13
Posts: 2,092
Reputation: 15,009

Post » Thu Sep 20, 2012 10:36 am

Thanks Jayjay! "For each Family object" loop helped to solve this problem.
B
54
S
11
G
4
Posts: 250
Reputation: 5,074

Post » Thu Sep 20, 2012 2:06 pm

Awesome, glad to hear Wolod
"Construct 4 lets YOU make advanced games! (maybe)" Construct Classic - Examples Kit
B
86
S
28
G
13
Posts: 2,092
Reputation: 15,009


Return to Help & Support using Construct Classic

Who is online

Users browsing this forum: No registered users and 5 guests