Commit graph

57 commits

Author SHA1 Message Date
Bill Niblock
4e2432ac66 Re-org...again... for gemspec 2017-10-14 22:33:21 -04:00
Bill Niblock
9575160f29 Implement Thor
- Remove old sapling.rb file
- Add new directory bin/
- Add new version of sapling.rb
2017-10-14 21:47:01 -04:00
Bill Niblock
4f0a6a11fb Merge pull request #8 from VagabondAzulien/editor
Editor
2017-10-14 15:25:19 -04:00
Bill Nibz
4b930fb67b Sapling: Dynamic local requires 2017-10-14 15:15:54 -04:00
Bill Nibz
b7cea51f7a Planter: Modify conditional logic 2017-10-14 15:15:38 -04:00
Bill Nibz
ca5ddf7baf Re-organization 2017-10-14 15:14:41 -04:00
Bill Nibz
dfc4117527 Planter: Gardner to Dialogue 2017-10-14 14:39:11 -04:00
Bill Nibz
783fb886fd Gardner: Remove display functionality 2017-10-14 14:38:41 -04:00
Bill Nibz
d0ebc37923 Dialogue: Move display back in 2017-10-14 14:38:19 -04:00
Bill Niblock
7b1b0541c1 planter.rb: Implement branch desc. editing 2017-05-21 15:56:12 -04:00
Bill Niblock
1af5c9a53c planter.rb: Improve editor and options
- Editor: Enable trunk editing
- General: Add value for Gardner debug mode
- General: Improve visability of option chosen
- General: Improve display
2017-05-14 14:13:50 -04:00
Bill Niblock
78f9837b5a dialogue.rb: Add debug value for Gardner 2017-05-14 14:13:20 -04:00
Bill Niblock
03d09105f3 gardner.rb: Add debug options and information 2017-05-14 14:12:32 -04:00
Bill Niblock
4b33abcd75 planter.rb: Implement editor logic
- Added flow for working with editor:
  - Allow for changing branches
  - Recognize all options, with ease of implementing more
  - Allow for exiting the editor
- Move assignment into initialize
2017-05-13 19:45:19 -04:00
Bill Niblock
1c6206c3cd dialogue.rb: Move assignments into initialize 2017-05-13 19:43:48 -04:00
Bill Niblock
4c726b079d sapling.rb: Modify start options
- Reduce some LOC by moving some assignments into the initialize functions of
  both Dialogue and Planter
2017-05-13 19:42:42 -04:00
Bill Niblock
2e2fea9e58 dialogue.rb: Update comment 2017-05-13 15:55:42 -04:00
Bill Niblock
802074a513 planter.rb: Utilize display code now in Gardner 2017-05-13 15:01:28 -04:00
Bill Niblock
280d016d38 gardner.rb: Move display code from dialogue 2017-05-13 15:00:36 -04:00
Bill Niblock
5f7da9d55a dialogue.rb: Refactor display code
- Dialogue should be responsible for the flow of a tree,
not displaying parts of it. With the exception of the prompt, all
display responsibilities fall to Gardner
2017-05-13 14:59:16 -04:00
Bill Niblock
ccf8a3b5f6 planter.rb: Style refactor updates 2017-05-07 23:52:13 -04:00
Bill Niblock
a2dd7e3b1c gardner.rb: Refactor
- Remove functionality that doesn't belong in this module:
  - Move printing of trunk to the dialogue class
  - Remove tree generation entirely; let other modules generate trees as
  they need them
- Style formatting
2017-05-07 23:49:12 -04:00
Bill Niblock
e27cd43e7c dialogue.rb: Refactor
- Abstract functionality from talk into individual functions:
  - display_trunk: Displays the trunk of the branch.
  - display_branch: Displays the branch and option list
  - get_response: Displays the conversation prompt, and gets the
  response

- Of note, this allows the editor to make use of talk functionality
2017-05-07 23:46:19 -04:00
Bill Niblock
252ad93d5e sapling/utility.rb: Minor style refactoring 2017-05-07 23:43:35 -04:00
Bill Niblock
8d2da5c6c6 Update documentation 2017-05-07 16:59:53 -04:00
Bill Niblock
d0b25e210c Fix documentation warnings 2017-05-07 16:59:24 -04:00
Bill Niblock
29be7885de planter.rb: Start work on editor
This should probably be on it's own branch, but too many of the changes I made
were already committed.

- Logic for a Plot, basically a data class
- Logic for Spade, the main functionality of the class
- Logic to load and parse the tree
- Functionality for loading the first branch with debugging mode

TO-DO
- Abstract branch display properly into Dialogue
- Abstract tree loading and parsing probably back into Gardner
- Change Gardner to a different name. Like... Druid or something...
- Actually build the editor
2017-05-07 16:56:31 -04:00
Bill Niblock
1740c759df .travis.yml: Remove unnecessary Ruby versions 2017-05-07 16:53:33 -04:00
Bill Niblock
bd69690272 gardner.rb: Refactoring
- Move YAML file loading to sapling
- Move tree verification to utility
2017-05-07 16:53:16 -04:00
Bill Niblock
4570ee37e6 sapling.rb: Multiple fixes
- Add logic for Planter, the editor module
- Add logic for catching a bad switch, and reporting accordingly
- Add logic for when no tree is included when required, and reporting
  accordingly
- Move YAML file loading from Dialogue/Gardner to here
2017-05-07 16:51:00 -04:00
Bill Niblock
adecc3b193 dialogue.rb: Add debug mode and results
- Dialogue can show some additional, generally hidden details about what's on
  screen.
- New attribute :debug (Boolean)
- Added debug information
2017-05-07 16:47:05 -04:00
Bill Niblock
520aad9740 utility.rb: Functionality shared across sapling
- Added some constants, specifically those used for brand new trees
- Moved the verify functionality into here
2017-05-07 16:43:57 -04:00
Bill Niblock
2d0f9a0318 .travis.yml: Travis-CI barebones config file 2017-05-07 13:00:57 -04:00
Bill Niblock
9389816052 README.md: Update links to respect new var dir 2017-05-07 13:00:09 -04:00
Bill Niblock
36c9f0d3ca Abstract sapling modules into individual modules
- module gardner -> lib/sapling/gardner.rb
- module dialogue -> lib/sapling/dialogue.rb
- module planter -> lib/sapling/planter.rb

- remove duplicate code from lib/sapling.rb
2017-05-07 12:59:36 -04:00
Bill Niblock
13683a35b4 Update documentation 2017-05-06 18:16:22 -04:00
Bill Niblock
04b52c13fc Repo organizing
- Add doc/ directory, so publishing to gh-pages is a bit easier.
- Update .gitignore to not ignore the doc/ directory.

- Move manual documentation directory into new var directory (var/docs)
- Move example dialogue tree into new var directory (var/trees)
- Update YARD to find manual documentation in new var directory
2017-05-06 18:15:08 -04:00
Bill Niblock
ee682ece5d Update formatting
- README.md: Remove unnecessary copyright line
- docs/config_file.md: Update the example YAML file to actually be proper.
- docs/config_file.md: Expand information to cover entire configuration file.
2017-05-06 18:06:00 -04:00
Bill Niblock
edcccc1869 Update yard docs 2017-05-06 17:41:40 -04:00
Bill Niblock
a10e53d689 .gitignore: Update for YARD 2017-05-06 17:37:29 -04:00
Bill Niblock
c240b494fc Auto-publish docs to gh-pages with yard-ghpages
- Add yard-ghpages to Gemfile
- Create Rakefile with yard-ghpages tasks for publishing to gh-pages
2017-05-06 17:35:37 -04:00
Bill Niblock
c729916f9d Start using Yard
- Add yard to Gemfile
- Configure .yardopts to pull in proper files
- Update custom docs to include yard metadata
2017-05-06 17:34:19 -04:00
Bill Niblock
893c71ea51 Start using Bundler
- Add Gemfile
- Add auto-generated Gemfile.lock
2017-05-06 17:29:47 -04:00
Bill Niblock
19fdb26cb7 trees/example_quest.yaml: Video games!
- Add branch 7, to actually finish the entire tree. Nice!
2017-05-06 16:18:52 -04:00
Bill Niblock
562aeb2437 README.md: Update to most current correct info 2017-05-06 15:39:33 -04:00
Bill Niblock
d02bf204cc CONTRIBUTING.md: Contribution guidelines 2017-05-06 15:39:15 -04:00
Bill Niblock
9cc77d6321 LICENSE: Add MIT license 2017-05-06 15:38:52 -04:00
Bill Niblock
df8a24b506 trees/example_quest.yaml: Finish the quest! 2017-05-06 15:20:17 -04:00
Bill Niblock
ada5787f8d trees/example_quest.yaml: Example Quest! Adventure!
- Example Quest is a meta dialogue, designed to walk the user through
  understanding what sapling is, and how it works.
- Used to be the configuration file example, but now it's all grown up and ready
  for big-boy pants.
2017-05-06 15:13:13 -04:00
Bill Niblock
0e7b80c740 docs/config_file_example.yaml: Self-document!
- Change the example configuration file from a tree to a self-documented
  reference. You can still run it in sapling, but it's pretty boring.
- Moved previous example configuration to "Example Quest", in the trees
  directory.
2017-05-06 15:12:11 -04:00