2D Toolkit Forum

2D Toolkit => Support => Topic started by: Magris on March 19, 2015, 03:31:30 pm

Title: Can i get sprite box custom collider size&offset by script??
Post by: Magris on March 19, 2015, 03:31:30 pm
I used sprite box custom collider(Weapon)

so i changed sprite then collider change together(i set each weapon sprite different box custom collider)

but sometimes not changed collider

when this time occured, i re commit weapon sprite collection and it works again.

but i dont want to do this every time.

so how can i fix it? or need update??

or can i access box custom collider value???

i use unity5 and latest version tk2d
Title: Re: Can i get sprite box custom collider size&offset by script??
Post by: unikronsoftware on March 21, 2015, 11:30:28 pm
Hi there,
This should work fine. Please post a repro and I'll investigate it.
Title: Re: Can i get sprite box custom collider size&offset by script??
Post by: Magris on March 26, 2015, 11:55:40 am
Sometimes  in editor scene tk2dsprite invisible( Rebuild All Sprites click and visible again but)

when that time

i think tk2d index broken(something wrong in tk2d collection)

so not update box custom collider(as i said)

and i rebuild index then it works again


i dont want to do this every time

how can i fix it?
Title: Re: Can i get sprite box custom collider size&offset by script??
Post by: unikronsoftware on March 26, 2015, 06:10:17 pm
The index should not be broken. I think you'll need to work out why thats happening - eg. is stuff not getting checked into version control correctly, etc...
Title: Re: Can i get sprite box custom collider size&offset by script??
Post by: Magris on March 27, 2015, 06:50:04 am
this happen when edit animator or animation

when edit animation(not tk2d animation) sometimes tk2dsprite invisible(i said)

and occured what i said


this problem solved when i click tk2d 'Rebuild Index' menu

but this problem occured again & again
Title: Re: Can i get sprite box custom collider size&offset by script??
Post by: unikronsoftware on March 28, 2015, 03:11:32 pm
Can you try to create a minimal repro case for this? I have not seen this happen at all.