Atrinik Server  4.0
Functions
bullet.c File Reference
#include <global.h>
#include <object.h>
#include <player.h>
#include <object_methods.h>

Go to the source code of this file.

Functions

static void process_func (object *op)
 
static int projectile_hit_func (object *op, object *victim)
 
 OBJECT_TYPE_INIT_DEFINE (bullet)
 

Detailed Description

Handles code related to bullet.

Definition in file bullet.c.

Function Documentation

OBJECT_TYPE_INIT_DEFINE ( bullet  )

Initialize the bullet type object methods.

Definition at line 86 of file bullet.c.

static void process_func ( object op)
static

Processes an object, giving it the opportunity to move or react.

Parameters
opThe object to process.

Definition at line 37 of file bullet.c.

static int projectile_hit_func ( object op,
object victim 
)
static

Called when a fired object finds an alive object on the square it just moved to.

Parameters
opThe fired object.
victimThe found alive object. Note that this just means that the object is on the LAYER_LIVING layer, which may or may not imply that the object is actually alive.
Return values
OBJECT_METHOD_OKSuccessfully processed and should stop the fired arch.
OBJECT_METHOD_UNHANDLEDDid not handle the event, should continue trying to look for another alive object.
OBJECT_METHOD_ERROR'op' was destroyed.

Definition at line 62 of file bullet.c.