Compare commits
2 Commits
5fa5b56e5a
...
6545f54cfc
| Author | SHA1 | Date | |
|---|---|---|---|
| 6545f54cfc | |||
| 02c39f01dc |
@ -210,7 +210,6 @@ pub struct Game {
|
|||||||
|
|
||||||
pub current_map: Option<Gd<Map>>,
|
pub current_map: Option<Gd<Map>>,
|
||||||
pub world_ball: Option<Gd<Ball>>,
|
pub world_ball: Option<Gd<Ball>>,
|
||||||
since_last_sync: f64,
|
|
||||||
|
|
||||||
pub goals: HashMap<u8, u16>,
|
pub goals: HashMap<u8, u16>,
|
||||||
|
|
||||||
|
|||||||
@ -1,7 +1,6 @@
|
|||||||
use std::{
|
use std::{
|
||||||
collections::VecDeque,
|
|
||||||
net::SocketAddr,
|
net::SocketAddr,
|
||||||
time::{Duration, Instant, SystemTime, UNIX_EPOCH},
|
time::{Duration, SystemTime, UNIX_EPOCH},
|
||||||
};
|
};
|
||||||
|
|
||||||
use godot::{
|
use godot::{
|
||||||
|
|||||||
@ -411,7 +411,7 @@ impl ICharacterBody3D for LocalPlayer {
|
|||||||
scoreboard.set_visible(Input::singleton().is_action_pressed("scoreboard"));
|
scoreboard.set_visible(Input::singleton().is_action_pressed("scoreboard"));
|
||||||
}
|
}
|
||||||
|
|
||||||
if self.movement_dir.length_squared() > 0. && self.base().is_on_floor() {
|
if self.movement_dir.length_squared() > 0. && self.base().is_on_floor() && !self.is_dead {
|
||||||
if let Some(effects) = &mut self.effects {
|
if let Some(effects) = &mut self.effects {
|
||||||
effects.bind_mut().walk();
|
effects.bind_mut().walk();
|
||||||
}
|
}
|
||||||
|
|||||||
@ -269,6 +269,7 @@ impl ICharacterBody3D for RemotePlayer {
|
|||||||
|
|
||||||
if self.movement_dir.length_squared() > 0.
|
if self.movement_dir.length_squared() > 0.
|
||||||
&& self.base().is_on_floor()
|
&& self.base().is_on_floor()
|
||||||
|
&& !self.is_dead
|
||||||
&& let Some(effects) = &mut self.effects
|
&& let Some(effects) = &mut self.effects
|
||||||
{
|
{
|
||||||
effects.bind_mut().walk();
|
effects.bind_mut().walk();
|
||||||
|
|||||||
@ -7,9 +7,9 @@ use godot::{
|
|||||||
use serde::{Deserialize, Serialize};
|
use serde::{Deserialize, Serialize};
|
||||||
|
|
||||||
use crate::{
|
use crate::{
|
||||||
game_manager::{Game, GameOption},
|
game_manager::Game,
|
||||||
net::util::{cast_ray, shotgun_ray},
|
net::util::{cast_ray, shotgun_ray},
|
||||||
player::{DamageSource, IPlayer, ball::Ball, shootable::Shootable},
|
player::{DamageSource, shootable::Shootable},
|
||||||
};
|
};
|
||||||
|
|
||||||
pub trait Weapon {
|
pub trait Weapon {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user