 |
Crossfire Server, Trunk
1.75.0
|
Go to the documentation of this file.
38 auto arch = item->
arch;
90 if (arch.second->clone.name == tmp) {
102 if (arch.second->clone.type ==
type && strcmp(arch.second->clone.name,
name) == 0)
114 if (((
type == -1) || (
type == arch.second->clone.type))
115 && (arch.second->clone.skill) && (!strcmp(arch.second->clone.skill,
skill)))
123 if (((
type == -1) || (
type == arch.second->clone.type))
124 && (subtype == -1 || subtype == arch.second->clone.subtype))
object * inv
Pointer to the first object in the inventory.
archetype * get_archetype_struct(void)
Allocates, initialises and returns the pointer to an archetype structure.
struct archetype * arch
Pointer to archetype.
StringBuffer * stringbuffer_new(void)
Create a new string buffer.
void object_copy_with_inv(const object *src_ob, object *dest_ob, bool update_speed)
Copy an object with an inventory, duplicate the inv too.
void free_arch(archetype *at)
Frees archetype.
void asset_destroy(archetype *item)
Plugin animator file specs[Config] name
char * stringbuffer_finish(StringBuffer *sb)
Deallocate the string buffer instance and return the string.
archetype * asset_create(const std::string &name)
object clone
An object from which to do object_copy()
sstring add_string(const char *str)
This will add 'str' to the hash table.
object * below
Pointer to the object stacked below this one.
static void recursive_update(object *item, archetype *updated)
Update if needed item based on the updated archetype, then recurse on item->below and item->inv.
sstring find_string(const char *str)
Searches a string in the shared strings.
archetype * findBySkillNameAndType(const char *skill, int type)
Retrieve an archetype by skill name and type.
The archetype structure is a set of rules on how to generate and manipulate objects which point to ar...
it was updated by reverse engineering the client code accessing the metaserver It therefore describes the as is state rather than what was intended Communication between server and metaserver was not updated
static void mark_inv_not_removed(object *item)
Recursively mark all items in inventory as not removed.
archetype * findByTypeSubtype(int type, int subtype)
Retrieve an archetype by type and subtype.
#define FLAG_REMOVED
Object is not in any map or invenory.
int set_variable(object *op, const char *buf)
This takes a buffer, scans it for variables, and sets those variables as appropriate in op.
#define CLEAR_FLAG(xyz, p)
void get_ob_diff(StringBuffer *sb, const object *op, const object *op2)
Returns a pointer to a static string which contains all variables which are different in the two give...
virtual void replace(archetype *existing, archetype *update) override
Replace an asset by an updated version.
archetype * findByObjectName(const char *name)
Retrieve an archetype given the name that appears during the game (for example, "writing pen" instead...
std::unordered_map< std::string, archetype * > m_assets
Known assets.
sstring name
More definite name, like "generate_kobold".
updateListener m_updateListener
void object_free_inventory(object *ob)
Frees the inventory of an object, without any callback.
archetype * findByObjectTypeName(int type, const char *name)
Retrieve an archetype by type and name that appears during the game.