mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-18 01:02:23 +00:00
feat(selection): selecting a contact keeps its size and the camera's view: aircraft, vessels, trains and transit vehicles keep their form and size when selected (colour only); a click follows from the camera's own distance and angle, the contact gliding to the centre over one second (FollowTarget transitionS, shared rule render/camera/followTransition, conformance camera.follow.transition)
This commit is contained in:
1 parent
e3865f462f
commit
7a61bf04a0
52 files changed
+1648
-891
No files matched your search
@@ -212,7 +212,8 @@ export function createRendering({
|
||||
pos: visual.position,
|
||||
image: shipIcon(record, selected),
|
||||
size: [SHIP_ICON_PX, SHIP_ICON_PX],
|
||||
scale: shipScale(record) * (selected ? 1.2 : 1),
|
||||
// Selection changes the colour only, never the size.
|
||||
scale: shipScale(record),
|
||||
rotationMode: 'course',
|
||||
// Held on course; `course` for renderers without motion segments.
|
||||
course: courseDeg,
|
||||
|
||||
@@ -125,6 +125,8 @@ export function createSelection({
|
||||
id: record.id,
|
||||
label: record.name || record.mmsi || record.id,
|
||||
position: components.rendering.iconPosition(record),
|
||||
// The camera keeps its distance and angle; the vessel slides to the centre.
|
||||
keepView: true,
|
||||
});
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user