add "template person" command

This commit is contained in:
yuni 2024-06-02 21:29:08 +02:00
parent f7002fd064
commit 0bbca303cb
2 changed files with 50 additions and 42 deletions

View file

@ -215,6 +215,44 @@ pub fn load_defs(mut ew_spawn: EventWriter<SpawnEvent>) {
debug!("Registering name: {}", name); debug!("Registering name: {}", name);
state.name = Some(name.to_string()); state.name = Some(name.to_string());
} }
["template", "person"] => {
// command: collider handcrafted
state.collider_is_one_mesh_of_scene = true;
// command: alive yes
state.is_alive = true;
state.is_lifeform = true;
state.is_suited = true;
// command: oxygen 0.864
state.is_lifeform = true;
state.is_suited = true;
state.oxygen = nature::OXY_D;
// command: engine monopropellant
state.engine_type = actor::EngineType::Monopropellant;
// command: thrust 1.2 1 1 14 1.5
state.thrust_forward = 1.2;
state.thrust_back = 1.0;
state.thrust_sideways = 1.0;
state.reaction_wheels = 14.0;
state.warmup_seconds = 1.5;
// command: wants maxrotation 0
state.wants_maxrotation = Some(0.0);
// command: wants maxvelocity 0
state.wants_maxvelocity = Some(0.0);
// command: pointofinterest yes
state.is_point_of_interest = true;
// command: density 200
state.density = 200.0;
// command: angularmomentum 0 0 0
state.angular_momentum = DVec3::ZERO;
}
// Parsing actors // Parsing actors
["actor", x, y, z, model] => { ["actor", x, y, z, model] => {
@ -291,6 +329,9 @@ pub fn load_defs(mut ew_spawn: EventWriter<SpawnEvent>) {
state.is_lifeform = true; state.is_lifeform = true;
state.is_suited = true; state.is_suited = true;
} }
["alive", "no"] => {
state.is_alive = false;
}
["vehicle", "yes"] => { ["vehicle", "yes"] => {
state.is_vehicle = true; state.is_vehicle = true;
} }

View file

@ -257,18 +257,14 @@ actor 0 0 0
actor 0 593051 0 suitv2 actor 0 593051 0 suitv2
template person
relativeto jupiter relativeto jupiter
orbit 221900e3 0.338 orbit 221900e3 0.338
player yes player yes
id player id player
density 200
collider handcrafted
oxygen 0.008 oxygen 0.008
health 0.3 health 0.3
angularmomentum 0 0 0
thrust 1.2 1 1 14 1.5
rotationy 135 rotationy 135
engine monopropellant
actor 10 -30 20 cruiser actor 10 -30 20 cruiser
name "Cruiser" name "Cruiser"
@ -284,18 +280,12 @@ actor 10 -30 20 cruiser
pointofinterest yes pointofinterest yes
actor -55e3 44e3 0 suitv2 actor -55e3 44e3 0 suitv2
template person
relativeto thebe relativeto thebe
id yuni id yuni
name "Yuni" name "Yuni"
chatid Yuni chatid Yuni
density 200
collider handcrafted
thrust 1.2 1 1 20 1.5
rotationx 180 rotationx 180
engine monopropellant
wants maxrotation 0
wants maxvelocity 0
pointofinterest yes
actor 5000 0 -3000 moonlet actor 5000 0 -3000 moonlet
name Moonlet name Moonlet
@ -315,26 +305,16 @@ actor 13200 300 -3000 hollow_asteroid
pointofinterest yes pointofinterest yes
angularmomentum 0 0.015 0 angularmomentum 0 0.015 0
actor 0 0 0 suitv2 actor 0 0 0 suitv2
template person
relativeto cultasteroid relativeto cultasteroid
name "Ash" name "Ash"
chatid Ash chatid Ash
alive yes
collider handcrafted
thrust 1.2 1 1 20 1.5
wants maxrotation 0
wants maxvelocity 0
angularmomentum 0 0 0
pronoun they pronoun they
actor -8 8 0 suitv2 actor -8 8 0 suitv2
template person
relativeto cultasteroid relativeto cultasteroid
name "River" name "River"
chatid River chatid River
alive yes
collider handcrafted
thrust 1.2 1 1 20 1.5
wants maxrotation 0
wants maxvelocity 0
angularmomentum 0 0 0
rotationy 54 rotationy 54
rotationx -90 rotationx -90
pronoun she pronoun she
@ -470,35 +450,25 @@ actor -3300 10 0 pizzeria
pronoun it pronoun it
actor -45 -4 -4 suitv2 actor -45 -4 -4 suitv2
template person
relativeto pizzeria relativeto pizzeria
name "Nox" name "Nox"
chatid PizzaChef chatid PizzaChef
armodel suit_ar_chefhat armodel suit_ar_chefhat
alive yes
collider handcrafted
thrust 1.2 1 1 20 1.5
wants maxrotation 0
wants maxvelocity 0
wants lookat PLAYERCAMERA wants lookat PLAYERCAMERA
rotationy -90 rotationy -90
angularmomentum 0 0 0
pronoun he pronoun he
actor 30 -12 -40 suitv2 actor 30 -12 -40 suitv2
template person
relativeto player relativeto player
name Icarus name Icarus
id Icarus id Icarus
chatid Icarus chatid Icarus
armodel suit_ar_wings armodel suit_ar_wings
alive yes
collider handcrafted
angularmomentum 0.4 0.2 0.1 angularmomentum 0.4 0.2 0.1
rotationy 108 rotationy 108
rotationx 180 rotationx 180
pointofinterest yes
thrust 1.2 1 1 20 1.5
wants maxrotation 0.5
wants maxvelocity 0
pronoun it pronoun it
actor 12 -35 -27 lightorb actor 12 -35 -27 lightorb
name "Light Orb" name "Light Orb"
@ -522,13 +492,13 @@ actor 30 -12 -40 suitv2
light FF8F4A 5000000 light FF8F4A 5000000
actor -300 0 40 suitv2 actor -300 0 40 suitv2
template person
relativeto player relativeto player
id Drifter id Drifter
name "梓涵" name "梓涵"
chatid Drifter chatid Drifter
alive no
oxygen 0.08 oxygen 0.08
pointofinterest yes
collider handcrafted
pronoun she pronoun she
actor 100 -18000 2000 clippy actor 100 -18000 2000 clippy
@ -674,12 +644,9 @@ actor 100 -18000 2000 clippy
scale 5 scale 5
actor 8 20 0 suitv2 actor 8 20 0 suitv2
template person
relativeto "busstopclippy" relativeto "busstopclippy"
name "Rudy" name "Rudy"
wants maxrotation 0.2
wants maxvelocity 0
thrust 1.2 1 1 20 1.5
collider capsule 1 0.5
chatid NPCinCryoStasis chatid NPCinCryoStasis
pronoun he pronoun he