SYMBOL INDEX (1447 symbols across 89 files) FILE: nmmo/core/action.py class NodeType (line 12) | class NodeType(Enum): class Node (line 22) | class Node(metaclass=utils.IterableNameComparable): method init (line 24) | def init(cls, config): method edges (line 29) | def edges(): method priority (line 34) | def priority(): method type (line 38) | def type(): method leaf (line 42) | def leaf(): method N (line 46) | def N(cls, config): method deserialize (line 49) | def deserialize(realm, entity, index: int, obs: Observation): class Fixed (line 52) | class Fixed: class Action (line 56) | class Action(Node): method init (line 61) | def init(cls, config): method hook (line 70) | def hook(config): method n (line 87) | def n(): method edges (line 92) | def edges(cls, config): class Move (line 105) | class Move(Node): method call (line 108) | def call(realm, entity, direction): method edges (line 152) | def edges(): method leaf (line 156) | def leaf(): method enabled (line 159) | def enabled(config): class Direction (line 162) | class Direction(Node): method edges (line 166) | def edges(): method deserialize (line 169) | def deserialize(realm, entity, index: int, obs): function deserialize_fixed_arg (line 173) | def deserialize_fixed_arg(arg, index): class North (line 185) | class North(Node): class South (line 188) | class South(Node): class East (line 191) | class East(Node): class West (line 194) | class West(Node): class Stay (line 197) | class Stay(Node): class Attack (line 200) | class Attack(Node): method n (line 204) | def n(): method edges (line 208) | def edges(): method leaf (line 212) | def leaf(): method enabled (line 215) | def enabled(config): method in_range (line 218) | def in_range(entity, stim, config, N): method call (line 231) | def call(realm, entity, style, target): class Style (line 272) | class Style(Node): method edges (line 275) | def edges(): method deserialize (line 278) | def deserialize(realm, entity, index: int, obs): class Target (line 281) | class Target(Node): method N (line 285) | def N(cls, config): method deserialize (line 288) | def deserialize(realm, entity, index: int, obs: Observation): class Melee (line 293) | class Melee(Node): method attack_range (line 297) | def attack_range(config): method skill (line 300) | def skill(entity): class Range (line 303) | class Range(Node): method attack_range (line 307) | def attack_range(config): method skill (line 310) | def skill(entity): class Mage (line 313) | class Mage(Node): method attack_range (line 317) | def attack_range(config): method skill (line 320) | def skill(entity): class InventoryItem (line 323) | class InventoryItem(Node): method N (line 327) | def N(cls, config): method deserialize (line 330) | def deserialize(realm, entity, index: int, obs: Observation): class Use (line 335) | class Use(Node): method edges (line 339) | def edges(): method enabled (line 342) | def enabled(config): method call (line 345) | def call(realm, entity, item): class Destroy (line 368) | class Destroy(Node): method edges (line 372) | def edges(): method enabled (line 375) | def enabled(config): method call (line 378) | def call(realm, entity, item): class Give (line 402) | class Give(Node): method edges (line 406) | def edges(): method enabled (line 409) | def enabled(config): method call (line 412) | def call(realm, entity, item, target): class GiveGold (line 460) | class GiveGold(Node): method edges (line 464) | def edges(): method enabled (line 468) | def enabled(config): method call (line 471) | def call(realm, entity, amount, target): class MarketItem (line 508) | class MarketItem(Node): method N (line 512) | def N(cls, config): method deserialize (line 515) | def deserialize(realm, entity, index: int, obs: Observation): class Buy (line 520) | class Buy(Node): method edges (line 525) | def edges(): method enabled (line 528) | def enabled(config): method call (line 531) | def call(realm, entity, item): class Sell (line 564) | class Sell(Node): method edges (line 569) | def edges(): method enabled (line 572) | def enabled(config): method call (line 575) | def call(realm, entity, item, price): function init_discrete (line 604) | def init_discrete(values): class Price (line 613) | class Price(Node): method init (line 617) | def init(cls, config): method index (line 623) | def index(cls, price): method edges (line 631) | def edges(): method deserialize (line 634) | def deserialize(realm, entity, index: int, obs): class Token (line 637) | class Token(Node): method init (line 641) | def init(cls, config): method edges (line 645) | def edges(): method deserialize (line 648) | def deserialize(realm, entity, index: int, obs): class Comm (line 651) | class Comm(Node): method edges (line 656) | def edges(): method enabled (line 659) | def enabled(config): method call (line 662) | def call(realm, entity, token): class BecomeSkynet (line 669) | class BecomeSkynet: FILE: nmmo/core/agent.py class Agent (line 1) | class Agent: method __init__ (line 4) | def __init__(self, config, idx): method __call__ (line 15) | def __call__(self, obs): method set_rng (line 22) | def set_rng(self, np_random): class Scripted (line 30) | class Scripted(Agent): FILE: nmmo/core/config.py class Template (line 27) | class Template(metaclass=utils.StaticIterable): method __init__ (line 28) | def __init__(self): method override (line 38) | def override(self, **kwargs): method set (line 44) | def set(self, k, v): method print (line 54) | def print(self): method items (line 63) | def items(self): method __iter__ (line 66) | def __iter__(self): method keys (line 70) | def keys(self): method values (line 73) | def values(self): function validate (line 76) | def validate(config): class Config (line 97) | class Config(Template): method __init__ (line 101) | def __init__(self): method original (line 121) | def original(self): method reset (line 124) | def reset(self): method set (line 129) | def set(self, k, v): method set_for_episode (line 133) | def set_for_episode(self, k, v): method enabled_systems (line 147) | def enabled_systems(self): method system_states (line 153) | def system_states(self): method are_systems_enabled (line 158) | def are_systems_enabled(self, systems): # systems is a list of strings method toggle_systems (line 162) | def toggle_systems(self, target_systems): # systems is a list of strings method PLAYER_POLICIES (line 179) | def PLAYER_POLICIES(self): method POSSIBLE_AGENTS (line 187) | def POSSIBLE_AGENTS(self): method PLAYER_VISION_DIAMETER (line 245) | def PLAYER_VISION_DIAMETER(self): method MAP_N_OBS (line 280) | def MAP_N_OBS(self): method MAP_BORDER (line 291) | def MAP_BORDER(self): class Terrain (line 337) | class Terrain: class Resource (line 384) | class Resource: function original_combat_damage_formula (line 427) | def original_combat_damage_formula(self, offense, defense, multiplier, m... function alt_combat_damage_formula (line 431) | def alt_combat_damage_formula(self, offense, defense, multiplier, minimu... class Combat (line 435) | class Combat: function default_exp_threshold (line 480) | def default_exp_threshold(base_exp, max_level): class Progression (line 486) | class Progression: class NPC (line 535) | class NPC: class Item (line 584) | class Item: method INVENTORY_N_OBS (line 600) | def INVENTORY_N_OBS(self): class Equipment (line 605) | class Equipment: class Profession (line 639) | class Profession: method PROFESSION_CONSUMABLE_RESTORE (line 675) | def PROFESSION_CONSUMABLE_RESTORE(self, level): class Exchange (line 680) | class Exchange: class Communication (line 701) | class Communication: class AllGameSystems (line 714) | class AllGameSystems( class Small (line 722) | class Small(Config): class Medium (line 745) | class Medium(Config): class Large (line 766) | class Large(Config): class Default (line 787) | class Default(Medium, AllGameSystems): FILE: nmmo/core/env.py class Env (line 23) | class Env(ParallelEnv): method __init__ (line 27) | def __init__(self, method _obs_space (line 85) | def _obs_space(self): method observation_space (line 129) | def observation_space(self, agent: AgentID): method _atn_space (line 142) | def _atn_space(self): method _str_atn_map (line 154) | def _str_atn_map(self): method action_space (line 165) | def action_space(self, agent: AgentID): method reset (line 179) | def reset(self, seed=None, options=None, # PettingZoo API args method _load_map_file (line 280) | def _load_map_file(self, map_id: int=None): method _map_task_to_agent (line 293) | def _map_task_to_agent(self): method step (line 313) | def step(self, actions: Dict[int, Dict[str, Dict[str, Any]]]): method dead_this_tick (line 375) | def dead_this_tick(self): method _validate_actions (line 378) | def _validate_actions(self, actions: Dict[int, Dict[str, Dict[str, Any... method _compute_scripted_agent_actions (line 423) | def _compute_scripted_agent_actions(self, actions: Dict[int, Dict[str,... method _compute_observations (line 438) | def _compute_observations(self): method _update_comm_obs (line 461) | def _update_comm_obs(self): method _compute_rewards (line 479) | def _compute_rewards(self): method render (line 520) | def render(self, mode='human'): method agents (line 524) | def agents(self) -> List[AgentID]: method close (line 528) | def close(self): method seed (line 531) | def seed(self, seed=None): method state (line 543) | def state(self) -> np.ndarray: FILE: nmmo/core/game_api.py class Game (line 14) | class Game(ABC): method __init__ (line 17) | def __init__(self, env, sampling_weight=None): method is_compatible (line 32) | def is_compatible(self): method name (line 37) | def name(self): method winners (line 41) | def winners(self): method winning_score (line 45) | def winning_score(self): method reset (line 51) | def reset(self, np_random, map_dict, tasks=None): method _set_config (line 68) | def _set_config(self): # pylint: disable=unused-argument method _set_realm (line 72) | def _set_realm(self, map_dict): method _post_setup (line 76) | def _post_setup(self): method _reset_stats (line 79) | def _reset_stats(self): method _define_tasks (line 88) | def _define_tasks(self): method set_next_tasks (line 94) | def set_next_tasks(self, tasks): method update (line 98) | def update(self, terminated, dead_players, dead_npcs): method _process_dead_players (line 110) | def _process_dead_players(self, terminated, dead_players): method _process_dead_npcs (line 118) | def _process_dead_npcs(self, dead_npcs): method _check_winners (line 126) | def _check_winners(self, terminated): method is_over (line 139) | def is_over(self): method get_episode_stats (line 143) | def get_episode_stats(self): method _who_completed_task (line 158) | def _who_completed_task(self): class DefaultGame (line 167) | class DefaultGame(Game): method is_compatible (line 171) | def is_compatible(self): method _define_tasks (line 174) | def _define_tasks(self): class AgentTraining (line 177) | class AgentTraining(Game): method winning_score (line 182) | def winning_score(self): method is_compatible (line 185) | def is_compatible(self): method _define_tasks (line 194) | def _define_tasks(self): class TeamGameTemplate (line 206) | class TeamGameTemplate(Game): method is_compatible (line 210) | def is_compatible(self): method _set_realm (line 223) | def _set_realm(self, map_dict): method _post_setup (line 230) | def _post_setup(self): method teams (line 234) | def teams(self): method _attach_team_tag (line 237) | def _attach_team_tag(self): method _get_cand_team_tasks (line 247) | def _get_cand_team_tasks(self, num_tasks, tags=None): class TeamTraining (line 261) | class TeamTraining(TeamGameTemplate): method _define_tasks (line 265) | def _define_tasks(self): function team_survival_task (line 269) | def team_survival_task(num_tick, embedding=None): class TeamBattle (line 276) | class TeamBattle(TeamGameTemplate): method __init__ (line 280) | def __init__(self, env, sampling_weight=None): method is_compatible (line 285) | def is_compatible(self): method _define_tasks (line 293) | def _define_tasks(self): method _check_winners (line 300) | def _check_winners(self, terminated): method _check_remaining_teams (line 311) | def _check_remaining_teams(self): class ProtectTheKing (line 319) | class ProtectTheKing(TeamBattle): method __init__ (line 320) | def __init__(self, env, sampling_weight=None): method _define_tasks (line 326) | def _define_tasks(self): method update (line 338) | def update(self, terminated, dead_players, dead_npcs): FILE: nmmo/core/map.py class Map (line 15) | class Map: method __init__ (line 20) | def __init__(self, config, realm, np_random): method packet (line 45) | def packet(self): method repr (line 53) | def repr(self): method reset (line 59) | def reset(self, map_dict, np_random, seize_targets=None): method _process_map (line 105) | def _process_map(self, map_dict, np_random): method _mark_tile (line 129) | def _mark_tile(map_np_array, row, col, dist=2): method step (line 133) | def step(self): method harvest (line 143) | def harvest(self, r, c, deplete=True): method is_valid_pos (line 149) | def is_valid_pos(self, row, col): method make_spawnable (line 153) | def make_spawnable(self, row, col, radius=2): method seize_status (line 169) | def seize_status(self): FILE: nmmo/core/observation.py class BasicObs (line 19) | class BasicObs: method __init__ (line 20) | def __init__(self, id_col, obs_dim): method reset (line 26) | def reset(self): method update (line 30) | def update(self, values): method len (line 35) | def len(self): method id (line 38) | def id(self, i): method index (line 41) | def index(self, val): class InventoryObs (line 44) | class InventoryObs(BasicObs): method __init__ (line 45) | def __init__(self, id_col, obs_dim): method update (line 50) | def update(self, values): method sig (line 55) | def sig(self, item: item_system.Item, level: int): class GymObs (line 59) | class GymObs: method __init__ (line 62) | def __init__(self, config, agent_id): method reset (line 67) | def reset(self, task_embedding=None): method clear (line 71) | def clear(self, tick=None): method _make_empty_obs (line 83) | def _make_empty_obs(self): method set_arr_values (line 105) | def set_arr_values(self, key, values): method export (line 109) | def export(self): class ActionTargets (line 112) | class ActionTargets: method __init__ (line 116) | def __init__(self, config): method _get_keys_to_clear (line 126) | def _get_keys_to_clear(self): method reset (line 138) | def reset(self): method clear (line 144) | def clear(self, reset=False): method _make_empty_targets (line 154) | def _make_empty_targets(self): class Observation (line 182) | class Observation: method __init__ (line 183) | def __init__(self, config, agent_id: int) -> None: method reset (line 214) | def reset(self, habitable_tiles, task_embedding=None): method return_dummy_obs (line 233) | def return_dummy_obs(self): method set_agent_dead (line 236) | def set_agent_dead(self): method update (line 239) | def update(self, tick, visible_tiles, visible_entities, method tile (line 271) | def tile(self, r_delta, c_delta): method entity (line 288) | def entity(self, entity_id): method clear_cache (line 294) | def clear_cache(self): method to_gym (line 299) | def to_gym(self): method _make_action_targets (line 320) | def _make_action_targets(self): method _make_move_mask (line 338) | def _make_move_mask(self, move_mask, use_cython=None): method _make_attack_mask (line 347) | def _make_attack_mask(self, attack_mask, use_cython=None): method _make_use_mask (line 389) | def _make_use_mask(self, use_mask): method _item_skill (line 408) | def _item_skill(self): method _make_destroy_item_mask (line 434) | def _make_destroy_item_mask(self, destroy_mask): method _make_give_mask (line 443) | def _make_give_mask(self, give_mask): method _make_sell_mask (line 463) | def _make_sell_mask(self, sell_mask): method _make_give_gold_mask (line 473) | def _make_give_gold_mask(self, give_mask): method _make_buy_mask (line 491) | def _make_buy_mask(self, buy_mask): method _existing_ammo_listings (line 510) | def _existing_ammo_listings(self): FILE: nmmo/core/realm.py function prioritized (line 19) | def prioritized(entities: Dict, merged: Dict): class Realm (line 27) | class Realm: method __init__ (line 30) | def __init__(self, config, np_random): method reset (line 68) | def reset(self, np_random, map_dict, method packet (line 104) | def packet(self): method num_players (line 117) | def num_players(self): method seize_status (line 122) | def seize_status(self): method entity (line 125) | def entity(self, ent_id): method entity_or_none (line 130) | def entity_or_none(self, ent_id): method step (line 140) | def step(self, actions): method update_fog_map (line 197) | def update_fog_map(self, reset=False): method record_replay (line 224) | def record_replay(self, replay_helper: ReplayHelper) -> ReplayHelper: FILE: nmmo/core/terrain.py function sharp (line 11) | def sharp(noise): class Save (line 15) | class Save: method render (line 18) | def render(mats, lookup, path): method fractal (line 25) | def fractal(terrain, path): method as_numpy (line 31) | def as_numpy(mats, path): class Terrain (line 38) | class Terrain: method generate_terrain (line 41) | def generate_terrain(config, map_id, interpolaters): function fractal_to_material (line 123) | def fractal_to_material(config, fractal, all_grass=False): function process_map_border (line 144) | def process_map_border(config, matl_map, l1=None): function place_fish (line 158) | def place_fish(tiles, mmin, mmax, np_random, num_fish): function uniform (line 184) | def uniform(config, tiles, mat, mmin, mmax, np_random): function cluster (line 193) | def cluster(config, tiles, mat, mmin, mmax, np_random): function spawn_profession_resources (line 215) | def spawn_profession_resources(config, tiles, np_random=None): function try_add_tile (line 232) | def try_add_tile(map_tiles, row, col, tile_to_add): function scatter_extra_resources (line 238) | def scatter_extra_resources(config, tiles, np_random=None, class MapGenerator (line 258) | class MapGenerator: method __init__ (line 260) | def __init__(self, config): method load_textures (line 265) | def load_textures(self): method generate_all_maps (line 277) | def generate_all_maps(self, seed=None): method generate_map (line 315) | def generate_map(self, idx, np_random=None): FILE: nmmo/core/tile.py class Tile (line 30) | class Tile(TileState): method __init__ (line 31) | def __init__(self, realm, r, c, np_random): method occupied (line 47) | def occupied(self): method repr (line 55) | def repr(self): method pos (line 59) | def pos(self): method habitable (line 63) | def habitable(self): method impassible (line 67) | def impassible(self): method void (line 71) | def void(self): method tex (line 75) | def tex(self): method reset (line 78) | def reset(self, mat, config, np_random): method set_depleted (line 85) | def set_depleted(self): method _respawn (line 90) | def _respawn(self): method add_entity (line 95) | def add_entity(self, ent): method remove_entity (line 99) | def remove_entity(self, ent_id): method step (line 103) | def step(self): method harvest (line 109) | def harvest(self, deplete): method update_seize (line 116) | def update_seize(self): FILE: nmmo/datastore/datastore.py class DataTable (line 25) | class DataTable: method __init__ (line 26) | def __init__(self, num_columns: int): method reset (line 30) | def reset(self): method update (line 33) | def update(self, row_id: int, col: int, value): method get (line 36) | def get(self, ids: List[id]): method where_in (line 39) | def where_in(self, col: int, values: List): method where_eq (line 42) | def where_eq(self, col: str, value): method where_neq (line 45) | def where_neq(self, col: str, value): method window (line 48) | def window(self, row_idx: int, col_idx: int, row: int, col: int, radiu... method remove_row (line 51) | def remove_row(self, row_id: int): method add_row (line 54) | def add_row(self) -> int: method is_empty (line 57) | def is_empty(self) -> bool: class DatastoreRecord (line 60) | class DatastoreRecord: method __init__ (line 61) | def __init__(self, datastore, table: DataTable, row_id: int) -> None: method update (line 66) | def update(self, col: int, value): method get (line 69) | def get(self, col: int): method delete (line 72) | def delete(self): class Datastore (line 75) | class Datastore: method __init__ (line 76) | def __init__(self) -> None: method register_object_type (line 79) | def register_object_type(self, object_type: str, num_colums: int): method create_record (line 83) | def create_record(self, object_type: str) -> DatastoreRecord: method table (line 88) | def table(self, object_type: str) -> DataTable: method _create_table (line 91) | def _create_table(self, num_columns: int) -> DataTable: FILE: nmmo/datastore/id_allocator.py class IdAllocator (line 3) | class IdAllocator: method __init__ (line 4) | def __init__(self, max_id): method full (line 10) | def full(self): method remove (line 13) | def remove(self, row_id): method allocate (line 16) | def allocate(self): method expand (line 19) | def expand(self, max_id): FILE: nmmo/datastore/numpy_datastore.py class NumpyTable (line 8) | class NumpyTable(DataTable): method __init__ (line 9) | def __init__(self, num_columns: int, initial_size: int, dtype=np.int16): method reset (line 17) | def reset(self): method update (line 23) | def update(self, row_id: int, col: int, value): method get (line 26) | def get(self, ids: List[int]): method where_eq (line 29) | def where_eq(self, col: int, value): method where_neq (line 32) | def where_neq(self, col: int, value): method where_gt (line 35) | def where_gt(self, col: int, value): method where_in (line 38) | def where_in(self, col: int, values: List): method window (line 41) | def window(self, row_idx: int, col_idx: int, row: int, col: int, radiu... method add_row (line 47) | def add_row(self) -> int: method remove_row (line 53) | def remove_row(self, row_id: int) -> int: method _expand (line 57) | def _expand(self, max_rows: int): method is_empty (line 65) | def is_empty(self) -> bool: class NumpyDatastore (line 71) | class NumpyDatastore(Datastore): method _create_table (line 72) | def _create_table(self, num_columns: int) -> DataTable: FILE: nmmo/datastore/serialized.py class SerializedAttribute (line 30) | class SerializedAttribute(): method __init__ (line 31) | def __init__(self, method val (line 43) | def val(self): method update (line 46) | def update(self, value): method min (line 55) | def min(self): method max (line 59) | def max(self): method increment (line 62) | def increment(self, val=1, max_v=math.inf): method decrement (line 66) | def decrement(self, val=1, min_v=-math.inf): method empty (line 71) | def empty(self): method __eq__ (line 74) | def __eq__(self, other): method __ne__ (line 77) | def __ne__(self, other): method __lt__ (line 80) | def __lt__(self, other): method __le__ (line 83) | def __le__(self, other): method __gt__ (line 86) | def __gt__(self, other): method __ge__ (line 89) | def __ge__(self, other): class SerializedState (line 92) | class SerializedState(): method subclass (line 94) | def subclass(name: str, attributes: List[str]): FILE: nmmo/entity/entity.py class Resources (line 124) | class Resources: method __init__ (line 125) | def __init__(self, ent, config): method update (line 138) | def update(self, immortal=False): method packet (line 168) | def packet(self): class Status (line 178) | class Status: method __init__ (line 179) | def __init__(self, ent): method update (line 182) | def update(self): method packet (line 186) | def packet(self): method frozen (line 192) | def frozen(self): class History (line 197) | class History: method __init__ (line 198) | def __init__(self, ent): method update (line 214) | def update(self, entity, actions): method packet (line 224) | def packet(self): class Entity (line 255) | class Entity(EntityState): method __init__ (line 256) | def __init__(self, realm, pos, entity_id, name): method packet (line 293) | def packet(self): method update (line 307) | def update(self, realm, actions): method receive_damage (line 322) | def receive_damage(self, source, dmg): method apply_damage (line 351) | def apply_damage(self, dmg, style): method pos (line 355) | def pos(self): method set_pos (line 360) | def set_pos(self, row, col): method alive (line 366) | def alive(self): method immortal (line 370) | def immortal(self): method is_player (line 374) | def is_player(self) -> bool: method is_npc (line 378) | def is_npc(self) -> bool: method is_recon (line 382) | def is_recon(self): method attack_level (line 386) | def attack_level(self) -> int: method in_combat (line 393) | def in_combat(self) -> bool: FILE: nmmo/entity/entity_manager.py class EntityGroup (line 9) | class EntityGroup(Mapping): method __init__ (line 10) | def __init__(self, realm, np_random): method __len__ (line 21) | def __len__(self): method __contains__ (line 24) | def __contains__(self, e): method __getitem__ (line 27) | def __getitem__(self, key) -> Entity: method __iter__ (line 30) | def __iter__(self) -> Entity: method items (line 33) | def items(self): method corporeal (line 37) | def corporeal(self): method packet (line 41) | def packet(self): method reset (line 44) | def reset(self, np_random, delete_dead_entity=True): method spawn_entity (line 57) | def spawn_entity(self, entity): method cull_entity (line 62) | def cull_entity(self, entity): method cull (line 74) | def cull(self): method update (line 83) | def update(self, actions): class PlayerManager (line 96) | class PlayerManager(EntityGroup): method spawn (line 97) | def spawn(self, agent_loader: spawn.SequentialLoader = None): FILE: nmmo/entity/npc.py function get_habitable_dir (line 20) | def get_habitable_dir(ent): function meander_toward (line 30) | def meander_toward(ent, goal, dist_crit=10, toward_weight=3): function move_action (line 60) | def move_action(direction): class Equipment (line 64) | class Equipment: method __init__ (line 65) | def __init__(self, total, method total (line 79) | def total(self, getter): method packet (line 85) | def packet(self): class NPC (line 98) | class NPC(entity.Entity): method __init__ (line 99) | def __init__(self, realm, pos, iden, name, npc_type): method is_npc (line 110) | def is_npc(self) -> bool: method update (line 113) | def update(self, realm, actions): method can_see (line 122) | def can_see(self, target): method _move_toward (line 128) | def _move_toward(self, goal): method _meander (line 132) | def _meander(self): method can_attack (line 135) | def can_attack(self, target): method _has_target (line 143) | def _has_target(self, search=False): method _add_attack_action (line 153) | def _add_attack_action(self, actions, target): method _charge_toward (line 156) | def _charge_toward(self, target): method receive_damage (line 163) | def receive_damage(self, source, dmg): method default_spawn (line 188) | def default_spawn(realm, pos, iden, np_random, danger=None): method packet (line 262) | def packet(self): class Passive (line 269) | class Passive(NPC): method __init__ (line 270) | def __init__(self, realm, pos, iden, name=None): method decide (line 273) | def decide(self): class PassiveAggressive (line 277) | class PassiveAggressive(NPC): method __init__ (line 278) | def __init__(self, realm, pos, iden, name=None): method decide (line 281) | def decide(self): class Aggressive (line 286) | class Aggressive(NPC): method __init__ (line 287) | def __init__(self, realm, pos, iden, name=None): method decide (line 290) | def decide(self): class Soldier (line 295) | class Soldier(NPC): method __init__ (line 296) | def __init__(self, realm, pos, iden, name, order): method _process_order (line 302) | def _process_order(self, order): method _is_order_done (line 311) | def _is_order_done(self, radius=5): method decide (line 317) | def decide(self): method _decide_move_action (line 328) | def _decide_move_action(self): method _decide_attack_action (line 339) | def _decide_attack_action(self, actions): FILE: nmmo/entity/npc_manager.py class NPCManager (line 9) | class NPCManager(EntityGroup): method __init__ (line 10) | def __init__(self, realm, np_random): method reset (line 15) | def reset(self, np_random): method actions (line 20) | def actions(self): method default_spawn (line 23) | def default_spawn(self): method spawn_npc (line 46) | def spawn_npc(self, r, c, danger=None, name=None, order=None, method area_spawn (line 72) | def area_spawn(self, r_min, r_max, c_min, c_max, num_spawn, method edge_spawn (line 82) | def edge_spawn(self, num_spawn, npc_init_fn: Callable): FILE: nmmo/entity/player.py class Player (line 7) | class Player(entity.Entity): method __init__ (line 8) | def __init__(self, realm, pos, agent, resilient=False): method serial (line 41) | def serial(self): method is_player (line 45) | def is_player(self) -> bool: method level (line 49) | def level(self) -> int: method _set_immortal (line 55) | def _set_immortal(self, value=True, duration=None): method make_recon (line 65) | def make_recon(self, new_pos=None): method apply_damage (line 76) | def apply_damage(self, dmg, style): method receive_damage (line 81) | def receive_damage(self, source, dmg): method equipment (line 120) | def equipment(self): method packet (line 123) | def packet(self): method update (line 137) | def update(self, realm, actions): method resurrect (line 165) | def resurrect(self, health_prop=0.5, freeze_duration=10, edge_spawn=Tr... FILE: nmmo/lib/astar.py function l1 (line 7) | def l1(start, goal): function adjacentPos (line 12) | def adjacentPos(pos): function aStar (line 16) | def aStar(realm_map, start, goal, cutoff = CUTOFF): FILE: nmmo/lib/colors.py function rgb (line 10) | def rgb(h): function rgbNorm (line 14) | def rgbNorm(h): function makeColor (line 18) | def makeColor(idx, h=1, s=1, v=1): class Color (line 24) | class Color: method __init__ (line 25) | def __init__(self, name, hexVal): method packet (line 32) | def packet(self): class Color256 (line 35) | class Color256: method make256 (line 36) | def make256(): class Color16 (line 45) | class Color16: method make (line 46) | def make(): class Tier (line 54) | class Tier: class Swatch (line 63) | class Swatch: method colors (line 64) | def colors(): method rand (line 68) | def rand(): class Neon (line 75) | class Neon(Swatch): method colors (line 104) | def colors(): class Solid (line 111) | class Solid(Swatch): method colors (line 126) | def colors(): class Palette (line 133) | class Palette: method __init__ (line 134) | def __init__(self, initial_swatch=Neon): method color (line 139) | def color(self, idx): FILE: nmmo/lib/event_code.py class EventCode (line 1) | class EventCode: FILE: nmmo/lib/event_log.py class EventLogger (line 53) | class EventLogger(EventCode): method __init__ (line 54) | def __init__(self, realm): method reset (line 73) | def reset(self): method _create_event (line 77) | def _create_event(self, entity: Entity, event_code: int): method record (line 87) | def record(self, event_code: int, entity: Entity, **kwargs): method update (line 188) | def update(self): method get_data (line 194) | def get_data(self, event_code=None, agents: List[int]=None, tick: int=... method get_stat (line 215) | def get_stat(self): function extract_event_key (line 238) | def extract_event_key(event_row): FILE: nmmo/lib/material.py class Material (line 4) | class Material: method __init__ (line 11) | def __init__(self, config): method __eq__ (line 14) | def __eq__(self, mtl): method __equals__ (line 17) | def __equals__(self, mtl): method harvest (line 20) | def harvest(self): class Void (line 23) | class Void(Material): class Water (line 27) | class Water(Material): method __init__ (line 33) | def __init__(self, config): class Grass (line 37) | class Grass(Material): class Scrub (line 41) | class Scrub(Material): class Foilage (line 45) | class Foilage(Material): method __init__ (line 52) | def __init__(self, config): class Stone (line 57) | class Stone(Material): class Slag (line 61) | class Slag(Material): class Ore (line 65) | class Ore(Material): method __init__ (line 72) | def __init__(self, config): class Stump (line 88) | class Stump(Material): class Tree (line 92) | class Tree(Material): method __init__ (line 99) | def __init__(self, config): class Fragment (line 111) | class Fragment(Material): class Crystal (line 115) | class Crystal(Material): method __init__ (line 122) | def __init__(self, config): class Weeds (line 134) | class Weeds(Material): class Herb (line 138) | class Herb(Material): method __init__ (line 148) | def __init__(self, config): class Ocean (line 153) | class Ocean(Material): class Fish (line 157) | class Fish(Material): method __init__ (line 167) | def __init__(self, config): class Meta (line 174) | class Meta(type): method __init__ (line 175) | def __init__(self, name, bases, dict): method __iter__ (line 178) | def __iter__(self): method __contains__ (line 181) | def __contains__(self, mtl): class All (line 188) | class All(metaclass=Meta): class Impassible (line 195) | class Impassible(metaclass=Meta): class Habitable (line 199) | class Habitable(metaclass=Meta): class Harvestable (line 203) | class Harvestable(metaclass=Meta): FILE: nmmo/lib/seeding.py class RandomNumberGenerator (line 7) | class RandomNumberGenerator(np.random.Generator): method __init__ (line 8) | def __init__(self, bit_generator): method get_direction (line 16) | def get_direction(self): function np_random (line 20) | def np_random(seed: Optional[int] = None) -> Tuple[np.random.Generator, ... FILE: nmmo/lib/spawn.py class SequentialLoader (line 3) | class SequentialLoader: method __init__ (line 5) | def __init__(self, config, np_random, method __iter__ (line 18) | def __iter__(self): method __next__ (line 21) | def __next__(self): method get_spawn_position (line 26) | def get_spawn_position(self, agent_id): function get_random_coord (line 30) | def get_random_coord(config, np_random, edge=True): function get_edge_tiles (line 56) | def get_edge_tiles(config, np_random=None, shuffle=False): FILE: nmmo/lib/team_helper.py function make_teams (line 6) | def make_teams(config, num_teams): class TeamHelper (line 14) | class TeamHelper: method __init__ (line 15) | def __init__(self, teams: Dict[Any, List[int]], np_random=None): method agent_position (line 34) | def agent_position(self, agent_id: int) -> int: method agent_id (line 37) | def agent_id(self, team_id: Any, position: int) -> int: method is_agent_in_team (line 40) | def is_agent_in_team(self, agent_id:int , team_id: Any) -> bool: method get_team_idx (line 43) | def get_team_idx(self, agent_id:int) -> int: method get_target_agent (line 47) | def get_target_agent(self, team_id: Any, target: str): class RefillPopper (line 77) | class RefillPopper: method __init__ (line 78) | def __init__(self, original_list, np_random=None): method pop (line 84) | def pop(self): class TeamLoader (line 92) | class TeamLoader(spawn.SequentialLoader): method __init__ (line 93) | def __init__(self, config, np_random, method get_spawn_position (line 115) | def get_spawn_position(self, agent_id): function spawn_team_together (line 119) | def spawn_team_together(config, num_teams): FILE: nmmo/lib/utils.py class staticproperty (line 10) | class staticproperty(property): method __get__ (line 11) | def __get__(self, cls, owner): class classproperty (line 14) | class classproperty(object): method __init__ (line 15) | def __init__(self, f): method __get__ (line 17) | def __get__(self, obj, owner): class Iterable (line 20) | class Iterable(type): method __iter__ (line 21) | def __iter__(cls): method values (line 31) | def values(cls): class StaticIterable (line 34) | class StaticIterable(type): method __iter__ (line 35) | def __iter__(cls): class NameComparable (line 45) | class NameComparable(type): method __hash__ (line 46) | def __hash__(self): method __eq__ (line 49) | def __eq__(self, other): method __ne__ (line 52) | def __ne__(self, other): method __lt__ (line 55) | def __lt__(self, other): method __le__ (line 58) | def __le__(self, other): method __gt__ (line 61) | def __gt__(self, other): method __ge__ (line 64) | def __ge__(self, other): class IterableNameComparable (line 67) | class IterableNameComparable(Iterable, NameComparable): function linf (line 70) | def linf(pos1, pos2): function linf_single (line 75) | def linf_single(pos1, pos2): function in_bounds (line 80) | def in_bounds(r, c, shape, border=0): function l1_map (line 89) | def l1_map(size): function get_hash_embedding (line 96) | def get_hash_embedding(func, embed_dim): function identify_closest_target (line 114) | def identify_closest_target(entity): FILE: nmmo/lib/vec_noise.py function snoise2 (line 39) | def snoise2(x, y): FILE: nmmo/minigames/center_race.py class RacetoCenter (line 9) | class RacetoCenter(Game): method __init__ (line 12) | def __init__(self, env, sampling_weight=None): method map_size (line 27) | def map_size(self): method set_map_size (line 30) | def set_map_size(self, map_size): method is_compatible (line 33) | def is_compatible(self): method reset (line 36) | def reset(self, np_random, map_dict, tasks=None): method _set_config (line 44) | def _set_config(self): method _determine_difficulty (line 64) | def _determine_difficulty(self): method _set_realm (line 73) | def _set_realm(self, map_dict): method _define_tasks (line 77) | def _define_tasks(self): method _process_dead_players (line 81) | def _process_dead_players(self, terminated, dead_players): method winning_score (line 88) | def winning_score(self): method _check_winners (line 95) | def _check_winners(self, terminated): method test (line 99) | def test(env, horizon=30, seed=0): FILE: nmmo/minigames/comm_together.py function seek_task (line 9) | def seek_task(within_dist): class CommTogether (line 15) | class CommTogether(TeamBattle): method __init__ (line 18) | def __init__(self, env, sampling_weight=None): method required_systems (line 37) | def required_systems(self): method map_size (line 41) | def map_size(self): method set_map_size (line 44) | def set_map_size(self, map_size): method set_spawn_immunity (line 47) | def set_spawn_immunity(self, spawn_immunity): method set_grass_map (line 50) | def set_grass_map(self, grass_map): method is_compatible (line 53) | def is_compatible(self): method reset (line 56) | def reset(self, np_random, map_dict, tasks=None): method _set_config (line 62) | def _set_config(self): method _determine_difficulty (line 80) | def _determine_difficulty(self): method _set_realm (line 93) | def _set_realm(self, map_dict): method _define_tasks (line 97) | def _define_tasks(self): method _process_dead_players (line 101) | def _process_dead_players(self, terminated, dead_players): method _check_winners (line 107) | def _check_winners(self, terminated): method winning_score (line 112) | def winning_score(self): method test (line 120) | def test(env, horizon=30, seed=0): FILE: nmmo/minigames/king_hill.py function seize_task (line 8) | def seize_task(dur_to_win): class KingoftheHill (line 14) | class KingoftheHill(TeamBattle): method __init__ (line 17) | def __init__(self, env, sampling_weight=None): method seize_duration (line 34) | def seize_duration(self): method set_seize_duration (line 37) | def set_seize_duration(self, seize_duration): method is_compatible (line 40) | def is_compatible(self): method reset (line 43) | def reset(self, np_random, map_dict, tasks=None): method _set_config (line 48) | def _set_config(self): method _determine_difficulty (line 67) | def _determine_difficulty(self): method _set_realm (line 77) | def _set_realm(self, map_dict): method _define_tasks (line 83) | def _define_tasks(self): method winning_score (line 88) | def winning_score(self): method _check_winners (line 98) | def _check_winners(self, terminated): method test (line 133) | def test(env, horizon=30, seed=0): FILE: nmmo/minigames/radio_raid.py function hunt_task (line 9) | def hunt_task(num_npc): class RadioRaid (line 15) | class RadioRaid(TeamBattle): method __init__ (line 19) | def __init__(self, env, sampling_weight=None): method teams (line 48) | def teams(self): method goal_num_npc (line 57) | def goal_num_npc(self): method set_goal_num_npc (line 60) | def set_goal_num_npc(self, goal_num_npc): method set_grass_map (line 63) | def set_grass_map(self, grass_map): method is_compatible (line 66) | def is_compatible(self): method reset (line 69) | def reset(self, np_random, map_dict, tasks=None): method _set_config (line 75) | def _set_config(self): method _determine_difficulty (line 99) | def _determine_difficulty(self): method _set_realm (line 107) | def _set_realm(self, map_dict): method _define_tasks (line 120) | def _define_tasks(self): method _process_dead_npcs (line 124) | def _process_dead_npcs(self, dead_npcs): method _check_winners (line 143) | def _check_winners(self, terminated): method is_over (line 148) | def is_over(self): method winning_score (line 153) | def winning_score(self): method test (line 163) | def test(env, horizon=30, seed=0): FILE: nmmo/minigames/sandwich.py function secure_order (line 9) | def secure_order(pos, radius=5): class Sandwich (line 12) | class Sandwich(TeamBattle): method __init__ (line 16) | def __init__(self, env, sampling_weight=None): method teams (line 30) | def teams(self): method inner_npc_num (line 39) | def inner_npc_num(self): method set_inner_npc_num (line 42) | def set_inner_npc_num(self, inner_npc_num): method outer_npc_num (line 46) | def outer_npc_num(self): method set_outer_npc_num (line 49) | def set_outer_npc_num(self, outer_npc_num): method set_grass_map (line 52) | def set_grass_map(self, grass_map): method is_compatible (line 55) | def is_compatible(self): method reset (line 58) | def reset(self, np_random, map_dict, tasks=None): method _set_config (line 64) | def _set_config(self): method _determine_difficulty (line 86) | def _determine_difficulty(self): method _generate_spawn_locs (line 97) | def _generate_spawn_locs(self): method _set_realm (line 103) | def _set_realm(self, map_dict): method _process_dead_npcs (line 132) | def _process_dead_npcs(self, dead_npcs): method winning_score (line 146) | def winning_score(self): method _check_winners (line 154) | def _check_winners(self, terminated): method test (line 161) | def test(env, horizon=30, seed=0): FILE: nmmo/render/overlay.py class OverlayRegistry (line 9) | class OverlayRegistry: method __init__ (line 10) | def __init__(self, realm, renderer): method init (line 27) | def init(self, *args): method step (line 33) | def step(self, cmd): class Overlay (line 49) | class Overlay: method __init__ (line 55) | def __init__(self, config, realm, renderer, *args): method update (line 68) | def update(self): method register (line 75) | def register(self): class Skills (line 79) | class Skills(Overlay): method __init__ (line 80) | def __init__(self, config, realm, renderer, *args): method update (line 87) | def update(self): method register (line 102) | def register(self): class Counts (line 128) | class Counts(Overlay): method __init__ (line 129) | def __init__(self, config, realm, renderer, *args): method update (line 133) | def update(self): method register (line 140) | def register(self): FILE: nmmo/render/render_client.py class DummyRenderer (line 10) | class DummyRenderer: method __init__ (line 11) | def __init__(self, realm=None) -> None: method set_realm (line 22) | def set_realm(self, realm) -> None: method render_packet (line 26) | def render_packet(self, packet) -> None: method render_realm (line 34) | def render_realm(self) -> None: method register (line 78) | def register(self, overlay: np.ndarray) -> None: FILE: nmmo/render/render_utils.py function np_encoder (line 8) | def np_encoder(obj): function normalize (line 12) | def normalize(ary: np.ndarray, norm_std=2): function clip (line 29) | def clip(ary: np.ndarray): function make_two_tone (line 42) | def make_two_tone(ary, norm_std=2, preprocess='norm', invert=False, peri... function patch_packet (line 68) | def patch_packet(packet, realm): FILE: nmmo/systems/combat.py function level (line 8) | def level(skills): function damage_multiplier (line 11) | def damage_multiplier(config, skill, targ): function attack (line 27) | def attack(realm, attacker, target, skill_fn): function danger (line 115) | def danger(config, pos): function spawn (line 128) | def spawn(config, dnger, np_random): FILE: nmmo/systems/droptable.py class Fixed (line 1) | class Fixed(): method __init__ (line 2) | def __init__(self, item): method roll (line 5) | def roll(self, realm, level): class Drop (line 8) | class Drop: method __init__ (line 9) | def __init__(self, item, prob): method roll (line 13) | def roll(self, realm, level): class Standard (line 22) | class Standard: method __init__ (line 23) | def __init__(self): method add (line 26) | def add(self, item, prob=1.0): method roll (line 29) | def roll(self, realm, level): class Empty (line 37) | class Empty(Standard): method roll (line 38) | def roll(self, realm, level): class Ammunition (line 41) | class Ammunition(Standard): method __init__ (line 42) | def __init__(self, item): method roll (line 46) | def roll(self, realm, level): class Consumable (line 49) | class Consumable(Standard): method __init__ (line 50) | def __init__(self, item): method roll (line 54) | def roll(self, realm, level): FILE: nmmo/systems/exchange.py class ItemListing (line 27) | class ItemListing: method __init__ (line 28) | def __init__(self, item: Item, seller, price: int, tick: int): class Exchange (line 34) | class Exchange: method __init__ (line 35) | def __init__(self, realm): method reset (line 41) | def reset(self): method _list_item (line 45) | def _list_item(self, item: Item, seller, price: int, tick: int): method unlist_item (line 50) | def unlist_item(self, item: Item): method _unlist_item (line 54) | def _unlist_item(self, item_id: int): method step (line 58) | def step(self): method sell (line 99) | def sell(self, seller, item: Item, price: int, tick: int): method buy (line 110) | def buy(self, buyer, item: Item): method packet (line 141) | def packet(self): FILE: nmmo/systems/inventory.py class EquipmentSlot (line 6) | class EquipmentSlot: method __init__ (line 7) | def __init__(self) -> None: method equip (line 10) | def equip(self, item: Item.Item) -> None: method unequip (line 13) | def unequip(self) -> None: class Equipment (line 18) | class Equipment: method __init__ (line 19) | def __init__(self): method total (line 26) | def total(self, lambda_getter): method __iter__ (line 32) | def __iter__(self): method conditional_packet (line 37) | def conditional_packet(self, packet, slot_name: str, slot: EquipmentSl... method item_level (line 42) | def item_level(self): method melee_attack (line 46) | def melee_attack(self): method range_attack (line 50) | def range_attack(self): method mage_attack (line 54) | def mage_attack(self): method melee_defense (line 58) | def melee_defense(self): method range_defense (line 62) | def range_defense(self): method mage_defense (line 66) | def mage_defense(self): method packet (line 70) | def packet(self): class Inventory (line 92) | class Inventory: method __init__ (line 93) | def __init__(self, realm, entity): method space (line 109) | def space(self): method has_stack (line 112) | def has_stack(self, signature: Tuple) -> bool: method packet (line 115) | def packet(self): method __iter__ (line 124) | def __iter__(self): method receive (line 128) | def receive(self, item: Item.Item) -> bool: method remove (line 163) | def remove(self, item, quantity=None): method _remove (line 188) | def _remove(self, item): FILE: nmmo/systems/item.py class Item (line 69) | class Item(ItemState): method register (line 74) | def register(item_type): method item_class (line 80) | def item_class(type_id: int): method __init__ (line 83) | def __init__(self, realm, level, method destroy (line 111) | def destroy(self): method packet (line 122) | def packet(self): method _level (line 137) | def _level(self, entity): method level_gt (line 142) | def level_gt(self, entity): method use (line 145) | def use(self, entity) -> bool: class Stack (line 148) | class Stack: method signature (line 150) | def signature(self): class Equipment (line 153) | class Equipment(Item): method packet (line 155) | def packet(self): method color (line 160) | def color(self): method unequip (line 175) | def unequip(self, equip_slot): method equip (line 180) | def equip(self, entity, equip_slot): method _slot (line 188) | def _slot(self, entity): method use (line 191) | def use(self, entity): class Armor (line 204) | class Armor(Equipment, ABC): method __init__ (line 205) | def __init__(self, realm, level, **kwargs): class Hat (line 213) | class Hat(Armor): method _slot (line 215) | def _slot(self, entity): class Top (line 217) | class Top(Armor): method _slot (line 219) | def _slot(self, entity): class Bottom (line 221) | class Bottom(Armor): method _slot (line 223) | def _slot(self, entity): class Weapon (line 227) | class Weapon(Equipment): method __init__ (line 228) | def __init__(self, realm, level, **kwargs): method _slot (line 234) | def _slot(self, entity): class Spear (line 237) | class Spear(Weapon): method __init__ (line 240) | def __init__(self, realm, level, **kwargs): method _level (line 244) | def _level(self, entity): class Bow (line 246) | class Bow(Weapon): method __init__ (line 249) | def __init__(self, realm, level, **kwargs): method _level (line 253) | def _level(self, entity): class Wand (line 255) | class Wand(Weapon): method __init__ (line 258) | def __init__(self, realm, level, **kwargs): method _level (line 262) | def _level(self, entity): class Tool (line 266) | class Tool(Equipment): method __init__ (line 267) | def __init__(self, realm, level, **kwargs): method _slot (line 276) | def _slot(self, entity): class Rod (line 278) | class Rod(Tool): method _level (line 280) | def _level(self, entity): class Gloves (line 282) | class Gloves(Tool): method _level (line 284) | def _level(self, entity): class Pickaxe (line 286) | class Pickaxe(Tool): method _level (line 288) | def _level(self, entity): class Axe (line 290) | class Axe(Tool): method _level (line 292) | def _level(self, entity): class Chisel (line 294) | class Chisel(Tool): method _level (line 296) | def _level(self, entity): class Ammunition (line 300) | class Ammunition(Equipment, Stack): method __init__ (line 301) | def __init__(self, realm, level, **kwargs): method _slot (line 307) | def _slot(self, entity): method fire (line 310) | def fire(self, entity) -> int: class Whetstone (line 324) | class Whetstone(Ammunition): method __init__ (line 327) | def __init__(self, realm, level, **kwargs): method _level (line 331) | def _level(self, entity): method damage (line 335) | def damage(self): class Arrow (line 338) | class Arrow(Ammunition): method __init__ (line 341) | def __init__(self, realm, level, **kwargs): method _level (line 345) | def _level(self, entity): method damage (line 349) | def damage(self): class Runes (line 352) | class Runes(Ammunition): method __init__ (line 355) | def __init__(self, realm, level, **kwargs): method _level (line 359) | def _level(self, entity): method damage (line 363) | def damage(self): class Consumable (line 369) | class Consumable(Item): method use (line 370) | def use(self, entity) -> bool: class Ration (line 381) | class Ration(Consumable): method __init__ (line 384) | def __init__(self, realm, level, **kwargs): method _apply_effects (line 390) | def _apply_effects(self, entity): class Potion (line 394) | class Potion(Consumable): method __init__ (line 397) | def __init__(self, realm, level, **kwargs): method _apply_effects (line 403) | def _apply_effects(self, entity): FILE: nmmo/systems/skill.py class ExperienceCalculator (line 13) | class ExperienceCalculator: method __init__ (line 14) | def __init__(self, config): method exp_at_level (line 23) | def exp_at_level(self, level): method level_at_exp (line 28) | def level_at_exp(self, exp): class SkillGroup (line 33) | class SkillGroup: method __init__ (line 34) | def __init__(self, realm, entity): method update (line 42) | def update(self): method packet (line 46) | def packet(self): class Skill (line 53) | class Skill(abc.ABC): method __init__ (line 54) | def __init__(self, skill_group: SkillGroup): method packet (line 63) | def packet(self): method add_xp (line 69) | def add_xp(self, xp): method set_experience_by_level (line 78) | def set_experience_by_level(self, level): method level (line 83) | def level(self): method exp (line 88) | def exp(self): class CombatSkill (line 93) | class CombatSkill(Skill): method update (line 94) | def update(self): class NonCombatSkill (line 97) | class NonCombatSkill(Skill): method __init__ (line 98) | def __init__(self, skill_group: SkillGroup): method level (line 103) | def level(self): method exp (line 107) | def exp(self): class HarvestSkill (line 110) | class HarvestSkill(NonCombatSkill): method process_drops (line 111) | def process_drops(self, matl, drop_table): method harvest (line 133) | def harvest(self, matl, deplete=True): method harvest_adjacent (line 147) | def harvest_adjacent(self, matl, deplete=True): class AmmunitionSkill (line 168) | class AmmunitionSkill(HarvestSkill): method process_drops (line 169) | def process_drops(self, matl, drop_table): class ConsumableSkill (line 175) | class ConsumableSkill(HarvestSkill): method process_drops (line 176) | def process_drops(self, matl, drop_table): class Basic (line 183) | class Basic(SkillGroup): method __init__ (line 184) | def __init__(self, realm, entity): method basic_level (line 191) | def basic_level(self): class Harvest (line 195) | class Harvest(SkillGroup): method __init__ (line 196) | def __init__(self, realm, entity): method harvest_level (line 206) | def harvest_level(self): class Combat (line 213) | class Combat(SkillGroup): method __init__ (line 214) | def __init__(self, realm, entity): method packet (line 221) | def packet(self): method combat_level (line 228) | def combat_level(self): method apply_damage (line 233) | def apply_damage(self, style): method receive_damage (line 238) | def receive_damage(self, dmg): class Skills (line 241) | class Skills(Basic, Harvest, Combat): class Melee (line 245) | class Melee(CombatSkill): method level (line 249) | def level(self): method exp (line 253) | def exp(self): class Range (line 256) | class Range(CombatSkill): method level (line 260) | def level(self): method exp (line 264) | def exp(self): class Mage (line 267) | class Mage(CombatSkill): method level (line 271) | def level(self): method exp (line 275) | def exp(self): class DummyValue (line 285) | class DummyValue: method __init__ (line 286) | def __init__(self, val=0): method update (line 289) | def update(self, val): class Water (line 292) | class Water(HarvestSkill): method update (line 293) | def update(self): class Food (line 314) | class Food(HarvestSkill): method update (line 315) | def update(self): class Fishing (line 336) | class Fishing(ConsumableSkill): method level (line 340) | def level(self): method exp (line 344) | def exp(self): method update (line 347) | def update(self): class Herbalism (line 350) | class Herbalism(ConsumableSkill): method level (line 354) | def level(self): method exp (line 358) | def exp(self): method update (line 361) | def update(self): class Prospecting (line 364) | class Prospecting(AmmunitionSkill): method level (line 368) | def level(self): method exp (line 372) | def exp(self): method update (line 375) | def update(self): class Carving (line 378) | class Carving(AmmunitionSkill): method level (line 382) | def level(self): method exp (line 386) | def exp(self): method update (line 389) | def update(self,): class Alchemy (line 392) | class Alchemy(AmmunitionSkill): method level (line 396) | def level(self): method exp (line 400) | def exp(self): method update (line 403) | def update(self): FILE: nmmo/task/base_predicates.py function norm (line 15) | def norm(progress): function Success (line 18) | def Success(gs: GameState, subject: Group): function TickGE (line 23) | def TickGE(gs: GameState, subject: Group, num_tick: int = None): function CanSeeTile (line 31) | def CanSeeTile(gs: GameState, subject: Group, tile_type: type[Material]): function StayAlive (line 36) | def StayAlive(gs: GameState, subject: Group): function AllDead (line 41) | def AllDead(gs: GameState, subject: Group): function CheckAgentStatus (line 46) | def CheckAgentStatus(gs: GameState, subject: Group, target: Iterable[int... function OccupyTile (line 59) | def OccupyTile(gs: GameState, subject: Group, row: int, col: int): function CanSeeAgent (line 64) | def CanSeeAgent(gs: GameState, subject: Group, target: int): function CanSeeGroup (line 69) | def CanSeeGroup(gs: GameState, subject: Group, target: Iterable[int]): function DistanceTraveled (line 76) | def DistanceTraveled(gs: GameState, subject: Group, dist: int): function AttainSkill (line 87) | def AttainSkill(gs: GameState, subject: Group, function GainExperience (line 97) | def GainExperience(gs: GameState, subject: Group, function CountEvent (line 103) | def CountEvent(gs: GameState, subject: Group, event: str, N: int): function ScoreHit (line 109) | def ScoreHit(gs: GameState, subject: Group, combat_style: type[Skill], N... function DefeatEntity (line 116) | def DefeatEntity(gs: GameState, subject: Group, agent_type: str, level: ... function HoardGold (line 129) | def HoardGold(gs: GameState, subject: Group, amount: int): function EarnGold (line 134) | def EarnGold(gs: GameState, subject: Group, amount: int): function SpendGold (line 140) | def SpendGold(gs: GameState, subject: Group, amount: int): function MakeProfit (line 145) | def MakeProfit(gs: GameState, subject: Group, amount: int): function InventorySpaceGE (line 152) | def InventorySpaceGE(gs: GameState, subject: Group, space: int): function OwnItem (line 159) | def OwnItem(gs: GameState, subject: Group, item: type[Item], level: int,... function EquipItem (line 167) | def EquipItem(gs: GameState, subject: Group, item: type[Item], level: in... function FullyArmed (line 178) | def FullyArmed(gs: GameState, subject: Group, function ConsumeItem (line 202) | def ConsumeItem(gs: GameState, subject: Group, item: type[Item], level: ... function HarvestItem (line 209) | def HarvestItem(gs: GameState, subject: Group, item: type[Item], level: ... function FireAmmo (line 216) | def FireAmmo(gs: GameState, subject: Group, item: type[Item], level: int... function ListItem (line 223) | def ListItem(gs: GameState, subject: Group, item: type[Item], level: int... function BuyItem (line 230) | def BuyItem(gs: GameState, subject: Group, item: type[Item], level: int,... function ProgressTowardCenter (line 241) | def ProgressTowardCenter(gs, subject): function AllMembersWithinRange (line 258) | def AllMembersWithinRange(gs: GameState, subject: Group, dist: int): function SeizeTile (line 279) | def SeizeTile(gs: GameState, subject: Group, row: int, col: int, num_tic... function SeizeCenter (line 306) | def SeizeCenter(gs: GameState, subject: Group, num_ticks: int, function SeizeQuadCenter (line 311) | def SeizeQuadCenter(gs: GameState, subject: Group, num_ticks: int, quadr... function ProtectLeader (line 327) | def ProtectLeader(gs, subject, target_protect: int, target_destroy: Iter... FILE: nmmo/task/game_state.py class GameState (line 32) | class GameState: method entity_or_none (line 55) | def entity_or_none(self, ent_id): method where_in_id (line 60) | def where_in_id(self, data_type, subject: Iterable[int]): method get_subject_view (line 79) | def get_subject_view(self, subject: Group): method clear_cache (line 84) | def clear_cache(self): class CachedProperty (line 93) | class CachedProperty: method __init__ (line 94) | def __init__(self, func): method __get__ (line 100) | def __get__(self, instance, owner): class ArrayView (line 107) | class ArrayView(ABC): method __init__ (line 108) | def __init__(self, method __len__ (line 122) | def __len__(self): method get_attribute (line 126) | def get_attribute(self, attr) -> np.ndarray: method __getattr__ (line 129) | def __getattr__(self, attr) -> np.ndarray: class ItemView (line 137) | class ItemView(ArrayView): method __init__ (line 138) | def __init__(self, gs: GameState, subject: Group, arr: np.ndarray): method get_attribute (line 142) | def get_attribute(self, attr) -> np.ndarray: class EntityView (line 145) | class EntityView(ArrayView): method __init__ (line 146) | def __init__(self, gs: GameState, subject: Group, arr: np.ndarray): method get_attribute (line 149) | def get_attribute(self, attr) -> np.ndarray: class EventView (line 152) | class EventView(ArrayView): method __init__ (line 153) | def __init__(self, gs: GameState, subject: Group, arr: np.ndarray): method get_attribute (line 156) | def get_attribute(self, attr) -> np.ndarray: class TileView (line 162) | class TileView(ArrayView): method __init__ (line 163) | def __init__(self, gs: GameState, subject: Group, arr: np.ndarray): method get_attribute (line 166) | def get_attribute(self, attr) -> np.ndarray: class EventCodeView (line 169) | class EventCodeView(ArrayView): method __init__ (line 170) | def __init__(self, method get_attribute (line 177) | def get_attribute(self, attr) -> np.ndarray: class GroupObsView (line 181) | class GroupObsView: method __init__ (line 182) | def __init__(self, gs: GameState, subject: Group): method tile (line 190) | def tile(self): method __getattr__ (line 193) | def __getattr__(self, attr): class GroupView (line 196) | class GroupView: method __init__ (line 197) | def __init__(self, gs: GameState, subject: Group): method obs (line 203) | def obs(self): method _sbj_ent (line 207) | def _sbj_ent(self): method entity (line 211) | def entity(self): method _sbj_item (line 215) | def _sbj_item(self): method item (line 219) | def item(self): method _sbj_event (line 223) | def _sbj_event(self): method event (line 227) | def event(self): method __getattribute__ (line 230) | def __getattribute__(self, attr): class GameStateGenerator (line 253) | class GameStateGenerator: method __init__ (line 254) | def __init__(self, realm: Realm, config: Config): method generate (line 261) | def generate(self, realm: Realm, env_obs: Dict[int, Observation]) -> G... function precompute_index (line 284) | def precompute_index(table, id_col): FILE: nmmo/task/group.py class Group (line 10) | class Group(Sequence, Set): method __init__ (line 13) | def __init__(self, method agents (line 32) | def agents(self): method union (line 35) | def union(self, o: Group): method intersection (line 38) | def intersection(self, o: Group): method __eq__ (line 41) | def __eq__(self, o): method __len__ (line 44) | def __len__(self): method __hash__ (line 47) | def __hash__(self): method __getitem__ (line 50) | def __getitem__(self, key): method __contains__ (line 55) | def __contains__(self, key): method __str__ (line 60) | def __str__(self) -> str: method __int__ (line 63) | def __int__(self) -> int: method __copy__ (line 67) | def __copy__(self): method __deepcopy__ (line 69) | def __deepcopy__(self, memo): method description (line 72) | def description(self) -> Dict: method clear_prev_state (line 79) | def clear_prev_state(self) -> None: method update (line 87) | def update(self, gs: GameState) -> None: method __getattr__ (line 92) | def __getattr__(self, attr): function union (line 95) | def union(*groups: Group) -> Group: function complement (line 104) | def complement(group: Group, universe: Group) -> Group: FILE: nmmo/task/predicate_api.py class InvalidPredicateDefinition (line 15) | class InvalidPredicateDefinition(Exception): class Predicate (line 18) | class Predicate(ABC): method __init__ (line 21) | def __init__(self, method __call__ (line 37) | def __call__(self, gs: GameState) -> float: method close (line 58) | def close(self): method _evaluate (line 64) | def _evaluate(self, gs: GameState) -> float: method _make_name (line 70) | def _make_name(self, class_name, args, kwargs) -> str: method __str__ (line 77) | def __str__(self): method get_source_code (line 81) | def get_source_code(self) -> str: method get_signature (line 87) | def get_signature(self) -> List: method args (line 93) | def args(self): method kwargs (line 97) | def kwargs(self): method subject (line 101) | def subject(self): method create_task (line 104) | def create_task(self, method __and__ (line 119) | def __and__(self, other): method __or__ (line 121) | def __or__(self, other): method __invert__ (line 123) | def __invert__(self): method __add__ (line 125) | def __add__(self, other): method __radd__ (line 127) | def __radd__(self, other): method __sub__ (line 129) | def __sub__(self, other): method __rsub__ (line 131) | def __rsub__(self, other): method __mul__ (line 133) | def __mul__(self, other): method __rmul__ (line 135) | def __rmul__(self, other): function arg_to_string (line 139) | def arg_to_string(arg): function make_predicate (line 148) | def make_predicate(fn: Callable) -> Type[Predicate]: class PredicateOperator (line 176) | class PredicateOperator(Predicate): method __init__ (line 177) | def __init__(self, n, *predicates: Union[Predicate, Real], subject: Gr... method check (line 192) | def check(self, config: Config) -> bool: method sample (line 196) | def sample(self, config: Config, cls: Type[PredicateOperator], **kwargs): method get_source_code (line 202) | def get_source_code(self) -> str: method get_signature (line 215) | def get_signature(self): method args (line 220) | def args(self): method kwargs (line 225) | def kwargs(self): class OR (line 234) | class OR(PredicateOperator, Predicate): method __init__ (line 235) | def __init__(self, *predicates: Predicate, subject: Group=None): method _evaluate (line 237) | def _evaluate(self, gs: GameState) -> float: method sample (line 240) | def sample(self, config: Config, **kwargs): class AND (line 243) | class AND(PredicateOperator, Predicate): method __init__ (line 244) | def __init__(self, *predicates: Predicate, subject: Group=None): method _evaluate (line 246) | def _evaluate(self, gs: GameState) -> float: method sample (line 249) | def sample(self, config: Config, **kwargs): class NOT (line 252) | class NOT(PredicateOperator, Predicate): method __init__ (line 253) | def __init__(self, predicate: Predicate, subject: Group=None): method _evaluate (line 255) | def _evaluate(self, gs: GameState) -> float: method sample (line 257) | def sample(self, config: Config, **kwargs): class ADD (line 260) | class ADD(PredicateOperator, Predicate): method __init__ (line 261) | def __init__(self, *predicate: Union[Predicate, Real], subject: Group=... method _evaluate (line 263) | def _evaluate(self, gs: GameState) -> float: method sample (line 265) | def sample(self, config: Config, **kwargs): class SUB (line 268) | class SUB(PredicateOperator, Predicate): method __init__ (line 269) | def __init__(self, p: Predicate, q: Union[Predicate, Real], subject: G... method _evaluate (line 271) | def _evaluate(self, gs: GameState) -> float: method sample (line 273) | def sample(self, config: Config, **kwargs): class MUL (line 276) | class MUL(PredicateOperator, Predicate): method __init__ (line 277) | def __init__(self, *predicate: Union[Predicate, Real], subject: Group=... method _evaluate (line 279) | def _evaluate(self, gs: GameState) -> float: method sample (line 284) | def sample(self, config: Config, **kwargs): FILE: nmmo/task/task_api.py class Task (line 13) | class Task(ABC): method __init__ (line 17) | def __init__(self, method reset (line 39) | def reset(self): method close (line 48) | def close(self): method assignee (line 55) | def assignee(self) -> Tuple[int]: method completed (line 59) | def completed(self) -> bool: method progress (line 63) | def progress(self) -> float: method reward_multiplier (line 67) | def reward_multiplier(self) -> float: method reward_signal_count (line 71) | def reward_signal_count(self) -> int: method embedding (line 75) | def embedding(self): method set_embedding (line 78) | def set_embedding(self, embedding): method _map_progress_to_reward (line 81) | def _map_progress_to_reward(self, gs: GameState) -> float: method compute_rewards (line 98) | def compute_rewards(self, gs: GameState) -> Tuple[Dict[int, float], Di... method _make_name (line 119) | def _make_name(self, class_name, **kwargs) -> str: method __str__ (line 125) | def __str__(self): method subject (line 129) | def subject(self): method get_source_code (line 134) | def get_source_code(self): method get_signature (line 139) | def get_signature(self): method args (line 146) | def args(self): method kwargs (line 153) | def kwargs(self): method progress_info (line 160) | def progress_info(self): class OngoingTask (line 172) | class OngoingTask(Task): method _map_progress_to_reward (line 173) | def _map_progress_to_reward(self, gs: GameState) -> float: class HoldDurationTask (line 182) | class HoldDurationTask(Task): method __init__ (line 183) | def __init__(self, method _reset_timer (line 192) | def _reset_timer(self): method reset (line 196) | def reset(self): method _map_progress_to_reward (line 200) | def _map_progress_to_reward(self, gs: GameState) -> float: function make_same_task (line 225) | def make_same_task(pred_cls: Union[Type[Predicate], Callable], function nmmo_default_task (line 244) | def nmmo_default_task(agent_list: Iterable[int], test_mode=None) -> List... FILE: nmmo/task/task_spec.py class TaskSpec (line 39) | class TaskSpec: method __post_init__ (line 50) | def __post_init__(self): method name (line 63) | def name(self): function make_task_from_spec (line 76) | def make_task_from_spec(assign_to: Union[Iterable[int], Dict], function check_task_spec (line 153) | def check_task_spec(spec_list: List[TaskSpec], debug=False) -> List[Dict]: FILE: scripted/attack.py function closestTarget (line 10) | def closestTarget(config, ob: Observation): function attacker (line 32) | def attacker(config, ob: Observation): function target (line 46) | def target(config, actions, style, targetID): FILE: scripted/baselines.py class Scripted (line 16) | class Scripted(nmmo.Scripted): method __init__ (line 22) | def __init__(self, config, idx): method policy (line 38) | def policy(self): method forage_criterion (line 42) | def forage_criterion(self) -> bool: method forage (line 47) | def forage(self): method gather (line 53) | def gather(self, resource): method explore (line 57) | def explore(self): method downtime (line 62) | def downtime(self): method evade (line 66) | def evade(self): method attack (line 73) | def attack(self): method target_weak (line 80) | def target_weak(self): # pylint: disable=inconsistent-return-statements method scan_agents (line 95) | def scan_agents(self): method adaptive_control_and_targeting (line 112) | def adaptive_control_and_targeting(self, explore=True): method process_inventory (line 129) | def process_inventory(self): method upgrade_heuristic (line 180) | def upgrade_heuristic(self, current_level, upgrade_level, price): method process_market (line 183) | def process_market(self): method equip (line 219) | def equip(self, items: set): method consume (line 233) | def consume(self): method sell (line 250) | def sell(self, keep_k: dict, keep_best: set): method buy (line 276) | def buy(self, buy_k: dict, buy_upgrade: set): method exchange (line 301) | def exchange(self): method use (line 309) | def use(self): method __call__ (line 314) | def __call__(self, observation: Observation): class Sleeper (line 354) | class Sleeper(Scripted): method __call__ (line 356) | def __call__(self, obs): class Random (line 359) | class Random(Scripted): method __call__ (line 361) | def __call__(self, obs): class Meander (line 367) | class Meander(Scripted): method __call__ (line 369) | def __call__(self, obs): class Explore (line 375) | class Explore(Scripted): method __call__ (line 377) | def __call__(self, obs): class Forage (line 384) | class Forage(Scripted): method __call__ (line 386) | def __call__(self, obs): class Combat (line 396) | class Combat(Scripted): method __init__ (line 398) | def __init__(self, config, idx): method supplies (line 403) | def supplies(self): method wishlist (line 411) | def wishlist(self): method __call__ (line 420) | def __call__(self, obs): class Gather (line 430) | class Gather(Scripted): method __init__ (line 432) | def __init__(self, config, idx): method supplies (line 437) | def supplies(self): method wishlist (line 444) | def wishlist(self): method __call__ (line 452) | def __call__(self, obs): class Fisher (line 464) | class Fisher(Gather): method __init__ (line 465) | def __init__(self, config, idx): class Herbalist (line 471) | class Herbalist(Gather): method __init__ (line 472) | def __init__(self, config, idx): class Prospector (line 478) | class Prospector(Gather): method __init__ (line 479) | def __init__(self, config, idx): class Carver (line 485) | class Carver(Gather): method __init__ (line 486) | def __init__(self, config, idx): class Alchemist (line 492) | class Alchemist(Gather): method __init__ (line 493) | def __init__(self, config, idx): class Melee (line 499) | class Melee(Combat): method __init__ (line 500) | def __init__(self, config, idx): class Range (line 507) | class Range(Combat): method __init__ (line 508) | def __init__(self, config, idx): class Mage (line 515) | class Mage(Combat): method __init__ (line 516) | def __init__(self, config, idx): FILE: scripted/move.py function inSight (line 10) | def inSight(dr, dc, vision): function rand (line 14) | def rand(config, ob, actions, np_random): function towards (line 18) | def towards(direction, np_random): function pathfind (line 30) | def pathfind(config, ob, actions, rr, cc, np_random): function meander (line 35) | def meander(config, ob, actions, np_random): function explore (line 51) | def explore(config, ob, actions, r, c, np_random): function evade (line 61) | def evade(config, ob: Observation, actions, attacker, np_random): function forageDijkstra (line 66) | def forageDijkstra(config, ob: Observation, actions, function findResource (line 134) | def findResource(config, ob: Observation, resource): function gatherAStar (line 145) | def gatherAStar(config, ob, actions, resource, np_random, cutoff=100): function gatherBFS (line 159) | def gatherBFS(config, ob: Observation, actions, resource, np_random, cut... function aStar (line 226) | def aStar(config, ob: Observation, actions, rr, cc, cutoff=100): FILE: tests/action/test_ammo_use.py class TestAmmoUse (line 15) | class TestAmmoUse(ScriptedTestTemplate): method setUpClass (line 19) | def setUpClass(cls): method _assert_action_targets_zero (line 26) | def _assert_action_targets_zero(self, gym_obs): method test_spawn_immunity (line 36) | def test_spawn_immunity(self): method test_ammo_fire_all (line 56) | def test_ammo_fire_all(self): method test_use_ammo_only_when_attack_style_match (line 144) | def test_use_ammo_only_when_attack_style_match(self): method test_cannot_use_listed_items (line 168) | def test_cannot_use_listed_items(self): method test_receive_extra_ammo_swap (line 234) | def test_receive_extra_ammo_swap(self): method test_use_ration_potion (line 332) | def test_use_ration_potion(self): FILE: tests/action/test_destroy_give_gold.py class TestDestroyGiveGold (line 15) | class TestDestroyGiveGold(ScriptedTestTemplate): method setUpClass (line 19) | def setUpClass(cls): method test_destroy (line 34) | def test_destroy(self): method test_give_tile_npc (line 90) | def test_give_tile_npc(self): method test_give_equipped_listed (line 131) | def test_give_equipped_listed(self): method test_give_full_inventory (line 192) | def test_give_full_inventory(self): method test_give_gold (line 238) | def test_give_gold(self): FILE: tests/action/test_monkey_action.py function make_random_actions (line 16) | def make_random_actions(config, ent_obs): function filter_item_actions (line 32) | def filter_item_actions(actions, use_str_key=False): class TestMonkeyAction (line 67) | class TestMonkeyAction(unittest.TestCase): method setUpClass (line 69) | def setUpClass(cls): method rollout_with_seed (line 75) | def rollout_with_seed(config, seed, use_str_key=False): method test_monkey_action (line 87) | def test_monkey_action(self): method test_monkey_action_with_str_key (line 93) | def test_monkey_action_with_str_key(self): FILE: tests/action/test_sell_buy.py class TestSellBuy (line 15) | class TestSellBuy(ScriptedTestTemplate): method setUpClass (line 19) | def setUpClass(cls): method test_sell_buy (line 33) | def test_sell_buy(self): FILE: tests/conftest.py function pytest_benchmark_scale_unit (line 7) | def pytest_benchmark_scale_unit(config, unit, benchmarks, best, worst, s... FILE: tests/core/test_config.py class Config (line 7) | class Config(cfg.Config, cfg.Terrain, cfg.Combat): class TestConfig (line 10) | class TestConfig(unittest.TestCase): method test_config_attr_set_episode (line 11) | def test_config_attr_set_episode(self): method test_cannot_change_immutable_attr (line 21) | def test_cannot_change_immutable_attr(self): method test_cannot_change_obs_attr (line 26) | def test_cannot_change_obs_attr(self): method test_cannot_use_noninit_system (line 31) | def test_cannot_use_noninit_system(self): FILE: tests/core/test_cython_masks.py class TestCythonMasks (line 14) | class TestCythonMasks(unittest.TestCase): method setUpClass (line 16) | def setUpClass(cls): method test_move_mask (line 28) | def test_move_mask(self): method test_attack_mask (line 45) | def test_attack_mask(self): FILE: tests/core/test_entity.py class MockRealm (line 10) | class MockRealm: method __init__ (line 11) | def __init__(self): class TestEntity (line 19) | class TestEntity(unittest.TestCase): method test_entity (line 20) | def test_entity(self): method test_query_by_ids (line 47) | def test_query_by_ids(self): method test_recon_resurrect (line 62) | def test_recon_resurrect(self): FILE: tests/core/test_env.py class Config (line 22) | class Config(nmmo.config.Small, nmmo.config.AllGameSystems): class TestEnv (line 28) | class TestEnv(unittest.TestCase): method setUpClass (line 30) | def setUpClass(cls): method test_action_space (line 34) | def test_action_space(self): method test_observations (line 41) | def test_observations(self): method _validate_tiles (line 92) | def _validate_tiles(self, obs, realm: Realm): method _validate_entitites (line 101) | def _validate_entitites(self, player_id, obs, realm: Realm, entity_loc... method _validate_inventory (line 133) | def _validate_inventory(self, player_id, obs, realm: Realm): method _validate_market (line 139) | def _validate_market(self, obs, realm: Realm): method _validate_items (line 145) | def _validate_items(self, items_dict, item_obs): method test_clean_item_after_reset (line 157) | def test_clean_item_after_reset(self): method test_truncated (line 175) | def test_truncated(self): FILE: tests/core/test_game_api.py class TeamConfig (line 12) | class TeamConfig(nmmo.config.Small, nmmo.config.AllGameSystems): class TestGameApi (line 18) | class TestGameApi(unittest.TestCase): method setUpClass (line 20) | def setUpClass(cls): method test_num_agents_in_teams (line 24) | def test_num_agents_in_teams(self): method test_agent_training_game (line 31) | def test_agent_training_game(self): method test_team_training_game_spawn (line 59) | def test_team_training_game_spawn(self): method test_team_battle_mode (line 84) | def test_team_battle_mode(self): method test_competition_winner_task_completed (line 104) | def test_competition_winner_task_completed(self): method test_game_via_config (line 118) | def test_game_via_config(self): method test_game_set_next_task (line 131) | def test_game_set_next_task(self): FILE: tests/core/test_gym_obs_spaces.py class TestGymObsSpaces (line 11) | class TestGymObsSpaces(unittest.TestCase): method _is_obs_valid (line 12) | def _is_obs_valid(self, obs_spec, obs): method _test_gym_obs_space (line 18) | def _test_gym_obs_space(self, env): method test_env_without_noop (line 35) | def test_env_without_noop(self): method test_env_with_noop (line 44) | def test_env_with_noop(self): method test_env_with_fogmap (line 53) | def test_env_with_fogmap(self): method test_system_disable (line 62) | def test_system_disable(self): FILE: tests/core/test_map_generation.py class TestMapGeneration (line 11) | class TestMapGeneration(unittest.TestCase): method test_insufficient_maps (line 12) | def test_insufficient_maps(self): method test_map_preview (line 35) | def test_map_preview(self): method test_map_reset_from_fractal (line 55) | def test_map_reset_from_fractal(self): FILE: tests/core/test_observation_tile.py class TestObservationTile (line 23) | class TestObservationTile(unittest.TestCase): method setUpClass (line 25) | def setUpClass(cls): method test_tile_attr (line 32) | def test_tile_attr(self): method test_action_target_consts (line 35) | def test_action_target_consts(self): method test_obs_tile_correctness (line 40) | def test_obs_tile_correctness(self): method test_env_visible_tiles_correctness (line 79) | def test_env_visible_tiles_correctness(self): method test_make_attack_mask_within_range (line 112) | def test_make_attack_mask_within_range(self): method test_gs_where_in_1d (line 144) | def test_gs_where_in_1d(self): FILE: tests/core/test_tile_property.py class TestTileProperty (line 10) | class TestTileProperty(unittest.TestCase): method setUpClass (line 13) | def setUpClass(cls): method test_fixed_habitability_passability (line 24) | def test_fixed_habitability_passability(self): FILE: tests/core/test_tile_seize.py class MockRealm (line 11) | class MockRealm: method __init__ (line 12) | def __init__(self): class MockTask (line 20) | class MockTask: method __init__ (line 21) | def __init__(self, ent_id): class MockEntity (line 24) | class MockEntity: method __init__ (line 25) | def __init__(self, ent_id): class TestTileSeize (line 31) | class TestTileSeize(unittest.TestCase): method test_tile (line 33) | def test_tile(self): method test_map_seize_targets (line 91) | def test_map_seize_targets(self): FILE: tests/datastore/test_datastore.py class TestDatastore (line 8) | class TestDatastore(unittest.TestCase): method testdatastore_record (line 10) | def testdatastore_record(self): FILE: tests/datastore/test_id_allocator.py class TestIdAllocator (line 5) | class TestIdAllocator(unittest.TestCase): method test_id_allocator (line 6) | def test_id_allocator(self): method test_id_reuse (line 33) | def test_id_reuse(self): FILE: tests/datastore/test_numpy_datastore.py class TestNumpyTable (line 8) | class TestNumpyTable(unittest.TestCase): method test_continous_table (line 9) | def test_continous_table(self): method test_discrete_table (line 20) | def test_discrete_table(self): method test_expand (line 31) | def test_expand(self): FILE: tests/datastore/test_serialized.py class MockDatastoreRecord (line 16) | class MockDatastoreRecord(): method __init__ (line 17) | def __init__(self): method get (line 20) | def get(self, name): method update (line 23) | def update(self, name, value): class MockDatastore (line 26) | class MockDatastore(): method create_record (line 27) | def create_record(self, name): method register_object_type (line 30) | def register_object_type(self, name, attributes): class TestSerialized (line 34) | class TestSerialized(unittest.TestCase): method test_serialized (line 36) | def test_serialized(self): FILE: tests/systems/test_exchange.py class MockRealm (line 13) | class MockRealm: method __init__ (line 14) | def __init__(self): class MockEntity (line 22) | class MockEntity: method __init__ (line 23) | def __init__(self) -> None: class TestExchange (line 30) | class TestExchange(unittest.TestCase): method test_listings (line 31) | def test_listings(self): method test_for_sale_items (line 70) | def test_for_sale_items(self): FILE: tests/systems/test_item.py class MockRealm (line 9) | class MockRealm: method __init__ (line 10) | def __init__(self): class TestItem (line 19) | class TestItem(unittest.TestCase): method test_item (line 20) | def test_item(self): method test_owned_by (line 56) | def test_owned_by(self): FILE: tests/systems/test_skill_level.py class TestSkillLevel (line 10) | class TestSkillLevel(unittest.TestCase): method setUpClass (line 12) | def setUpClass(cls): method test_experience_calculator (line 18) | def test_experience_calculator(self): method test_add_xp (line 38) | def test_add_xp(self): FILE: tests/task/test_demo_task_creation.py function rollout (line 15) | def rollout(env, tasks, steps=5): class TestDemoTask (line 21) | class TestDemoTask(unittest.TestCase): method test_baseline_tasks (line 23) | def test_baseline_tasks(self): method test_player_kill_reward (line 125) | def test_player_kill_reward(self): method test_predicate_math (line 180) | def test_predicate_math(self): method test_task_spec_based_curriculum (line 215) | def test_task_spec_based_curriculum(self): FILE: tests/task/test_manual_curriculum.py function PracticeFormation (line 76) | def PracticeFormation(gs, subject, dist, num_tick): function PracticeInventoryManagement (line 174) | def PracticeInventoryManagement(gs, subject, space, num_tick): function create_pool (line 305) | def create_pool(num_proc): FILE: tests/task/test_predicates.py class TestBasePredicate (line 28) | class TestBasePredicate(unittest.TestCase): method _get_taskenv (line 31) | def _get_taskenv(self, method _check_result (line 60) | def _check_result(self, env, test_preds, infos, true_task): method _check_progress (line 76) | def _check_progress(self, task, infos, value): method test_tickge_stay_alive_rip (line 83) | def test_tickge_stay_alive_rip(self): method test_can_see_tile (line 141) | def test_can_see_tile(self): method test_can_see_agent (line 185) | def test_can_see_agent(self): method test_occupy_tile (line 226) | def test_occupy_tile(self): method test_distance_traveled (line 259) | def test_distance_traveled(self): method test_all_members_within_range (line 293) | def test_all_members_within_range(self): method test_attain_skill (line 329) | def test_attain_skill(self): method test_gain_experience (line 363) | def test_gain_experience(self): method test_inventory_space_ge_not (line 397) | def test_inventory_space_ge_not(self): method test_own_equip_item (line 430) | def test_own_equip_item(self): method test_fully_armed (line 484) | def test_fully_armed(self): method test_hoard_gold_and_team (line 516) | def test_hoard_gold_and_team(self): # HoardGold, TeamHoardGold method test_exchange_gold_predicates (line 543) | def test_exchange_gold_predicates(self): # Earn Gold, Spend Gold, Make... method test_count_event (line 580) | def test_count_event(self): # CountEvent method test_score_hit (line 602) | def test_score_hit(self): # ScoreHit method test_defeat_entity (line 643) | def test_defeat_entity(self): # PlayerKill method test_item_event_predicates (line 698) | def test_item_event_predicates(self): # Consume, Harvest, List, Buy FILE: tests/task/test_sample_task_from_file.py class TestSampleTaskFromFile (line 6) | class TestSampleTaskFromFile(unittest.TestCase): method test_sample_task_from_file (line 7) | def test_sample_task_from_file(self): FILE: tests/task/test_task_api.py function Success (line 24) | def Success(gs, subject: Group): function Failure (line 27) | def Failure(gs, subject: Group): function Fake (line 30) | def Fake(gs, subject, a,b,c): class MockGameState (line 33) | class MockGameState(): method __init__ (line 34) | def __init__(self): method clear_cache (line 41) | def clear_cache(self): class TestTaskAPI (line 44) | class TestTaskAPI(unittest.TestCase): method test_predicate_operators (line 45) | def test_predicate_operators(self): method test_team_assignment (line 113) | def test_team_assignment(self): method test_predicate_name (line 123) | def test_predicate_name(self): method test_task_api_with_predicate (line 139) | def test_task_api_with_predicate(self): method test_task_api_with_function (line 170) | def test_task_api_with_function(self): method test_predicate_fn_using_other_predicate_fn (line 196) | def test_predicate_fn_using_other_predicate_fn(self): method test_completed_tasks_in_info (line 283) | def test_completed_tasks_in_info(self): method test_make_task_from_spec (line 331) | def test_make_task_from_spec(self): method test_hold_duration_task (line 371) | def test_hold_duration_task(self): method test_task_spec_with_predicate (line 426) | def test_task_spec_with_predicate(self): FILE: tests/task/test_task_system_perf.py class TestTaskSystemPerf (line 10) | class TestTaskSystemPerf(unittest.TestCase): method test_nmmo_default_task (line 11) | def test_nmmo_default_task(self): FILE: tests/test_death_fog.py class TestDeathFog (line 6) | class TestDeathFog(unittest.TestCase): method test_death_fog (line 7) | def test_death_fog(self): FILE: tests/test_determinism.py class TestDeterminism (line 16) | class TestDeterminism(unittest.TestCase): method test_np_random_get_direction (line 17) | def test_np_random_get_direction(self): method test_map_determinism (line 32) | def test_map_determinism(self): method test_env_level_rng (line 59) | def test_env_level_rng(self): FILE: tests/test_eventlog.py class MockRealm (line 13) | class MockRealm: method __init__ (line 14) | def __init__(self): method step (line 23) | def step(self): class MockEntity (line 27) | class MockEntity(Entity): method __init__ (line 29) | def __init__(self, ent_id, **kwargs): method ent_id (line 34) | def ent_id(self): method attack_level (line 38) | def attack_level(self): class TestEventLog (line 42) | class TestEventLog(unittest.TestCase): method test_event_logging (line 44) | def test_event_logging(self): FILE: tests/test_memory_usage.py function test_memory_usage (line 6) | def test_memory_usage(): FILE: tests/test_mini_games.py class TestMinigames (line 11) | class TestMinigames(unittest.TestCase): method test_mini_games (line 12) | def test_mini_games(self): FILE: tests/test_performance.py function create_and_reset (line 20) | def create_and_reset(conf): function create_config (line 24) | def create_config(base, *systems): function benchmark_config (line 36) | def benchmark_config(benchmark, base, nent, *systems): function test_small_env_creation (line 47) | def test_small_env_creation(benchmark): function test_small_env_reset (line 50) | def test_small_env_reset(benchmark): function test_fps_base_small_1_pop (line 56) | def test_fps_base_small_1_pop(benchmark): function test_fps_minimal_small_1_pop (line 59) | def test_fps_minimal_small_1_pop(benchmark): function test_fps_npc_small_1_pop (line 62) | def test_fps_npc_small_1_pop(benchmark): function test_fps_test_small_1_pop (line 65) | def test_fps_test_small_1_pop(benchmark): function test_fps_no_npc_small_1_pop (line 68) | def test_fps_no_npc_small_1_pop(benchmark): function test_fps_all_small_1_pop (line 72) | def test_fps_all_small_1_pop(benchmark): function test_fps_base_med_1_pop (line 75) | def test_fps_base_med_1_pop(benchmark): function test_fps_minimal_med_1_pop (line 78) | def test_fps_minimal_med_1_pop(benchmark): function test_fps_npc_med_1_pop (line 81) | def test_fps_npc_med_1_pop(benchmark): function test_fps_test_med_1_pop (line 84) | def test_fps_test_med_1_pop(benchmark): function test_fps_no_npc_med_1_pop (line 87) | def test_fps_no_npc_med_1_pop(benchmark): function test_fps_all_med_1_pop (line 91) | def test_fps_all_med_1_pop(benchmark): function test_fps_base_med_100_pop (line 94) | def test_fps_base_med_100_pop(benchmark): function test_fps_minimal_med_100_pop (line 97) | def test_fps_minimal_med_100_pop(benchmark): function test_fps_npc_med_100_pop (line 100) | def test_fps_npc_med_100_pop(benchmark): function test_fps_test_med_100_pop (line 103) | def test_fps_test_med_100_pop(benchmark): function test_fps_no_npc_med_100_pop (line 106) | def test_fps_no_npc_med_100_pop(benchmark): function test_fps_all_med_100_pop (line 110) | def test_fps_all_med_100_pop(benchmark): function set_seed_test (line 113) | def set_seed_test(): function set_seed_test_complex (line 131) | def set_seed_test_complex(): FILE: tests/test_pettingzoo.py class TestPettingZoo (line 8) | class TestPettingZoo(unittest.TestCase): method test_pettingzoo_api (line 9) | def test_pettingzoo_api(self): FILE: tests/test_rollout.py class SimpleConfig (line 4) | class SimpleConfig(nmmo.config.Small, nmmo.config.Combat): function test_rollout (line 7) | def test_rollout(): FILE: tests/testhelpers.py function actions_are_equal (line 18) | def actions_are_equal(source_atn, target_atn, debug=True): function observations_are_equal (line 48) | def observations_are_equal(source_obs, target_obs, debug=True): function player_total (line 85) | def player_total(env): function count_actions (line 89) | def count_actions(tick, actions): class ScriptedAgentTestConfig (line 110) | class ScriptedAgentTestConfig(nmmo.config.Small, nmmo.config.AllGameSyst... class ScriptedAgentTestEnv (line 122) | class ScriptedAgentTestEnv(nmmo.Env): method __init__ (line 129) | def __init__(self, config: nmmo.config.Config, seed=None): method reset (line 139) | def reset(self, map_id=None, seed=None, options=None): method _compute_scripted_agent_actions (line 143) | def _compute_scripted_agent_actions(self, actions): function change_spawn_pos (line 164) | def change_spawn_pos(realm: Realm, ent_id: int, new_pos): function provide_item (line 178) | def provide_item(realm: Realm, ent_id: int, class ScriptedTestTemplate (line 186) | class ScriptedTestTemplate(unittest.TestCase): method setUpClass (line 189) | def setUpClass(cls): method _make_item_sig (line 211) | def _make_item_sig(self): method _setup_env (line 221) | def _setup_env(self, random_seed, check_assert=True, remove_immunity=F... method _check_ent_mask (line 264) | def _check_ent_mask(self, ent_obs, atn, target_id): method _check_inv_mask (line 271) | def _check_inv_mask(self, ent_obs, atn, item_sig): method _check_mkt_mask (line 279) | def _check_mkt_mask(self, ent_obs, item_id): method _check_default_asserts (line 285) | def _check_default_asserts(self, env): method _check_assert_make_action (line 330) | def _check_assert_make_action(self, env, atn, test_cond): function profile_env_step (line 379) | def profile_env_step(action_target=True, tasks=None, condition=None):