Parallax holders
Holds all the information about a client's parallax
Not on mob because parallax is area based, not mob based.
How parallax works:
- Layers - normal layers, scroll with movement to relative position, can scroll
- Absolute - absolute layers, scroll with movement to absolute position, cannot scroll
- Vis - vis_contents-like model - things in this are directly applied and get no processing whatsoever. Things like overmap ships can use this.
Vars | |
cached_eye | Eye we were last anchored to - used to detect eye changes |
---|---|
forced_eye | force this eye as the "real" eye - useful for secondary maps |
last | last turf loc |
last_area | last area - for parallax scrolling/loop animations |
layers | all layers |
owner | Client that owns us |
parallax | The parallax object we're currently rendering |
planemaster_override | override planemaster we manipulate for turning and other effects |
scroll_speed | current scroll speed in DS per scroll |
scroll_turn | current scroll turn - applied after angle. if angle is 0 (picture moving north) and turn is 90, it would be like if you turned your viewport 90 deg clockwise. |
scrolling | currently scrolling? |
secondary_map | are we not on the main map? if so, put map id here |
vis | vis contents |
vis_holder | Holder object for vis |
Procs | |
Animation | Runs a modifier to parallax as an animation. |
Eye | Gets the eye we should be centered on |
GetPlaneMaster | Gets the base parallax planemaster for things like turning |
HardResetAnimations | fully resets animation state |
StopScrolling | Smoothly stops the animation, turning to a certain angle as needed. |
Sync | Syncs us to our parallax objects. Does NOT check if we should have those objects, that's Reset()'s job. |
UpdateMotion | Updates motion if needed |
Var Details
cached_eye
Eye we were last anchored to - used to detect eye changes
forced_eye
force this eye as the "real" eye - useful for secondary maps
last
last turf loc
last_area
last area - for parallax scrolling/loop animations
layers
all layers
owner
Client that owns us
parallax
The parallax object we're currently rendering
planemaster_override
override planemaster we manipulate for turning and other effects
scroll_speed
current scroll speed in DS per scroll
scroll_turn
current scroll turn - applied after angle. if angle is 0 (picture moving north) and turn is 90, it would be like if you turned your viewport 90 deg clockwise.
scrolling
currently scrolling?
secondary_map
are we not on the main map? if so, put map id here
vis
vis contents
vis_holder
Holder object for vis
Proc Details
Animation
Runs a modifier to parallax as an animation.
@params speed - ds per loop turn - angle clockwise from north to turn the motion to windup - ds to spend on windups. 0 for immediate. turn_speed - ds to spend on turning. 0 for immediate.
Eye
Gets the eye we should be centered on
GetPlaneMaster
Gets the base parallax planemaster for things like turning
HardResetAnimations
fully resets animation state
StopScrolling
Smoothly stops the animation, turning to a certain angle as needed.
Sync
Syncs us to our parallax objects. Does NOT check if we should have those objects, that's Reset()'s job.
Doesn't move/update positions/screen locs either.
Also ensures movedirs are correct for the eye's pos.
UpdateMotion
Updates motion if needed