5
基于Tile的2D平台平台中的45°坡度
我想在基于图块的平台游戏中使用简单的45°坡度,但是我似乎无法将算法推倒。请看一下代码和视频,也许我错过了明显的地方? //collisionRectangle is the collision rectangle of the player with //origin at the top left and width and height //wantedPosition is the new position the player will be set to. //this is determined elsewhere by checking the bottom center point of the players rect if(_leftSlope || _rightSlope) { //Test bottom …
12
xna
c#
xna-4.0
platformer