More cleanup
parent
b40adb1685
commit
54a1a26a2c
|
@ -2,12 +2,12 @@ use cgmath::Point2;
|
|||
use std::time::Instant;
|
||||
use winit::event::{ElementState, MouseButton, MouseScrollDelta, TouchPhase, VirtualKeyCode};
|
||||
|
||||
use super::{camera::Camera, outfits, system::System, util};
|
||||
use super::{camera::Camera, outfits, system::System};
|
||||
use crate::{
|
||||
consts,
|
||||
content::Content,
|
||||
inputstatus::InputStatus,
|
||||
physics::{Physics, ShipHandle},
|
||||
physics::{util, Physics, ShipHandle},
|
||||
render::Sprite,
|
||||
};
|
||||
|
||||
|
|
|
@ -1,10 +1,10 @@
|
|||
//! This module contains high-level game control routines.
|
||||
|
||||
mod camera;
|
||||
mod game;
|
||||
pub mod objects;
|
||||
pub mod outfits;
|
||||
mod system;
|
||||
mod systemobject;
|
||||
mod util;
|
||||
|
||||
pub use game::Game;
|
||||
pub use systemobject::SystemObject;
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
mod consts;
|
||||
mod game;
|
||||
mod inputstatus;
|
||||
mod objects;
|
||||
mod physics;
|
||||
mod render;
|
||||
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
//! This module contains game objects that may interact with the physics engine.
|
||||
|
||||
mod projectile;
|
||||
mod ship;
|
||||
|
|
@ -4,8 +4,10 @@ use rapier2d::{
|
|||
geometry::{ColliderBuilder, ColliderHandle},
|
||||
};
|
||||
|
||||
use super::super::util;
|
||||
use crate::render::{Sprite, SpriteTexture};
|
||||
use crate::{
|
||||
physics::util,
|
||||
render::{Sprite, SpriteTexture},
|
||||
};
|
||||
|
||||
pub struct ProjectileBuilder {
|
||||
pub rigid_body: RigidBodyBuilder,
|
|
@ -1,16 +1,18 @@
|
|||
use cgmath::{Deg, EuclideanSpace, Matrix2, Rad, Vector2};
|
||||
use nalgebra::vector;
|
||||
use rand::Rng;
|
||||
use rapier2d::dynamics::{RigidBody, RigidBodyBuilder};
|
||||
use rapier2d::geometry::ColliderBuilder;
|
||||
use rapier2d::pipeline::ActiveEvents;
|
||||
use rapier2d::{
|
||||
dynamics::{RigidBody, RigidBodyBuilder},
|
||||
geometry::ColliderBuilder,
|
||||
pipeline::ActiveEvents,
|
||||
};
|
||||
|
||||
use super::ProjectileBuilder;
|
||||
use crate::{
|
||||
content,
|
||||
game::{outfits, util},
|
||||
game::outfits,
|
||||
inputstatus::InputStatus,
|
||||
physics::ShipHandle,
|
||||
physics::{util, ShipHandle},
|
||||
render::{Sprite, SpriteTexture},
|
||||
};
|
||||
|
|
@ -1,4 +1,5 @@
|
|||
mod physics;
|
||||
pub mod util;
|
||||
mod wrapper;
|
||||
|
||||
pub use physics::Physics;
|
||||
|
|
|
@ -9,11 +9,7 @@ use rapier2d::{
|
|||
use std::collections::HashMap;
|
||||
|
||||
use super::{wrapper::Wrapper, ShipHandle};
|
||||
use crate::{
|
||||
content,
|
||||
game::{objects, outfits},
|
||||
render::Sprite,
|
||||
};
|
||||
use crate::{content, game::outfits, objects, render::Sprite};
|
||||
|
||||
/// Keeps track of all objects in the world that we can interact with.
|
||||
/// Also wraps our physics engine
|
||||
|
|
Loading…
Reference in New Issue