How can I use tag from Collider Component?

Hi @pandamicro

Nope…I tried changing some programming issue, but it’s not solved yet, please look below:

zombiecolliderobjects:{
default:,
type: [cc.Prefab]
},

I have an array of 4 prefabs [0], [1], [2], [3]

onCollisionEnter:function(other,self){
this.node.color = cc.Color.RED;
this.touchingNumber ++;
//Left Zombie Collides with Left Bullet–Function//
if(cc.rectIntersectsRect(this.node.getBoundingBox(),this.zombiecolliderobjects[0]))
{this.ZombieBulletLeftHit()}
//Left Zombie Collides with Right Bullet–Function//
if(cc.rectIntersectsRect(this.node.getBoundingBox(),this.zombiecolliderobjects[1]))
{this.ZombieBulletLeftHit()}
//Left Zombie Collides with U Lightning–Function//
if(cc.rectIntersectsRect(this.node.getBoundingBox(),this.zombiecolliderobjects[2]))
{this.ZombieLightningHitBurn()}
//Left Zombie Collides with The U Tornado --Function
if(cc.rectIntersectsRect(this.node.getBoundingBox(),this.zombiecolliderobjects[3]))
{this.ZombieLightningHitBurn()}

I’ve set up the Group Colliders via the panel and within each node ( group ), placed checked marks for collision within the panel, and added the above code… So, the issue that I’m having is that example, if this.node (zombie ) collides with this.zombiecolliderobjects[0] ( bullet ) it’s supposed to call method {this.ZombieBulletLeftHit()} , but it doesn’t, it calls method {this.ZombieLightningHitBurn()}. I added else at the end of each if to see if it would solve the issue, but it didn’t work…Would appreciate any feedback…Thanks and God Bless…

Sincerely,

Sunday