Removed redundant code
This commit is contained in:
parent
f8d3cd1f48
commit
4711dd3258
@ -45,11 +45,11 @@ export const calculateIsometricDepth = (x: number, y: number, width: number = 0,
|
||||
const baseDepth = x + y
|
||||
if (isCharacter) {
|
||||
// Increase the offset for characters to ensure they're always on top
|
||||
return baseDepth + 0.9 // @TODO: Fix collision, this is a hack
|
||||
} else {
|
||||
// For objects, use their back bottom corner
|
||||
return baseDepth + (width + height) / (2 * config.tile_size.x)
|
||||
return baseDepth // @TODO: Fix collision, this is a hack
|
||||
}
|
||||
|
||||
// For objects, use their back bottom corner
|
||||
return baseDepth + (width + height) / (2 * config.tile_size.x)
|
||||
}
|
||||
|
||||
export const sortByIsometricDepth = <T extends { positionX: number; positionY: number }>(items: T[]) => {
|
||||
|
Loading…
x
Reference in New Issue
Block a user