Class: Pathfinding::Cursor

Inherits:
Object show all
Includes:
GameData::SystemTags
Defined in:
docs/01450_Systems_00003_Map_Engine.rb

Overview


Class that describe and manipulate the simili character used in pathfinding

Constant Summary collapse

SurfTag =

SystemTags that trigger Surfing

Game_Character::SurfTag
SurfLTag =

SystemTags that does not trigger leaving water

Game_Character::SurfLTag
SlideTags =

SystemTags that triggers “sliding” state

[TIce, RapidsL, RapidsR, RapidsU, RapidsD, RocketL, RocketU, RocketD, RocketR, RocketRL, RocketRU, RocketRD, RocketRR]
BRIDGE_TILES =

Array used to detect if a character is on a bridge tile

[BridgeRL, BridgeUD]

Constants included from GameData::SystemTags

GameData::SystemTags::AcroBike, GameData::SystemTags::AcroBikeRL, GameData::SystemTags::AcroBikeUD, GameData::SystemTags::BridgeRL, GameData::SystemTags::BridgeUD, GameData::SystemTags::CrackedSoil, GameData::SystemTags::DeepSwamp, GameData::SystemTags::Empty, GameData::SystemTags::HeadButt, GameData::SystemTags::Hole, GameData::SystemTags::JumpD, GameData::SystemTags::JumpL, GameData::SystemTags::JumpR, GameData::SystemTags::JumpU, GameData::SystemTags::MachBike, GameData::SystemTags::Puddle, GameData::SystemTags::RapidsD, GameData::SystemTags::RapidsL, GameData::SystemTags::RapidsR, GameData::SystemTags::RapidsU, GameData::SystemTags::Road, GameData::SystemTags::RocketD, GameData::SystemTags::RocketL, GameData::SystemTags::RocketR, GameData::SystemTags::RocketRD, GameData::SystemTags::RocketRL, GameData::SystemTags::RocketRR, GameData::SystemTags::RocketRU, GameData::SystemTags::RocketU, GameData::SystemTags::SlopesL, GameData::SystemTags::SlopesR, GameData::SystemTags::StairsD, GameData::SystemTags::StairsL, GameData::SystemTags::StairsR, GameData::SystemTags::StairsU, GameData::SystemTags::StopSlide, GameData::SystemTags::SwampBorder, GameData::SystemTags::TCave, GameData::SystemTags::TGrass, GameData::SystemTags::TIce, GameData::SystemTags::TMount, GameData::SystemTags::TPond, GameData::SystemTags::TSand, GameData::SystemTags::TSea, GameData::SystemTags::TSnow, GameData::SystemTags::TTallGrass, GameData::SystemTags::TUnderWater, GameData::SystemTags::TWetSand, GameData::SystemTags::WaterFall, GameData::SystemTags::Whirlpool, GameData::SystemTags::ZTag

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from GameData::SystemTags

gen, system_tag_db_symbol

Constructor Details

#initialize(character) ⇒ Cursor

Returns a new instance of Cursor.



2942
2943
# File 'docs/01450_Systems_00003_Map_Engine.rb', line 2942

def initialize(character)
end

Instance Attribute Details

#__bridge (readonly)

Returns the value of attribute __bridge.



2941
2942
2943
# File 'docs/01450_Systems_00003_Map_Engine.rb', line 2941

def __bridge
  @__bridge
end

#x (readonly)

Returns the value of attribute x.



2938
2939
2940
# File 'docs/01450_Systems_00003_Map_Engine.rb', line 2938

def x
  @x
end

#y (readonly)

Returns the value of attribute y.



2939
2940
2941
# File 'docs/01450_Systems_00003_Map_Engine.rb', line 2939

def y
  @y
end

#z (readonly)

Returns the value of attribute z.



2940
2941
2942
# File 'docs/01450_Systems_00003_Map_Engine.rb', line 2940

def z
  @z
end

Instance Method Details

#sim_move?(sx, sy, sz, code, b = @__bridge, slide = @sliding, surf = @surfing) ⇒ Boolean

Simulate the mouvement of the character and store the data into cursor’s attributes

Parameters:

  • sx (Integer)

    start coords X

  • sy (Integer)

    start coords Y

  • sz (Integer)

    start coords z

  • code (Integer)

    mouvement’s code

  • b (Array, nil) (defaults to: @__bridge)

    bridge metadata

  • slide (Boolean) (defaults to: @sliding)

    slide meta data

  • surf (Boolean) (defaults to: @surfing)

    surf meta data

Returns:

  • (Boolean)


2956
2957
# File 'docs/01450_Systems_00003_Map_Engine.rb', line 2956

def sim_move?(sx, sy, sz, code, b = @__bridge, slide = @sliding, surf = @surfing)
end

#state

Get the current state of the cursor



2945
2946
# File 'docs/01450_Systems_00003_Map_Engine.rb', line 2945

def state
end