Class: PFM::ItemDescriptor::Wrapper

Inherits:
Object
  • Object
show all
Defined in:
docs/3_Studio.rb

Overview

Wrapper to make the item description more usefull

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#action_to_push=(value) (writeonly)

Register the action_to_push block



1798
1799
1800
# File 'docs/3_Studio.rb', line 1798

def action_to_push=(value)
  @action_to_push = value
end

#chen ⇒ Boolean

Get if the item should not be used there

Returns:

  • (Boolean)


1762
1763
1764
# File 'docs/3_Studio.rb', line 1762

def chen
  @chen
end

#item ⇒ Studio::Item

Get the item bound to this wrapper

Returns:



1780
1781
1782
# File 'docs/3_Studio.rb', line 1780

def item
  @item
end

#no_effect ⇒ Boolean

Get if the item has no effect

Returns:

  • (Boolean)


1759
1760
1761
# File 'docs/3_Studio.rb', line 1759

def no_effect
  @no_effect
end

#on_creature_choice(creature, scene) ⇒ Boolean

Call the on_creature_choice block

Parameters:

Returns:

  • (Boolean)


1810
1811
# File 'docs/3_Studio.rb', line 1810

def on_creature_choice(creature, scene)
end

#on_creature_use(creature, scene)

Call the on_creature_use block

Parameters:



1820
1821
# File 'docs/3_Studio.rb', line 1820

def on_creature_use(creature, scene)
end

#on_skill_choice(skill, scene) ⇒ Boolean

Call the on_creature_choice block

Parameters:

Returns:

  • (Boolean)


1826
1827
# File 'docs/3_Studio.rb', line 1826

def on_skill_choice(skill, scene)
end

#on_skill_use(creature, skill, scene)

Call the on_skill_use block

Parameters:



1832
1833
# File 'docs/3_Studio.rb', line 1832

def on_skill_use(creature, skill, scene)
end

#on_use(scene)

Call the on_use block

Parameters:



1836
1837
# File 'docs/3_Studio.rb', line 1836

def on_use(scene)
end

#open_party ⇒ Boolean

Get if the item should open the party menu

Returns:

  • (Boolean)


1765
1766
1767
# File 'docs/3_Studio.rb', line 1765

def open_party
  @open_party
end

#open_skill ⇒ Boolean

Get if the item should open the skill menu

Returns:

  • (Boolean)


1768
1769
1770
# File 'docs/3_Studio.rb', line 1768

def open_skill
  @open_skill
end

#open_skill_learn ⇒ Integer?

Get the ID of the move that should be learnt if it should be learnt

Returns:

  • (Integer, nil)


1771
1772
1773
# File 'docs/3_Studio.rb', line 1771

def open_skill_learn
  @open_skill_learn
end

#skill ⇒ PFM::Skill (readonly)

Get the skill bound to the wrapper

Returns:



1783
1784
1785
# File 'docs/3_Studio.rb', line 1783

def skill
  @skill
end

#skill_message_id ⇒ Integer?

Get the ID of the message that should be shown in the Summary UI

Returns:

  • (Integer, nil)


1786
1787
1788
# File 'docs/3_Studio.rb', line 1786

def skill_message_id
  @skill_message_id
end

#stone_evolve ⇒ Boolean

Get if the item is making a Pokemon evolve

Returns:

  • (Boolean)


1774
1775
1776
# File 'docs/3_Studio.rb', line 1774

def stone_evolve
  @stone_evolve
end

#use_before_telling ⇒ Boolean

Get if the item should be used before the usage message

Returns:

  • (Boolean)


1777
1778
1779
# File 'docs/3_Studio.rb', line 1777

def use_before_telling
  @use_before_telling
end

Instance Method Details

#bind(scene, creature, skill = nil)

Bind the wrapper to a scene, creature & skill

Parameters:



1845
1846
# File 'docs/3_Studio.rb', line 1845

def bind(scene, creature, skill = nil)
end

#execute_battle_action

Call the action_to_push block



1839
1840
# File 'docs/3_Studio.rb', line 1839

def execute_battle_action
end

#on_creature_choice? ⇒ Boolean

Tell if the wrapper has a Pokemon choice

Returns:

  • (Boolean)


1804
1805
# File 'docs/3_Studio.rb', line 1804

def on_creature_choice?
end

#rejection_message(creature) ⇒ String

Build the user-facing message when on_creature_choice returns false for this creature

Parameters:

Returns:



1815
1816
# File 'docs/3_Studio.rb', line 1815

def rejection_message(creature)
end

#void_non_battle_block

Void all regular block for battle usage



1800
1801
# File 'docs/3_Studio.rb', line 1800

def void_non_battle_block
end