~starkingdoms/starkingdoms

ref: e3dc9c372e5372aaca738c2346313a626530fa25 starkingdoms/crates/unified/src/shared/net/planet.rs -rw-r--r-- 493 bytes
e3dc9c37 — core Revert "netcode: part updates (mystery performance issue, probably related to lots of malloc())" 7 days ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
use bevy::prelude::{Entity, Message, Transform, TypePath};
use serde::{Deserialize, Serialize};
use crate::shared::config::planet::Planet;

#[derive(Serialize, Deserialize, Message, TypePath, Debug, Clone)]
pub struct PlanetUpdatePacket {
    pub updated_planets: Vec<UpdatedPlanet>
}

#[derive(Serialize, Deserialize, TypePath, Debug, Clone)]
pub struct UpdatedPlanet {
    pub server_entity: Entity,

    pub planet: Planet,
    pub planet_data_changed: bool,

    pub transform: Transform
}