修复建筑碰撞问题
This commit is contained in:
parent
79a8956b9a
commit
4e3f00bc68
@ -73,12 +73,12 @@ ColliderComponent* Building::GetBoxBound()
|
||||
collider->active = true;
|
||||
collider->owner = this;
|
||||
collider->_min = Vector2D(
|
||||
pos.x - meta->i->tilewidth()/2.0,
|
||||
pos.y - meta->i->tileheight()/2.0
|
||||
-meta->i->tilewidth()/2.0,
|
||||
-meta->i->tileheight()/2.0
|
||||
);
|
||||
collider->_max = Vector2D(
|
||||
pos.x + meta->i->tilewidth()/2.0,
|
||||
pos.y + meta->i->tileheight()/2.0
|
||||
meta->i->tilewidth()/2.0,
|
||||
meta->i->tileheight()/2.0
|
||||
);
|
||||
return collider;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user