Compare commits

...

3 commits

Author SHA1 Message Date
yuni 20ff266cc4 add 2 stray moonlets near thebe 2024-10-05 03:11:55 +02:00
yuni 2409da8fed cleanup 2024-10-05 03:03:19 +02:00
yuni 7a7b4422d1 more efficient collider on moonlet 2024-10-05 02:56:59 +02:00
2 changed files with 20 additions and 3 deletions

View file

@ -696,7 +696,7 @@ fn handle_wants_maxvelocity(
} }
fn handle_wants_lookat( fn handle_wants_lookat(
mut query: Query<(&Position, &mut Rotation, &Transform, &WantsToLookAt), Without<Camera>>, mut query: Query<(&Position, &mut Rotation, &WantsToLookAt), Without<Camera>>,
q_playercam: Query<&Position, With<PlayerCamera>>, q_playercam: Query<&Position, With<PlayerCamera>>,
q_cam: Query<&Transform, With<Camera>>, q_cam: Query<&Transform, With<Camera>>,
id2pos: Res<game::Id2Pos>, id2pos: Res<game::Id2Pos>,
@ -713,7 +713,7 @@ fn handle_wants_lookat(
}; };
// TODO: use ExternalTorque rather than hard-resetting the rotation // TODO: use ExternalTorque rather than hard-resetting the rotation
for (pos, mut rot, trans, target_id) in &mut query { for (pos, mut rot, target_id) in &mut query {
let target_pos: DVec3 = if target_id.0 == cmd::ID_SPECIAL_PLAYERCAM { let target_pos: DVec3 = if target_id.0 == cmd::ID_SPECIAL_PLAYERCAM {
cam_pos cam_pos
} else if let Some(target_pos) = id2pos.0.get(&target_id.0) { } else if let Some(target_pos) = id2pos.0.get(&target_id.0) {

View file

@ -144,6 +144,23 @@ actor 0 0 0
only_in_map_at_dist 1e7 thebe only_in_map_at_dist 1e7 thebe
clickable no clickable no
physics off physics off
actor 0 -53e3 0 metis
name Moonlet
relativeto jupiter
orbitaround jupiter 221900e3
orbit_phase_offset 0.0003
collider handcrafted
density 10000000000
scale 6e3
angularmomentum 0.01 0 0
actor 120e3 0 0 metis
name Moonlet
relativeto jupiter
orbitaround jupiter 221900e3
collider handcrafted
density 10000000000
scale 3e3
angularmomentum 0 0.03 0
actor 0 0 0 io actor 0 0 0 io
name Io name Io
id io id io
@ -334,7 +351,7 @@ actor -55e3 44e3 0 suitv2
actor 5000 0 -3000 metis actor 5000 0 -3000 metis
name Moonlet name Moonlet
collider mesh collider handcrafted
relativeto player relativeto player
density 10000000000 density 10000000000
scale 500 scale 500