|
Xonotic QuakeC
The free, fast arena FPS with crisp movement and a wide array of weapons
|
|
Source file that contains implementation of the functions related to creation of game items. More...
#include "spawning.qh"#include <common/mapobjects/subs.qh>#include <common/mutators/mutator/powerups/_mod.qh>#include <common/weapons/all.qh>#include <server/items/items.qh>#include <server/mutators/_mod.qh>#include <server/weapons/spawning.qh>#include <server/world.qh>Go to the source code of this file.
Functions | |
| bool | Item_Initialise (entity item) |
| An optimised and generic way to initialise items (loot or permanent) | |
| bool | Item_IsDefinitionAllowed (entity definition) |
| Checks whether the items with the specified definition are allowed to spawn. | |
| entity | Item_RandomFromList (string itemlist) |
| Takes a space-separated list of netnames, returns the itemdef of one of them (or NULL if none are available). | |
Source file that contains implementation of the functions related to creation of game items.
Definition in file spawning.qc.
An optimised and generic way to initialise items (loot or permanent)
| [in] | item | The item entity to initialise |
Definition at line 27 of file spawning.qc.
References entity(), FOREACH, ITEM_SET_LOOT, LABEL, LOG_FATALF, StartItem(), time, weapon_defaultspawnfunc(), and Weapons.
Referenced by monster_dropitem(), MUTATOR_HOOKFUNCTION(), ok_DropItem(), powerups_DropItem(), RandomItems_ReplaceMapItem(), and RandomItems_SpawnLootItem().
Checks whether the items with the specified definition are allowed to spawn.
| [in] | definition | Item definition to check. |
Definition at line 17 of file spawning.qc.
References entity(), and MUTATOR_CALLHOOK.
Referenced by Item_RandomFromList(), RandomItems_GetRandomInstagibItemClassName(), RandomItems_GetRandomItemClassNameWithProperty(), RandomItems_GetRandomOverkillItemClassName(), and weapon_defaultspawnfunc().
Takes a space-separated list of netnames, returns the itemdef of one of them (or NULL if none are available).
Definition at line 71 of file spawning.qc.
References entity(), FOREACH, FOREACH_WORD, ITEM_FLAG_NORMAL, Item_IsDefinitionAllowed(), NULL, RandomSelection_AddEnt, RandomSelection_chosen_ent, RandomSelection_Init(), Weapons, and WEP_FLAG_MUTATORBLOCKED.
Referenced by monster_dropitem(), and ok_DropItem().