Nuclide
Software Development Kit for id Technology (BETA)
ncMapDelegate Class Reference

About this class

This class delegates active MapC logic.

The ncMapDelegate class is for any set of active level specific logic. It can be accessed in QuakeC via the global g_grMap from the server-side.

Startup

Upon server init, the game will attempt to find a MapC progs file alongside the BSP or MAP that is being played on.

If you load map foobar in the console, and it'll find the map at <gamedir>/maps/foobar.bsp, then our server-game will look for a MapC progs over at <gamedir>/maps/foobar.dat.

Implementing MapC Progs

Similarily to RuleC, that progs can be implemented with as many binds to the ncMapDelegate class as you like. The only requirement is you include the header found under src/server/api.h.

Example MapC

To be written.

Class To Progs Callback Mappings

Left = class method, right = name of the callback function for you to implement in progs.

To be written.**

The underlying return values and parameters are inherited from its class counter-part.

Inheritance diagram for ncMapDelegate:
ncIO

Public Member Functions

void ncMapDelegate (void)
 
virtual void Input (entity, string, string)
 Called when we are being prompted by another object/function with an input message. More...
 
virtual void Precache (void)
 Overridable: Called from initents(). More...
 
virtual void FrameStart (void)
 Overridable: Called every server frame. More...
 
virtual void PlayerConnect (ncPlayer)
 Overridable: Called when a ncPlayer joins the server. More...
 
virtual void PlayerDisconnect (ncPlayer)
 Overridable: Called when a ncPlayer leaves the server. More...
 
virtual void PlayerSpawn (ncPlayer)
 Overridable: Called when a ncPlayer spawns, called sometime after joining. More...
 
virtual void PlayerDeath (ncPlayer, ncEntity, ncEntity, string)
 Overridable: Called when a ncPlayer dies in the game. More...
 
virtual void PlayerPain (ncPlayer, ncActor, ncDict)
 Overridable: Called when a ncPlayer feels pain. More...
 
virtual void NPCDeath (ncActor, ncEntity, ncEntity)
 Overridable:: Called when an NPC gets killed. More...
 
nonvirtual void LinkProgs (void)
 
nonvirtual ncMapDelegate ActiveInstance (void)
 

Constructor & Destructor Documentation

◆ ncMapDelegate()

void ncMapDelegate::ncMapDelegate ( void  )

Member Function Documentation

◆ ActiveInstance()

ncMapDelegate ncMapDelegate::ActiveInstance ( void  )

◆ FrameStart()

void ncMapDelegate::FrameStart ( void  )
virtual

Overridable: Called every server frame.

◆ Input()

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

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

Reimplemented from ncIO.

◆ LinkProgs()

void ncMapDelegate::LinkProgs ( void  )

◆ NPCDeath()

void ncMapDelegate::NPCDeath ( ncActor  npc,
ncEntity  attacker,
ncEntity  inflictor 
)
virtual

Overridable:: Called when an NPC gets killed.

◆ PlayerConnect()

void ncMapDelegate::PlayerConnect ( ncPlayer  pl)
virtual

Overridable: Called when a ncPlayer joins the server.

◆ PlayerDeath()

void ncMapDelegate::PlayerDeath ( ncPlayer  deadPlayer,
ncEntity  inflictor,
ncEntity  attacker,
string  weaponDef 
)
virtual

Overridable: Called when a ncPlayer dies in the game.

◆ PlayerDisconnect()

void ncMapDelegate::PlayerDisconnect ( ncPlayer  pl)
virtual

Overridable: Called when a ncPlayer leaves the server.

◆ PlayerPain()

void ncMapDelegate::PlayerPain ( ncPlayer  pl,
ncActor  attacker,
ncDict  damageDecl 
)
virtual

Overridable: Called when a ncPlayer feels pain.

◆ PlayerSpawn()

void ncMapDelegate::PlayerSpawn ( ncPlayer  pl)
virtual

Overridable: Called when a ncPlayer spawns, called sometime after joining.

◆ Precache()

void ncMapDelegate::Precache ( void  )
virtual

Overridable: Called from initents().


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