Jump to content
  • Advertisement
Sign in to follow this  
  • entries
  • comment
  • views

More Prototyping

Sign in to follow this  


Sorry it's been a while since I updated, real life took up most of my time over the last week and a half. I've been refining my design for a prototype, and figured that my progress might be worth posting.

In making the prototype, I've thought about what elements are most important to my concept so that I could focus on something manageable to get up and running. I'm glad that I focused on designing very small chunks of the program, because there are a lot of details that I managed to overlook in the design work I've done so far.

The central aspect of my game is the investigation, so I've started working on that. The keys to the investigation mechanics as I've envisioned them are:

-Every action a character takes must leave some sort of trace behind, whether or not any other character is capable of perceiving and interpreting that trace

-Traces include physical evidence, supernatural evidence, and eyewitness accounts

-Characters need to be able to control how discreetly they carry out actions to influence how many traces they leave, and how much information these traces contain

So my prototype will need to contain characters, some possible actions, locations, and the ability for characters to make observations.

Characters are easy enough since I don't need them to be fully implemented. For now, they just need names (so that they can be easily told apart) and a couple of stats related to observation and concealment.

Traces are more complicated, but they don't need to be fully implemented either. To get started, a eyewitness accounts will be the only trace I deal with. Later on I plan to have a specific container class attached to items, characters, and locations which can hold information representing the other two types of traces.

Variable discretion in carrying out actions is already a part of the action system that I've been working on, so for the prototype it's just a matter of implementing the action system in conjunction with the eyewitness observation system.

For my initial tests, I'm planning on coding a single location, a player-character, and ten NPC's to serve as potential observers. I'll also need some more abstract classes to allow the player-character to define actions, a system for resolving actions, and a system for resolving potential observation. There's obviously a lot more that needs to be done, but this seems like a realistic initial challenge to tackle, and it'll all need to be in place before more features can be added.

For anyone who wants a bit more design detail, I've added a brief overview of the Action and Observation systems, which are a lot more complex than the other (very basic) elements of the prototype. If you're interested, please take a look and leave comments on what you think of the design and my presentation of it.

The action system:

As I layed out in a previous post, my action system will have a grammar-based structure. Only certain combinations of parts of speech are allowed for each action, and only certain types of objects can be used in a given part of speech for a given action.

For example, the Go action requires a destination (the part of speech is an indirect object) and a adverb determining how secretive the character is in moving there. The destination must be a Location object, and the adverb must be from an Enum I've created for this purpose. So a character might choose "{Go} {park} {casually}". I'm calling a completed structure like this an "action-phrase".

Each action-phrase has its own construction screen, which ensures that only appropriate parts of speech are used and also ensures that only appropriate object types are used in each.

Once an action-phrase is constructed it is sent to a function called "ResolveAction", which is part of a static class. ResolveAction takes the Action-phrase as an argument and then parses it by the action chosen (the verb of the phrase, sorted by a switch statement). The appropriate case then calls a specific function which contains the formulae needed to determine whether or not the action is successful.

The observation system:

While resolving an action, checks are made of NPC's in the area to determine whether or not they observe the action, and how completely they do so.

I haven't worked out exactly how the formula for this will work, and anything I choose will have to be tweaked a lot anyhow. But for now, each character in an area has a chance of noticing an acting character.

For each NPC that successfully notices the acting character, additional checks will be made to determine how many details the NPC observes. These details are the components of the action-phrase being resolved. Finally, a combination of how secretively the acting character was behaving and how much detail the NPC noticed determines how strong their memory of the event is.

Any observation made will be recorded in a master list of observations, which represents all of the information that a character could gather by talking with witnesses. Over time, characters will forget details about things that they witness. The rate of this degradation will depend on the strength of the memory. When no characters still recall any detail of an event, it will be removed from the record entirely.

So a completed observation will include:

-The identity of the observer

-The identity or physical description of the character observed

-A copy of the action-phrase that the observer witnessed. The more details successfully observed, the more exactly the observation will reflect the action-phrase being resolved

-A measure of how strongly the observer remembers the event observed

However, for initial tests I'll probably just have a text output state whether or not an NPC noticed the action taken by the player character, and if so print a a dummy version of the observation. I don't think that the master record is crucial at the moment, nor do I expect it to be all that difficult to create once I'm more confident that the observation system is working.
Sign in to follow this  


Recommended Comments

There are no comments to display.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!