Basically, I am trying to rework computers so that they can be loaded through json. It’s getting fairly close to a releasable condition, so I am submitting it here for everyone to review and tell me what I’m missing. One of my big worries right now is that a lot of this work is in the context of how the current computer system works, so I’m probably missing out on a lot of exciting possibilities without more outside input.
Requesting Input on These Items:
[ol][li]As designed, all failure actions trigger in the event of one security check failure. Should failure actions be associated with a specific check? Further, should there be support for failures as a combination or a distribution, allowing for things like critical failures, etc.?[/li]
[li]Right now this is a ton of json, even without things like distributions and associations, one idea I had was to use templates to simplify a lot of this code. What sort of templates should be supported?[/li]
[li]Did I miss any security check types or action types? Any potential for combination and reducing complexity here?[/li]
[li]Should the computer option prompts include what is necessary for the security checks, or should that be the responsibility of the creator to include?[/li]
[li]LUA. Does anybody use it and want support for it added?[/li][/ol]
Major Changes:
[ul][li]Loadable through json[/li]
[li]Multiple computers per submap (rotation needs work)[/li]
[li]New computer actions (in work)[/li]
[li]Maintain support for hardcoded actions[/li]
[li]Load hardcoded actions through json (in work)[/li]
[li]Various bugfixes[/li][/ul]
How it Works:
New json addition to map code, “place_computers”, takes x,y location, name, prompt, and set of options. Each option contains a prompt, a set of security measures, a set of actions to take on security check pass, and a set of actions to take on a check fail.
When accessing a computer, each option’s prompt is displayed. Selecting a prompt triggers the security checks, which in turn trigger the applicable set of actions.
Security Checks:
Password - Parameters: password - Requires a password to log in. Will have to include the password in an accessible terminal or on an item somewhere to be used.
Item - Parameters: item name, item count, consume - Requires a set amount of items to log in. May consume the items or not.
Hack - Parameters: difficulty - Requires successful computer skill check to log in.
Trait - Parameters: trait name - Requires player to possess a certain trait.
Pass or Hack - Parameters: password, difficulty - Requires either a password or a successful hack attempt.
Trait or Hack - Parameters: trait name, difficulty - Requires player to have the trait or pass a hack attempt.
Item At - Parameters: location, item name - Requires an item to exist at the specific location. May roll this into Item.
Container At - Parameters: location, watertight, software, empty, contents - Requires a container to exist at the specific location. If watertight, requires a liquid container. If software, requires a usb drive (currently, may be adapted to include SD card, PDAs, etc). If empty, requires the container to be empty. If contents are set, require the contents to be in the container. Also may roll this one into item.
Skill Check - Parameters: skill name, difficulty - Require passing a generic roll of a specific skill and difficulty.
Actions:
Change Terrain - Parameters: location, terrain - Changes the terrain at the location to the specified terrain.
Message - Parameters: message - Display a message on the computer display window.
Change Level - Parameters: number of levels - Changes z-level.
Noise - Parameters: volume, description - Makes a sound with given volume and description.
Spawn Monster - Parameters: location, monster - Spawns a monster at given location.
Spawn Item - Parameters: location, item - Spawns an item at given location.
Fill Container - Parameters: location, contents, charges - Places number of charges into container at location with contents.
Reveal Map - Parameters: z level, radius, terrain types (optional) - Reveals circular area of map at z level with given radius, specifically the given terrain types if given.
Add Trap - Parameters: location, trap - Adds the specified trap at the location.
Remove Trap - Parameters: location - Removes trap at location.
Add Field - Parameters: location, field, density - Adds specified field with given density at location.
Remove Field - Parameters: location, field (optional) - Removes all fields at location, or just specified field if given.
Explode - Parameters: location, power, shrapnel, start fire - Creates an explosion at location with specified power and shrapnel levels, and whether it starts a fire or not.
Kill Monsters - Parameters: top left location, bottom right location - Kills all monsters in a rectangular area.
Disease - Parameters: disease name, duration - Adds a disease to the player for a duration.
Pain - Parameters: min, max - Givens player random amount of pain in range.
Event - Parameters: location, event type, when to trigger, faction association - Triggers a given game event centered on location, at the time, and with certain faction association.
Cascade - Parameters: - Trigger resonance cascade. (May be removed)
Nuke - Parameters: - Trigger nuclear missile targeting. (May be removed)