Module: PFM::HoneyTree

Defined in:
docs/4_Systems_998_Global_Systems.rb

Overview

Module holding all the logic about Honey Trees

Constant Summary collapse

COUNT =

Maximum number of honney trees

21
MON_INDEXES =

List of probability for each mon_index

[0...40, 40...60, 60...80, 80...90, 90...95, 95...100]
LAST_MON_INDEX_CHANCES =

Probablity to get the last mon_index on the same tree

90
SHAKES_NUMBERS =

2D List of shakes value (column -> chance -> nb_shakes)

[[], [0...20, 20...79, 79...99, 99...100], [0...1, 1...21, 21...96, 96...100], [0...1, 1...2, 2...7, 7...100]]
COLUMN_INDEXES =

List of chance to get a specific column if the Tree is a Munchlax tree or not

{false => [0...10, 10...80, 80...100], true => [0...9, 9...29, 29...99, 99...100]}
WAIT_TO_BATTLE =

Time to wait before being able to fight a Pokemon (in seconds)

21540
LEAVE_TREE_TIME =

Time when the Pokemon leave the tree

86340
POKEMON_LISTS =

List of Pokemon / Column

[], %i[combee wurmple burmy cherubi aipom aipom], %i[burmy cherubi combee aipom aipom heracross], %i[munchlax munchlax munchlax munchlax munchlax munchlax]
LEVEL_RANGE =

Level range of the battles

5..15

Class Method Summary collapse

Class Method Details

.can_battle?(id) ⇒ Boolean

Tell if the tree is ready to battle

Parameters:

  • id (Integer)

    ID of the tree

Returns:

  • (Boolean)


36
37
# File 'docs/4_Systems_998_Global_Systems.rb', line 36

def can_battle?(id)
end

.get(id) ⇒ Hash{ Symbol => Integer}

Return the honney tree info

Parameters:

  • id (Integer)

    ID of the tree

Returns:

  • (Hash{ Symbol => Integer})


26
27
# File 'docs/4_Systems_998_Global_Systems.rb', line 26

def get(id)
end

.has_pokemon?(id) ⇒ Boolean

Tell if a tree has a Pokemon in it

Parameters:

  • id (Integer)

    ID of the tree

Returns:

  • (Boolean)


31
32
# File 'docs/4_Systems_998_Global_Systems.rb', line 31

def has_pokemon?(id)
end

.last_mon_indexInteger

Return the last index of the choosen mon in the table

Returns:

  • (Integer)


52
53
# File 'docs/4_Systems_998_Global_Systems.rb', line 52

def last_mon_index
end

.last_mon_index=(index)

Set the ID of the last choosen mon in the table

Parameters:

  • index (Integer)


56
57
# File 'docs/4_Systems_998_Global_Systems.rb', line 56

def last_mon_index=(index)
end

.last_tree_idInteger

Return the ID of the last tree

Returns:

  • (Integer)


44
45
# File 'docs/4_Systems_998_Global_Systems.rb', line 44

def last_tree_id
end

.last_tree_id=(id)

Set the ID of the last tree

Parameters:

  • id (Integer)

    ID of the tree



48
49
# File 'docs/4_Systems_998_Global_Systems.rb', line 48

def last_tree_id=(id)
end

.munchlax?(id) ⇒ Boolean

Tell if the tree is a munchlax tree or not

Parameters:

  • id (Integer)

    ID of the tree

Returns:

  • (Boolean)


61
62
# File 'docs/4_Systems_998_Global_Systems.rb', line 61

def munchlax?(id)
end

.slather(id)

Slather a tree

Parameters:

  • id (Integer)

    ID of the tree



40
41
# File 'docs/4_Systems_998_Global_Systems.rb', line 40

def slather(id)
end