woob.capabilities.rpg

class woob.capabilities.rpg.CapRPG

Bases: woob.capabilities.collection.CapCollection

Capability for rpg games to list characters, objects, etc.

get_character(character_id)

Get a character with its ID.

Parameters

character_id (str) – ID of the character

Return type

class

Character

Raises
class

CharcterNotFound

get_character_class(class_id)

Get details of a class according to id

Parameters

class_id (str) – ID of the skill

Return type

class

CharacterClass

Raises
class

CharacterClassNotFound

get_collectable_item(item_id)

Get details of a collectable item according to id

Parameters

item_id (str) – ID of the skill

Return type

class

CollectableItem

Raises
class

CollectableItemNotFound

get_skill(skill_id)

Get a skill from with ID.

Parameters

skill_id (str) – ID of the skill

Return type

class

Skill

Raises
class

SkillNotFound

iter_character_classes()

Iter all classes

Return type

class

iter[:class: CharacterClass]

iter_characters()

Iter characters.

Return type

iter[:class: Character]

iter_collectable_items()

Iter all collectable items

Return type

class

iter[:class: CollectableItem]

iter_resources(objs, split_path)

Iter reources.

return iter_characters() for ‘character’

iter_skill_set(character_id, skill_type=None)

Iter skills for a specific character

Parameters
  • character_id (str) – ID of the character

  • skill_type (int) – Type of skill

Return type

class

iter[:class: Skill]

iter_skills(skill_type=None)

Iter all available skills.

Parameters

skill_type (int) – Type of skill

Return type

iter[:class: Skill]

class woob.capabilities.rpg.Character(id='', url=NotLoaded, backend=None)

Bases: woob.capabilities.rpg.BaseRPGObject

Creature or person :var base_stats: (dict) Base statistics (default: {}) :var character_classes: (list) List of CharacterClasses id (default: []) :var skills: (list) List of Skills id (default: []) :var next_forms: (list) List of the next forms of the character (default: []) :var locations: (list) List of locations of the character (default: [])

class woob.capabilities.rpg.CharacterClass(id='', url=NotLoaded, backend=None)

Bases: woob.capabilities.rpg.BaseRPGObject

CharacterClass of a character

class woob.capabilities.rpg.CollectableItem(id='', url=NotLoaded, backend=None)

Bases: woob.capabilities.rpg.BaseRPGObject

Object that you can find in the game :var to_use: (bool) The object can be used at anytime :var to_carry: (bool) The object must be carried to be used (like in battle) :var category: (str) Category of the item :var locations: (list) List of locations of the item (default: [])

class woob.capabilities.rpg.Skill(id='', url=NotLoaded, backend=None)

Bases: woob.capabilities.rpg.BaseRPGObject

Skill of a character :var type: (int) Type of skill (default: 0) :var target: (int) Target of the skill (default: 0) :var statistics: (dict) Dict of statistics (default: {}) :var character_classes: (list) List of CharacterClass ids that can use this move (default: []) :var category: (int) Category of skill