Nuclide
Software Development Kit for id Tech
func_areaportal Class Reference

Server-Entity: Visibility/Areaportal Manager. More...

Inheritance diagram for func_areaportal:
NSEntity

Public Member Functions

void func_areaportal (void)
 
virtual void Spawned (void)
 Called when the entity is fulled initialized. More...
 
virtual void SpawnKey (string, string)
 This method handles entity key/value pairs on map load. More...
 
virtual void Trigger (entity, triggermode_t)
 Called whenever we're legacy triggered by another object or function. More...
 
virtual void Input (entity, string, string)
 Called when we are being prompted by another object/function with an input message. More...
 
virtual void Save (float)
 Handles saving a copy of this entity to a given filehandle. More...
 
virtual void Restore (string, string)
 Similar to NSIO::SpawnKey but for save-game fields. More...
 
nonvirtual void PortalOpen (void)
 
nonvirtual void PortalClose (void)
 

Detailed Description

Server-Entity: Visibility/Areaportal Manager.

QUAKED func_areaportal (0 .5 .8) ?

OVERVIEW

Manages a space between two areas. Requires to be positioned within an areaportal helper brush.

KEYS

  • "targetname" : Name
  • "StartOpen" : Sets the initial state. If 1 the portal will start open.

INPUTS

  • "Open" : Open the areaportal.
  • "Close" : Close the areaportal.
  • "Toggle" : Toggle the areaportal.

TRIVIA

This entity was introduced in Quake II (1997).

QUAKED func_areaportalwindow (0 .5 .8) ?

OVERVIEW

Manages a space between two areas, but only renders when a player is in the specified range.

Requires a helper func_brush entity that should be textured simple, and have 'Solidty' set to '1'. This entity will render instead of the culled area, and needs a targetname to be called by the areaportalwindow.

KEYS

  • "target" : The targetname of the helper func_brush entity.
  • "FadeStartDist" : Sets the distance for rendering the helper entity.
  • "FadeDist" : Sets the distance for closing the portal.
  • "TranslucencyLimit" : How much should the helper brush fade. Set to '0' for complete fadeout.
  • "BackgroundBModel" : Optional brush entity that can be drawn after the helper entity.

INPUTS

  • "SetFadeStartDistance" : Sets FadeStartDist.
  • "SetFadeEndDistance" : Sets FadeDist.

TRIVIA

This entity was introduced in Half-Life 2 (2004).

Constructor & Destructor Documentation

◆ func_areaportal()

void func_areaportal::func_areaportal ( void  )

Member Function Documentation

◆ Input()

void func_areaportal::Input ( entity  eAct,
string  strInput,
string  strData 
)
virtual

Called when we are being prompted by another object/function with an input message.

Reimplemented from NSEntity.

◆ PortalClose()

void func_areaportal::PortalClose ( void  )

◆ PortalOpen()

void func_areaportal::PortalOpen ( void  )

◆ Restore()

void func_areaportal::Restore ( string  strKey,
string  strValue 
)
virtual

Similar to NSIO::SpawnKey but for save-game fields.

Whatever you write into file handles within your NSIO::Save() method needs to be read back in here.

Reimplemented from NSEntity.

◆ Save()

void func_areaportal::Save ( float  handle)
virtual

Handles saving a copy of this entity to a given filehandle.

Within you want to use the NSIO::SaveFloat() etc. methods to write the internal member attributes to the specified file handle.

Reimplemented from NSEntity.

◆ Spawned()

void func_areaportal::Spawned ( void  )
virtual

Called when the entity is fulled initialized.

Any spawn key/value info pairs have already been dealt with. So now we can make full decisions on the entity. Always make sure to call super::Spawned(); inside your method when overriding.

Reimplemented from NSEntity.

◆ SpawnKey()

void func_areaportal::SpawnKey ( string  strKey,
string  strValue 
)
virtual

This method handles entity key/value pairs on map load.

You can easily convert the strValue parameter using the ReadFloat etc. methods that are part of NSIO.

Reimplemented from NSEntity.

◆ Trigger()

void func_areaportal::Trigger ( entity  act,
triggermode_t  state 
)
virtual

Called whenever we're legacy triggered by another object or function.

Reimplemented from NSTrigger.


The documentation for this class was generated from the following file: