Shorten the name of various scalar types

This commit is contained in:
crumblingstatue 2023-04-08 22:12:05 +02:00
parent 390a4d45d2
commit e7c30d231b
4 changed files with 28 additions and 28 deletions

View file

@ -3,7 +3,7 @@ use s2dc::{vec2, MobileEntity};
use crate::{
math::{WorldPos, TILE_SIZE},
world::{TilePos, TilePosScalar},
world::{TPosSc, TilePos},
};
#[derive(Debug, Inspect)]
@ -40,8 +40,8 @@ impl Player {
#[allow(dead_code)]
pub fn center_tp(&self) -> TilePos {
TilePos {
x: (self.col_en.en.pos.x / TILE_SIZE as i32) as TilePosScalar,
y: (self.col_en.en.pos.y / TILE_SIZE as i32) as TilePosScalar,
x: (self.col_en.en.pos.x / TILE_SIZE as i32) as TPosSc,
y: (self.col_en.en.pos.y / TILE_SIZE as i32) as TPosSc,
}
}
pub fn can_jump(&self) -> bool {