Your browser does not seem to support JavaScript. As a result, your viewing experience will be diminished, and you may not be able to execute some actions.
Please download a browser that supports JavaScript, or enable it if it's disabled (i.e. NoScript).
就像是把一个个方块,每个都是精灵,然后和网格对齐
比较偷懒的做法的话,是给这些精灵加上网格移动能力,然后把默认控制关掉,并把属性参数调到跟网格参数相近,好处是会自动对齐网格,坏处是不好调整位置,且因为该能力会跟刚体对象互相挤开,所以如果还涉及到刚体对象的话,需要把碰撞关掉才不会被挤开。比较好的做法自然就是自己写事件去对齐了,为了方便控制还可以写成动作组,调用动作组一次就对齐一次。
谢谢大佬的帮助^_^