Module: LOTS

Defined in:
lib/ui.rb,
lib/enemy.rb,
lib/story.rb,
lib/world.rb,
lib/character.rb

Overview

Legend of the Sourcerer Written by Robert W. Oliver II <[email protected]> Copyright © 2018 Sourcerer, All Rights Reserved. Licensed under GPLv3.

Defined Under Namespace

Classes: Character, Enemy, Story, UI, World

Constant Summary collapse

UI_FRAME_HORIZONTAL =
"\u2501"
UI_FRAME_VERTICAL =
"\u2503"
UI_FRAME_UPPER_LEFT =
"\u250F"
UI_FRAME_LOWER_LEFT =
"\u2517"
UI_FRAME_UPPER_RIGHT =
"\u2513"
UI_FRAME_LOWER_RIGHT =
"\u251B"
"\u00A9"
UI_EMAIL =
"\u2709"
UI_ARROW =
"\u2712"
ENEMY_CATALOG =
[
  [:name => "Imp", :health => 3, :mana => 0, :str => 3, :lines => 1], 
  [:name => "Rabid Wolf", :health => 4, :mana => 0, :str => 4, :lines => 2],
  [:name => "Rock Giant", :health => 7, :mana => 3, :str => 5, :lines => 5],
  [:name => "Toxic Toad", :health => 2, :mana => 6, :str => 1, :lines => 2],
  [:name => "Rabid Bear", :health => 5, :mana => 0, :str => 4, :lines => 3],
  [:name => "Angry Fae", :health => 3, :mana => 10, :str => 2, :lines => 5]
]
PLAYER_DEAD =
"PLAYER_DEAD"
STORY_INTRO =
[
"Your journey to discover your true potential has been arduous, but a glimmer of hope shines in the darkness.",
"A vivid dream stirrs you from your sleep. You are instructed to visit the " + "Sourcerer".light_white + ", the Oracle of the Path.",
"You feel certain he will provide the insight you need. Inspired, you carry on.",
"",
"At the end of the day's travel, you set up camp and find an old " + "map".light_white + " at the base of a tree.",
"You gaze at the ancient parchment, studying the path ahead."
]
STORY_AREA_TREE =
[
  "You see a magnificent tree standing tall above you."
]
STORY_AREA_WATER =
[
  "You stand on the banks of a crystal-clear lake."
]
STORY_AREA_MOUNTAIN =
[
  "A majestic snow-topped mountain range graces the horizon."
]
STORY_AREA_ENEMY =
[
  "You encounter an enemy!"
]
STORY_PLAYER_DEAD =
[
  "You have died.",
  "",
  "You failed to reach the Sourcerer. Please try again.",
]
STORY_END =
[
  "You've reached the Sourcerer!".light_white,
  "",
  "He stares deeply into your eyes. His knowledable, seeking gaze inspires you to recall",
  "the long journey you have endured. You recall your battles with vicious enemies and are",
  "proud of the many lines of code you have earned.",
  "",
  "The Sourcerer speaks:",
  "",
  "To be a better programmer, you must learn from your journey. By taking careful note".light_yellow,
  "of your successes and analyizing your performance, you can find the information you".light_yellow,
  "seek to better yourself.".light_yellow,
  "",
  "THANK YOU FOR PLAYING!".light_red,
  "",
]
MAP_WIDTH =
64
MAP_HEIGHT =
14
MAP_KEY_TREE =
"\u2663"
MAP_KEY_WATER =
"\u2248"
MAP_KEY_GRASS =
"\u2588"
MAP_KEY_MOUNTAIN =
"\u25B2"
MAP_KEY_ENEMY =
"\u263A"
MAP_KEY_SOURCERER =
"\u263B"
MAP_KEY_PLAYER =
"\u1330"
MAP_POSSIBLE_KEYS =

Weighted

[
  MAP_KEY_TREE,
  MAP_KEY_TREE,
  MAP_KEY_TREE,
  MAP_KEY_TREE,
  MAP_KEY_WATER,
  MAP_KEY_GRASS,
  MAP_KEY_MOUNTAIN,
  MAP_KEY_ENEMY,
  MAP_KEY_ENEMY
]
MAP_SOURCERER_X =
MAP_WIDTH
MAP_SOURCERER_Y =
1
ENEMY_KILLED =
"KILLED"
HIT_CHANCE_MODIFIER =
5
ATTACK_VALUE_MODIFIER =
1