How do you make it possible to show health/score?

TheHatMan
The title tells it all, I'm having trouble with my game because it does not show panes (inventory, places and objects, compass) and I still want it to be able to display health and the score (since I'm using score as money). Can someone help me with this? :(

HegemonKhan
you can have it always being displayed or by command~typing_it_in:

always being displayed:

Add a Global (have the upper left 'Object' in the GUI~Editor 's left pane's 'tree of stuff' highlighted, when you choose to add the turnscript rom the top horizontal menu bar ~ or you can just click and drag it after you made it ~ just don't have it under~within an Object) Turnscript, and then add this script to the turnscript:

add a script -> output -> print a message -> [EXPRESSION] -> game.score
add a script -> output -> print a message -> [EXPRESSION] -> game.health

(you may~probably need to add a 'turn' integer attribute too)

'on-command' being displayed:

create~add a Command

command name: show_health_command
command pattern: h // or: health // or: showhealth // or: whatever you want
command script: add a script -> output -> print a message -> [EXPRESSION] -> game.health

command name: show_score_command
command pattern: s // or: score // or: showscore // or: whatever you want
command script: add a script -> output -> print a message -> [EXPRESSION] -> game.score

or do both in one command:

command name: show_stats_command
command pattern: s // or: stats // or: showstats // or: whatever you want
command script: (see below)

add a script -> output -> print a message -> [EXPRESSION] -> game.score
add a script -> output -> print a message -> [EXPRESSION] -> game.health

during playing the game, you'd just need to type in your pattern, and it'll display your health (or: score, or: both)

This topic is now closed. Topics are closed after 60 days of inactivity.

Support

Forums