ADRIFT Game Development Tips

From ADRIFT 5 Manual Wiki
Revision as of 07:04, 8 January 2012 by Saabie (Talk | contribs) (How do i change the auto-completion of words on runner command line)

Jump to: navigation, search

Whats the difference between General, Specific and System tasks?

  • A general task defines a command (verb) and its synonyms. It is used to give the default response and actions to using the command in the game, as well as define restrictions on when the command is not valid, and the responses to give in those circumstances.
  • A specific task is used to change the default response for a command, either for a specific object/character etc. or when specific restrictions are true.
  • System tasks are completely separate from the command parser.
    There are three main uses of system tasks:
    • They can be set to run when a player enters a particular location.
    • An action in another task can execute them like a subroutine.
    • An event can call a system task to perform some actions at a particular time.

How do i change the auto-completion of words on runner command line

If you type 'i' on the runner command line it suggests 'inventory', and pressing the space bar will confirm it.

But if you type 'in', it instead suggests 'inside'. Likewise, typing 's' gives you 'south', but why not 'sit', 'stand' or 'say'?

The word that is chosen is governed by the auto-fill priority setting on the Advanced page of general tasks.

The general tasks for 'sit' and 'stand' in the standard library have auto-fill priorities of 4, 'say' has 2, and Player movement (which matches the word 'south' from the %direction% reference) has a priority of 1.

When the player types 's' into runner, it recognises that they could be trying to type any of these four words, and chooses the one with the highest priority as the one the player is most likely to want to enter.

If the player continues to type letters then this will eliminate any words that dont start with those letters, so runner will display the word with the highest priority from those that do still match.

When you create a new general task it will have an auto-fill priority of 10, which is lower than any of the standard library tasks, so the runner will always choose one of the standard commands over your new one.

If your new command is actually used more often than the command that the auto-fill chooses to display, you can force it to display the new command by changing its auto-fill to a higher priority (smaller number) than the command in the standard library that is currently being chosen.

If you add lots of new commands to your game then all of them will default to auto-fill priority 10, so before you release your game you should play it through to check that the auto-fill is choosing the best option most of the time, and adjust the auto-fill priority so that the most often used commands can be entered with the least amount of typing, while seldom used commands have to be typed in full.

My game has a secret password as a command, but the auto-fill gives it away by displaying it

Just set the auto-fill priority (on the 'Advanced' page of the passwords general task) to zero. This disables auto-fill and prevents that command from ever being displayed.