Walkthrough Question ^_^ [Solved]

How do I invoke/do the Walkthrough via a Menu Choice in the game?

Anonynn.


Hello!

I don't think you can do it from within the game.

I think it's the desktop player that handles the walkthrough, sending each command into the game, one by one.


if this is still about doing the selection of random choices for your character creation, here's a simple but "poor/messy/non-efficient/non-elegant-fancy-advacned" (and a bit tedious, depending on how big/long your character creation code is) way to implement it:

just copy your character creation code, and then edit it, so that instead of it allowing the person playing the game to input a choice/selection, you have it randomly selecting a choice instead

and, of course have code, for the person playing the game, to select whether to use this 'random character creation' code with it randomly selecting their character stuff, or to do the normal character creation code with them customizing/selecting their character stuff


also, since this is the automatic random selecting of character stuff, you have NO need/reason for displaying the menus and/or questions, as everything is going to be randomly selected anyways, so you can remove all the displayment of choices and/or prompting of questions to the person playing the game, from this copy and edited and new 'random character creation' code, unlike the normal character creation code which does need this stuff as the person playing needs to know what character creation stuff he's/she's to select, of course


again the basic code line for randomly selecting a choice from a list (can do a dictionary too, but too lazy to get into it, as it's a bit more complex), an example:

player.STRING_ATTRIBUTE_OR_OBJECT_REFERENCE_POINTER_ATTRIBUTE = ListItem (LIST, GetRandomInt (0, ListCount (LIST) - 1))

so, you'd do this for all of you menu choices in your copied character creation code


if you have non-string (non-menu) inputs (Integers, like the character's age/height/weight/etc for example) to do, then its even easier, just do the:

player.INTEGER_ATTRIBUTE = GetRandomInt (MIN, MAX)

if you're working with Doubles (floats / floating-points / decimal / fractional numbers) and thus likely doing more complex mechanics, while not going to get into the all various game mechanics/equations/formulas/methods that you can do, the code line for them is:

RANDOM_DOUBLE_FROM_0.1_TO_0.9 = GetRandomDouble ()

if you want to randomly 'select or not select' something, then you can just use this, an exmaple (using '50%', but you can put in whatever 0-100 number you want for the percent chance of selecting vs not selecting):

if (RandomChance (50)) {
  player.ATTRIBUTE
  // or: player.ATTRIBUTE = VALUE_OR_EXPRESSION
}
// optional: else

Heyo!

I appreciate the feedback! I tried a couple of different methods of trying to get the walkthrough to appear as a choice but that didn't work (I tried before reading the responses) xD So I just created new individual functions that ran through a series of RandomChances
50
33
25
20
16
etc
If you guys need to see the code though to help anyone doing it in the future let me know ^_^ And again, I super appreciate the help and feedback!

Anonynn.


Log in to post a reply.

Support

Forums