![]() |
Platformer Pro
2.3.2
A platform game kit for Unity.
|
A point at which the character can respawn. Transform should exactly match where the character will spawn. More...
Public Member Functions | |
virtual void | SetActive (Character c) |
Set this respawn point as the active one. More... | |
virtual void | SetEnabled () |
Enable this respawn point. More... | |
![]() | |
void | SetPersistenceState (bool state) |
Sets the persistence state. More... | |
void | SetPersistenceState (bool state, string extraPersistenceData) |
Sets the persistence state, overriding extra persistence data More... | |
![]() | |
virtual void | Validate (PlatformerProMonoBehaviour myTarget) |
Override this method if you want to provide custom validation. The actual code should be surrounded by the if UNITY_EDITOR / endif directive. More... | |
Public Attributes | |
bool | isDefaultStartingPoint |
Is this point the default starting point which is activated on scene load. More... | |
string | identifier |
Unique name for this respawn point. More... | |
bool | dontActivateOnRespawn |
If true the respawn point wont be activated when you spawn here. Generally used for doors so you can respawn at a position but if you die you wont go back there. More... | |
float | autoProximityTriggerRange |
If true create a proximity trigger which activates the respawn point automatically. More... | |
Sprite | autoSwitchSprite |
If non-null the Respawn Point will try to find an image component and update its sprite. If you want to do more use an EventResponder to listen to the Activated Event or create a custom trigger. More... | |
int | facingDirection |
Set the facing direction on spawn as either LEFT (-1), RIGHT (1) or NO_CHANGE (use whatever direction was last faced). More... | |
jnamobile.mmm.PointOfInterest | poi |
Reference to point of interest on a map. You can use this to override door POI settings. More... | |
bool | useDefaultPersistence = true |
Does this Item get persistence defaults form the Game manager? More... | |
![]() | |
bool | enablePersistence |
Should we enable persistence? More... | |
string | guid = System.Guid.NewGuid().ToString() |
Unique ID for this object. You shoulnd't need to edit this, use editor debug mode if you must. More... | |
GameObject | target |
GameObject to apply persitence settings to, defaults to self. More... | |
PersistableObjectType | persistenceImplementation |
How do we implement the persistence settings. More... | |
bool | defaultStateIsDisabled |
If true then the obejct starts disabled. More... | |
string | spawnedObjectName |
If this item was spawned then save the name of the prefab here. More... | |
Protected Member Functions | |
void | OnActivated (Character c) |
Raises the activated event. More... | |
virtual void | Init () |
Init this instance. More... | |
override void | PostInit () |
PostInit this instance. Called from Start. More... | |
virtual void | CreateProximityTrigger (float range) |
Creates a basic proximity trigger for enabling respawn point. More... | |
override void | SetPersistenceDefaults () |
Sets the persistence defaults. More... | |
override void | ApplyCustomPersistence (PersistableObjectData data) |
Custom persistable implementation. Override to customise. More... | |
![]() | |
virtual void | ProcessState () |
Processes the persisted state. More... | |
virtual void | ApplyExtraPersistenceData (PersistableObjectData data) |
Apply any extra data. This differs from custom persistence, as custom persistence must control both data and ctivation state. More... | |
Protected Attributes | |
SpriteRenderer | spriteRenderer |
Cached sprite reference used if auto switch sprite is true. More... | |
Properties | |
override string | Header [get] |
Gets the header string used to describe the component. More... | |
bool | IsActive [get] |
Returns true if this Respawn Point is active. More... | |
bool | IsEnabled [get] |
Returns true if this Respawn Point is enabled. More... | |
![]() | |
virtual string | ExtraPersistenceData [get] |
Gets the extra persistence data. More... | |
![]() | |
virtual string | Header [get] |
Gets the header string used to describe the component. More... | |
virtual string | DocLink [get] |
Gets a link to documentation site. More... | |
virtual string | VideoLink [get] |
Gets a link to a youtube video. More... | |
virtual string | Deprecated [get] |
If non-null this component is deprecated. The string shows a message indicating how it should be replaced. More... | |
Events | |
System.EventHandler< CharacterEventArgs > | Activated |
Event trigger when this spawn point is activated. More... | |
A point at which the character can respawn. Transform should exactly match where the character will spawn.
|
protectedvirtual |
Custom persistable implementation. Override to customise.
data | Data. |
Reimplemented from PlatformerPro.PersistableObject.
|
protectedvirtual |
Creates a basic proximity trigger for enabling respawn point.
range | Range. |
|
protectedvirtual |
Init this instance.
|
protected |
Raises the activated event.
c | Character ref. |
|
protectedvirtual |
PostInit this instance. Called from Start.
Reimplemented from PlatformerPro.PersistableObject.
|
virtual |
Set this respawn point as the active one.
|
virtual |
Enable this respawn point.
|
protectedvirtual |
Sets the persistence defaults.
Reimplemented from PlatformerPro.PersistableObject.
float PlatformerPro.RespawnPoint.autoProximityTriggerRange |
If true create a proximity trigger which activates the respawn point automatically.
Sprite PlatformerPro.RespawnPoint.autoSwitchSprite |
If non-null the Respawn Point will try to find an image component and update its sprite. If you want to do more use an EventResponder to listen to the Activated Event or create a custom trigger.
bool PlatformerPro.RespawnPoint.dontActivateOnRespawn |
If true the respawn point wont be activated when you spawn here. Generally used for doors so you can respawn at a position but if you die you wont go back there.
int PlatformerPro.RespawnPoint.facingDirection |
Set the facing direction on spawn as either LEFT (-1), RIGHT (1) or NO_CHANGE (use whatever direction was last faced).
string PlatformerPro.RespawnPoint.identifier |
Unique name for this respawn point.
bool PlatformerPro.RespawnPoint.isDefaultStartingPoint |
Is this point the default starting point which is activated on scene load.
jnamobile.mmm.PointOfInterest PlatformerPro.RespawnPoint.poi |
Reference to point of interest on a map. You can use this to override door POI settings.
|
protected |
Cached sprite reference used if auto switch sprite is true.
bool PlatformerPro.RespawnPoint.useDefaultPersistence = true |
Does this Item get persistence defaults form the Game manager?
|
get |
Gets the header string used to describe the component.
The header.
|
get |
Returns true if this Respawn Point is active.
|
get |
Returns true if this Respawn Point is enabled.
System.EventHandler<CharacterEventArgs> PlatformerPro.RespawnPoint.Activated |
Event trigger when this spawn point is activated.