 |
Crossfire Server, Trunk
1.75.0
|
Go to the documentation of this file.
66 if (old_transport && old_transport != op) {
69 "You must exit %s before you can board %s.",
86 "You disembark from %s.",
90 old_transport->
contr = NULL;
108 "%s has disembarked. You are now the captain of %s",
109 applier->
name, name_old);
124 "The %s is unable to hold your weight!",
130 if (op->
env == applier) {
137 "You cannot drop the %s in a shop to use it.",
144 "You need to drop the %s to use it.",
163 "The %s does not have space for any more people",
173 "The %s's captain is currently %s",
177 "You're the %s's captain",
190 if (ox != op->
x || oy != op->
y) {
218 base_speed = atof(kv);
225 if (op->
speed < 0.10)
#define AP_APPLY
Item is to be applied.
void esrv_map_scroll(socket_struct *ns, int dx, int dy)
uint16_t look_position
Start of drawing of look window.
void init_type_transport(void)
Initializer for the TRANSPORT object type.
struct archetype * arch
Pointer to archetype.
int16_t players
How many players are on this level right now.
void register_apply(int ob_type, apply_func method)
Registers the apply method for the given type.
float speed
Frequency of object 'moves' relative to server tick rate.
object * ob
The object representing the player.
object * transport
Transport the player is in.
float speed_left
How much speed is left to spend this round.
struct mapstruct * map
Pointer to the map in which this object is present.
void draw_ext_info_format(int flags, int pri, const object *pl, uint8_t type, uint8_t subtype, const char *format,...) PRINTF_ARGS(6
@ TRANSPORT
see doc/Developers/objects
void register_process(int ob_type, process_func method)
Registers the process method for the given type.
const char * object_get_value(const object *op, const char *const key)
Get an extra value by key.
object * object_insert_in_ob(object *op, object *where)
This function inserts the object op in the linked list inside the object environment.
uint32_t update_look
If true, we need to send the look window.
int32_t carrying
How much weight this object contains.
int16_t y
Position in the map for this object.
struct player * contr
Pointer to the player which control this object.
#define MSG_TYPE_APPLY_SUCCESS
Was able to apply object.
void query_name(const object *op, char *buf, size_t size)
Describes an item.
object clone
An object from which to do object_copy()
int32_t weight_limit
Weight-limit of object.
int transport_can_hold(const object *transport, const object *op, int nrof)
Can transport hold object op? This is a pretty trivial function, but in the future,...
const Face * face
Face with colors.
uint8_t type
PLAYER, BULLET, etc.
#define FOR_INV_FINISH()
Finishes FOR_INV_PREPARE().
const Animations * animation
Animation of this item, NULL if not animated.
object * object_insert_in_map_at(object *op, mapstruct *m, object *originator, int flag, int x, int y)
Same as object_insert_in_map() except it handle separate coordinates and do a clean job preparing mul...
#define MAX_BUF
Used for all kinds of things.
object * drop_object(object *op, object *tmp, uint32_t nrof)
Try to drop an object on the floor.
char method_ret
Define some standard return values for callbacks which don't need to return any other results.
#define NDI_UNIQUE
Print immediately, don't buffer.
static method_ret transport_type_process(object *op)
Processes a Transport.
sstring name
The name of the object, obviously...
object * object_find_by_type(const object *who, int type)
Find object in inventory.
object * env
Pointer to the object which is the environment.
static method_ret transport_type_apply(object *op, object *applier, int aflags)
Player is trying to use a transport.
Animations * find_animation(const char *name)
void object_remove(object *op)
This function removes the object op from the linked list of objects which it is currently tied to.
signed long object_sum_weight(object *op)
object_sum_weight() is a recursive function which calculates the weight an object is carrying.
const Face * try_find_face(const char *name, const Face *error)
socket_struct * socket
Socket information for this player.
#define AP_UNAPPLY
Item is to be remvoed.
bool shop_contains(object *ob)
Check if an object is in a shop.
#define MSG_TYPE_APPLY
Applying objects.
#define MSG_TYPE_APPLY_ERROR
#define FOR_INV_PREPARE(op_, it_)
Constructs a loop iterating over the inventory of an object.
#define METHOD_SILENT_ERROR
Player was warned she can't use the item for now.
#define MSG_TYPE_APPLY_UNAPPLY
Unapply an object.