User Tools

Site Tools


al:liveactor

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
al:liveactor [2022/03/17 13:50] fruityloopsal:liveactor [2022/05/16 10:16] (current) fruityloops
Line 1: Line 1:
 ====== al::LiveActor ====== ====== al::LiveActor ======
-LiveActor is a class that represents an actor in a scene((usually StageScene or DemoScene)). This can be an enemy, level geometry, or anything in between. Most inherited classes use the Nerve system to distribute code to different functions, instead of just 1 update function.+LiveActor is a class that represents an actor in a scene((usually StageScene)). This can be an enemy, level geometry, or anything in between. Most inherited classes use the Nerve system to distribute code to different functions, instead of just 1 update function.
  
-===== Alive & Dead ===== +===== Clipping ===== 
-StageScene uses its camera and other factors to determine if a LiveActor is currently "alive" or "dead", alive meaning its code is being run, dead meaning it is notFor StageScene actors that are not on screen are dead, which benefits performance. +If a LiveActor is "clipped", its code is not being run and it is essentially being ignoredWhether or not a LiveActor is clipped is managed by the scene it is in, usually its archive gives the scene a clipping radius which determines how far the LiveActor can be from the camera before it is clipped, to save on performance.
- +
-===== Functions ===== +
-==== init ==== +
-This function takes an ActorInitInfo parameter with the [[https://zeldamods.org/wiki/BYML|BYML]] node this actor is being created from in the stage file. It is used by inherited classes to initialize the Nerve system and the actor itself. +
-==== makeActorAlive & makeActorDead ==== +
-These functions manually make the actor alive/dead. +
-==== movement ==== +
-This is the internal "update" function for LiveActor. It updates all "Keepers" (NerveKeeper, etc.), and calls [[al:liveactor#control|control]]. +
-==== control ==== +
-This function is called every frame if the actor is alive.+
al/liveactor.1647525007.txt.gz · Last modified: 2022/03/17 13:50 by fruityloops