Skip to main content

A simple TextRPG which uses the 1d6 RPG backend module for character management and interaction.

Project description

Information: http://rpg-1d6.sf.net


Usage:
- ministory_helper.py
Test the ministory (a testcase for the textrpg module)
- textrpg.py
Start the internal test story of the textrpg.

Plans:
- Simple to use functions in easy to read scriptfiles in the style of the ministory file.
- char.compete(other, skill_name) -> See who wins and by how much.
- a basic implementation as minimal api reference for anyrpg plugins.
- Add the basic scripting function "python_interpreter(startup_data)", which shows an interactive python interpreter with the startup data already entered and interpreted.


Ideas:
- Lazy loading modules, to be able to print stuff at once without having to print before the imports.


Basic design principles for the scripting language:

- The action is character centered wherever possible and useful.
-> char.say(text) instead of dialog(char, text)

- Anything which affects only one character or any interaction between only a few characters which is initiated by one of them gets called from the character via char.action().
-> char.compete_skill(char2, skill_name) instead of competition_skill(char1, char2, skill_name)

- Anything which affects the whole scene, or a whole group of not necessarily interacting characters gets called as basic function via action() or as class in its own right via class.action().
-> save([char1, char2]) instead of char1.save() char2.save()

- The seperate class way should only be chosen, if the class can feel like a character in its own right and needs seperate states which may or may not be persistent over subsequent runs.
-> For example AI.choose_the_way(players_answer) or music.action()

- Data should be stored inside the chars wherever possible. If a script gets started with the same character again, the situation should resemble the previous one as much as possible, except where dictated otherwise by the story_helper.
-> char.save() instead of 'on quit' store_char_data(char) + 'on start' load_char_data(char)

- Actions should be written as verb_noun or simply verb.
-> char.say() and char.compete_skill() instead of char.text() and char.skill_compete()

- In the story function, an action is a parameter of the story.
-> story(switch_background_image="bg_image.png")

The code for the TextRPG can be found at U{http://freehg.org/ArneBab/textrpg}



Changes:

textrpg 0.4.8 (2008-10-24)

- FIX: char.say() now uses autoscrolling, too.

textrpg 0.4.6 (2008-10-23)

- Improved shell output by using sys.stdout.write() instead of print (thanks to AKF).
- German tutorial: Character creation chapter added.
- Added scrolling text (char by char).

- FIX: textrpg example code now uses story() instead of the low level diag() function to output text.

textrpg 0.4.4 (2008-09-28)

- Added docstrings to the basic textrpg functions (they were missing after the last large refactoring).

textrpg 0.4.2 (2008-07-21)

- Added a simple_ story.py (originally written for a german python forum)
- yaml is now distributed with TextRPG.
- FIX: Textlines were getting joined if the user pressed enter multiple times
in a short time.

textrpg 0.4.1 (2008-07-09)

- Added a branching story, walking through darker woods.

textrpg 0.4 (2008-07-09)

- FIX: Installed versions didn't find the modules in rpg_lib.
- Added german tutorial chapter 1 and 2: "telling and testing" and "asking users and distributing stories".
- Moved the basic modules into the rpg_lib directory.
- Raise Exception in anyrpg, if some helper function gets used which isn't implemented in the specific module
- Turned all basic functions into wrappers for class methods, so a change of them affects every other basic function.

textrpg 0.3 (2008-07-07)

- FIX: Answering Yes in battle screen didn't work.
- Now experience is spent incrementally (one point per step).
- Added char.check_skill(name_of_skill).

textrpg 0.2:

- FIX: Installation required Changelog.txt which isn't distributed.

textrpg 0.1:

- Added give_exp() function for scripts which calls the experience "screen".
- Renamed ews package to textrpg_1d6 to avoid clashes with possibly installed ews module -> useful while also working on the backend.
- Fertigkeiten now get increased by related attributes. Which attribute is related must be declared explicitely.
- Added fighting styles: defensive and attack head.
- Show base TP in battle stats.
- A bit more 'you did great' output if at least 9 battles were won and the character lost afterwards.
- The player is prompted to decide on a battle strategy/style each round.
- The experience can also be increased by simply saying char.exp = new_value. If the new value is lower than the current value, nothing happens, but it gives the return value False.
- exp is now a property, and so it wil always be up to date.
- added ministory scripting example.
- simpler scripting added.
- Prepared localization of most internal strings.
- Text output and documentation update.
- Ask whenever the round is for the player which action to take and many smaller changes (i.e.: tabs to spaces).
- Added interface for different fighting styles and a hit treshold (below which the character evades the attack or the attack hits the shield).
- Nicer Experience 'screen'.
- Nicer battle output and output, when a skill got raised.
- upgrade now returns what it did: (obj before, obj after).
- Begun writing the TextRPG.

- FIX: Damage for own attacks except the first wasn't printed.
- FIX: empty attributes to attribute dict problems -> turned attributes into a property.
- FIX: persistent game states didn't work due to a version management bug (workdir had not been changed everywhere).
- FIX: corrected dieing.

ews 0.1

- created ews as rpg backend package.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

TextRPG-0.4.8.tar.gz (1.6 MB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page