DGSH - a tool for Dungeon Masters

DGSH - the DunGeon Shell
$Id: commands.shtml,v 1.3 2002/08/31 06:38:22 jmettraux Exp $
* home
* features
* installing
* running
* tracking your party
* adding a PC or a NPC
* parsing stat blocks
* some fight
* commands
* scripted commands
* scripted triggers
* javadoc
* data files
* missing features
* mailing lists
* some links
* credits
* download
* dgsh on sf.net
* sources
* contact

The commands of dgsh

When dgsh is running, you can get help for any command by typing help commandName.

Some commands use filter expressed as regular expressions. Before being applied, these filters are always put in lower cases and '_' (underscores) are replaced by spaces. Putting a whitespace directy in the filter will fool dgsh.


ab {targetName} {abilityDefinition} {delta}

Like the hp command but for ability score. Plume The Gnome has been bitten by a silkspider ? Inflict him 1 con temporary damage with ab plume constitution -1. You can remove it the next day with ab plume constitution 1.


alias [alias [command]]

Tired of typing long command names ? use alias x long_command_name, so next time you type x arg1 arg2, long_command_name arg1 arg2 gets called

If you type alias without any argument, a list of the currently set aliases will be displayed.


blog [r[everse]]

Browses the current log. If 'reverse' is stated, will browse in reverse order (recent logs first).


browse [temp|party|opp[onents]]

Displays a list of all the sets in the game session and what they contains. There are two main sets : party and temp. Party (short : p) contains the PCs and their friends, while temp (short : t) contains monster templates (instantiate them with the inst command).
During a combat, a special set is created : opponents (short : o) which contains the adversaries.


carry {beingName} {equipmentLocator}

Put something into a character's bag or pockets.

carry shana ssword and Shana is now carrying that short sword she found on a goblin corpse.


cast {spellCasterName} {spellName} {className}

Simply casts a spell. Prepared spells are consumed as well as spell slots (if your class doesn't require spell preparation, only spell slots are consumed.


charge [creatureName]

This command can only get used during a combat. If the 'creatureName' is not specified, the creature whose turn it is will be considered as the charger.
This method simply adds a 'charge' effect to the creature marking it as 'charging' (+2 att / -2 AC for 1 round).


clock [add {timeString} | set {timeString}]

With no arguments, this command displays the current game time. If you specify 'add', the {timeString} is interpreted and added to the current game time. A timeString example : '1d2h3m4r5s' which is read as '1 day, 2 hours, 3 m inutes, 4 rounds and 5 seconds'


credit {targetName} {{amount}{gp|pp|cp|sp}}*

Adds or remove coins to a character wallet.

For example : credit shana 1gp 10pp -700cp



A list of people involved in making dgsh real and useful.


display {characterName|monsterName|templateName}

display hemgard will display the stats for the PC hemgard (you can find him in p.xml).
You can use this command with monsters, and also monster templates (try and load monsters.xml then d goblin).


drop {equipmentLocator}

drop shana.carried.ssword the short sword wasn't worth carrying around, so she dropped it.


effect {name} {target}*

combat command

Adds an effect during combat, like an entanglement or a bless effect.

for example : effect entangle troudukh plume shana


eqlist [filter]

Lists the equipments currently loaded in dgsh. The names listed here are the one used by the diverse equipment commands (hold, wear, carry)

The optional filter is used to match equipment entries. You can list only swords with eqlist .*sword.*


eval {exec|set} {jython commands}

Evaluates jython commands directly. For more information, take a look at Jython's homepage and at dgsh's javadoc. You can get quite powerful with this command, but a normal usage of dgsh, should NEVER imply a call to this command. If you tend to use this command, then a feature is missing in dgsh and you should drop a few lines about it on the users mailing list.



Quits the dgsh game session.


feet {value}

Translates a feet value into meters. Should be useful for european DMs like me. (Does it the easy way : 5 feet = 1.5 meters)


feats [filter]

Displays the list of feats loaded in dgsh. You can narrow the output by providing a filter like in feats scribe.* which will return 'Scribe Scroll'.


fidef [creatureName]

This command can only get used during a combat. If the 'creatureName' is not specified, the creature whose turn it is will be considered as the defender.
The creature will be marked as 'fighting defensively' (-4 att / +2 AC) for 1 round.



Enters the combat mode. After that, you should load opponents and/or instantiate them, then roll for initiative. Say next and dgsh will display the details of who or what is going to act.


gear {characterName}

Append the name of a character to this command to display the equipment that this character is currently holding / wearing / carrying. The coins and the total load are also displayed.


help {commandName}

Type help and the name of another command to get the syntax and 'manual' of that other command.


hp {targetName} {hpCount} [p[ermanent]]

Add or deduce hit points to characters or monster with this command :

hp hemgard -2 will inflict Hemgard the ranger 2 points of damage.

hp plume 4 will heal Plume the gnome cleric with 4 fresh hit points.

hp troll1 -10 p will reduce the hit points of 'troll1' by 10. He will not be able to regenerate these damages.


hold {beingName} {equipmentLocator}

Tells dgsh that a creature will hold a piece of equipment in hand.



A very important command : it iterates through the friends and the foes to automatically roll initiative for foes and ask for initiative result for friends.
My players enjoy to add their initiative bonus by themselves so dgsh just reminds me of their bonus but doesn't add it to the result I give.


inst {monster template name} [{count} [name prefix]]

6 goblins are embushing your characters ? Want to throw them right into action. Switch to combat mode with fight and then inst goblin 6 gob gob1 and all his brothers up to gob6 will show up in the 'opp' set.

Next step is initiative rolling with init



Displays the initiative table (who plays when).



Displays dgsh's license. Dgsh is released under a classic BSD license.


load {filename} [t[emp]|p[arty]|o[pponents]]

Loads an xml data file or a jython script file (ending with .py or .jy) into dgsh. If you are loading your party, don't forget to end the command with 'p' or 'party'.

When you load a jython script, it gets reinterpreted, so your changes are reflected immediately, debugging is easier... (And of course, you don't have precise a character set for loading jython scripts)


log {text}

Logs a text to the current game session log file (usually 'dungeon.log'). Note that every command you type also goes to this log file.


monsters [filter]

Displays the list of monsters you can 'instantiate' and throw against your party of players.


move {sourceEquipmentLocator} {targetEquipmentLocator}

Moves a piece of equipment from one place to the other.

Examples :

  • move shana.carried.baxe shana.held.baxe
  • move shana.h.baxe troudukh.c



This command is by default aliased to 'n'. Tells you who should play next (of course, initiative must be rolled at the beginning of the fight with init). Next also tells you when an effect ends or what effect it has when its turn shows up (1d6 damage per round).



Use this command to display the opponents currently facing your party.

you can also use its default alias : o.



The same result as opp but with your party of PC.


prepare {characterName} {className}

prepare shana drd starts a spell preparation session for shana.

It's like a small sub-shell for preparing spells.

commands available during preparation :

    - flushes the prepared spell list and resets the spell slots
    - displays the free slots available for preparation
l[ist] {level}
    - lists the spells that can be prepared for a given level
p[repare] {spellName} [d] [count]
    - the spellName can be a regular expression
    - use _ (underscores) instead of space in the spellName
    - you can specify how many times the spell gets prepared with [count]
    - if you flag the command with a 'd' after the spell name, the spell
      will be prepared as a domain spell (if possible).
u[nprepare] {spellName} [d]
    - removes a spell from the prepared ones 
    - flag with a 'd' if the spell is a domain spell
    - displays the prepared spells 
    - quits the preparation mode


ref [subject]

Displays reference texts contained in the subdirectory doc/ and having the '.ref' extension.

For example ref turning will display a small reference text about turning or rebuking undead creatures.

ref alone, displays the various available subjects.

Ref uses some kind of pager for viewing the files :

  • 'u' : pages up one screen
  • 'd' : pages down one screen
  • 'h' : goes 'home' (first page)
  • 'e' : displays last page
  • 'x' or 'q' : quits the ref command



Exits the combat mode and flushes the opponent list.


roll {diceSet}

Type for example : roll 5d6+2

This command is usually aliased to 'r', so r 1d4-1 will be equivalent to r 1d4-1


save {t[emp]|p[arty]|o[pponents] | creatureName} [filename]

Saves your party or the opponents into a file you choose. Be careful not to override important files (like dgsh data files, you've perhaps hacked them with some Eldritch Might). Usually put .xml at the end of the filename.

You can now save a creature in its own file. This is very useful to save each party member to its file :
save delfae pty/delfae.xml


scn [filename]

Allows you to browse the files you put in your scenario directory (by default it's $DGSH_HOME/scn/, but you can set it in dsh-config.xml). Works much like ref


search {dc} [characterName]

Performs an 'automatic' search check with the given DC. If no character name if given, performs the check for everybody in the party (don't bother about results for character you aren't allowed to check).


set [{attributeName} [newValue]]

Sets the value for an environment attribute. Using 'set' without parameters lists the current attributes and their values.
If you give no newValue, the attribute will be removed from the environment.


setinit {character or monster name}

Sets the init score of a character or a monster (useful when one has readied an action or enters the fight).


skills {characterName}

Displays the skills for a character or a monster.


spell {filter}

Is followed by a filter like in spell .*interposing.*. Displays all the stats for the first spell that matches the filter.


spellbook {characterName}

Displays the spellbook of a character.


spells [filter|{level} {className}}]

Lists the spells loaded in dgsh. You can use a filter so all the spells don't get displayed together. Try spells .*bigby.* to display all the Bigby suite.

You can also display spells by class and level like this : spells 1 wiz.


sub {targetName} {hpCount}

Adds or remove subdual damage points to a character or a monster. Remember that subdual damage points are lost at a rate of 1 pt per hour per level.


fidef [creatureName]

This command can only get used during a combat. If the 'creatureName' is not specified, the creature whose turn it is will be considered as the defender.
The creature will be marked as on 'total defense' (+4 AC) for 1 round.


transfer {name[*]} {fromSet} {toSet}

This command can get very useful if you've loaded your party into the 'temp' array, try transfer * temp party or transfer * t p and your adventurers will be back.


treasure {level}

Rolls a random treasure for a given level. By default aliased to 'trs'.

The random tables can be found in dgsh/etc/tables/



Displays the version of dgsh you are using


wear {beingName} {equipmentLocator}


xp {count} [target]*

Adds or remove xp to the party or only to certain characters.

Scripted commands

These commands are class related, so I didn't make them part of the dgsh standard commands. They are so implemented in jython, you can find their implementation in etc/scripts/ (and hack them if you like).

For example, the 'rage' command is tied to barbarians so if you look at the data file etc/classes.xml, you will find just before the xml representation of the barbarian class, a reference to etc/scripts/barbarianRage.py which contains the code for the rage command.


rage {barbarianName}

Pass the name of a barbarian as unique argument to this command and this barbarian will start its rage.
At the end of the rage, the barbarian will automatically depress.

$Id: commands.shtml,v 1.3 2002/08/31 06:38:22 jmettraux Exp $

hosted on SourceForge Logo and