R139 Family with Turret Behavior

Report Construct 2 bugs here.

Post » Fri Jul 19, 2013 5:23 am

Link to .capx file (required!):
https://dl.dropboxusercontent.com/u/65841566/TurretFamilyTargetBug.capx

Steps to reproduce:
1. Add two object sprites (Turret1 and Turret2)
2. Add those two into a Family (Turrets)
3. Add turret behavior to the family
4. Add instance variable to the family(TargetType-number)
5. Change the family instance variable of Turret1 to 0 and Turret2 to 1)
6. Add two object sprites (Target1 and Target2).
7. On start of layout, Turrets with targetType=0 assign target to Target1 while Turrets with TargetType=1 assign target to Target2.
or
8. On start of layout just assign Turret1 to target target1,Turret2 to target turret2.

Observed result:
When you add an object to target to a "Turrets" family, all of the Turret will target all objects, it will ignore the targetType condition.
(I dont know if this is intended or not)

Expected result:
Turret1 in family (Turrets) with TargetType=0 will target Target1
Turret2 in family (Turrets) with TargetType=1 will target Target2

Browsers affected:
Chrome: no
Firefox: no
Internet Explorer: no

Operating system & service pack:
Windows 7 SP1

Construct 2 version:
1.39
    
B
66
S
21
G
14
Posts: 387
Reputation: 11,895

Post » Fri Jul 26, 2013 4:01 pm

UP
I've got kind of the same problem.


I have a project, where all the units are in the family(UNITS) but got a variable "Side"(1 or 2) to different Allies from Foes. Family(UNITS) got a family turret behavior.

What am i trying to do is on creation of any instance from UNITS family it is given the different target to the turret behavior based on the Side variable.
So when UNITS was created and Side = 1, add one type of targets to it
When unit with side = 2 was created, add another object to the targets.

In result it adds the target of the last created unit to ALL of the UNITS instances in game. So on creation of the Side = 1 unit, all of the UNITS, both sides are given the target meant for only the side = 1 units.


I even try to use "Pick by comparison" condition to pick only units with set side, but the result was the same.raptor07232013-07-26 16:16:30
B
14
S
6
G
4
Posts: 14
Reputation: 3,655

Post » Fri Jul 26, 2013 10:17 pm

Yup. I think its a bug in turret behavior when use with family. No response from scirra yet though.
B
66
S
21
G
14
Posts: 387
Reputation: 11,895

Post » Mon Aug 05, 2013 4:22 pm

This is currently by design; the target types apply to the behavior type. Since you have a family behavior it means all the objects in the family share the same target list. I can see how this isn't ideal, though - maybe we can change it for a future release.
Scirra Founder
B
383
S
224
G
86
Posts: 24,106
Reputation: 190,410

Post » Tue Aug 06, 2013 3:27 am

Thanks @Ashley.
B
66
S
21
G
14
Posts: 387
Reputation: 11,895

Post » Mon Nov 25, 2013 9:34 am

Just a little ping for this thread. It is still an issue.
A simple .capx of it:
https://dl.dropboxusercontent.com/u/68649813/turret_bug.capxraptor07232013-11-25 09:35:48
B
14
S
6
G
4
Posts: 14
Reputation: 3,655

Post » Tue Sep 08, 2015 8:38 pm

I realize these bug reports aren't actively monitored once closed, but I'd also +1 for changing this for a future release.
B
38
S
11
G
2
Posts: 45
Reputation: 3,908

Post » Mon Dec 28, 2015 9:32 pm

This is an old post, but I believe I'm experiencing this issue right now. If it's by design, it's flawed design, what is the workaround? I'm trying to have turrets only target objects on teams other than it's own team.
B
6
S
1
Posts: 39
Reputation: 486


Return to Bugs

Who is online

Users browsing this forum: No registered users and 0 guests