Author Topic: Survival - Hunger/Thirst/Sleep  (Read 4017 times)

Offline nologgie

  • Non-resident Non-expert
  • Dungeon Craft Tester
  • Hero Member
  • ***
  • Posts: 3465
Re: Survival - Hunger/Thirst/Sleep
« Reply #15 on: June 19, 2011, 01:41:49 PM »
The items displayed in the character's inventory as "Rations: Stage 5", which was a bit wonky, so I hex edited "%s: stage %u" to "%s: %u      " in the engine. It now reads "Rations: 5". (I hope Paul doesn't see this, but old habits are hard to break.  :-[ )

While quest- and special items stages are displayed in the "test mode" (if you start your game from the editor), the values are hidden in "normal mode" (if you start your game directly) if I remember right. I am not sure if this is important here (since I did not completely understand what you did, though it sounds ingenious :) ), but maybe it is something to consider...

D'OH! Yes, it's definitely something to consider because it blows the inventory listing. I should have known it wouldn't be so easy.  :(

I guess using a "non-special" item is the way to go. Food can then have encumbrance so a character can't carry a multi-year supply. An immediate problem I see is the way bundling is handled. The basic item quantity must be greater than one for an item to be bundled, and $GIVE_CHAR_ITEM and $TAKE_CHAR_ITEM give or take the basic quantity. There are ways to get around this, such as assigning a basic quantity of 7 and taking 7 once per week, but it's a pretty obvious flaw.

I played around with renaming jewelry and using it as food, but got nowhere.
Some days it just doesn't pay to gnaw through the straps.

Offline steve_mcdee

  • Dungeon Craft Tester
  • Hero Member
  • ***
  • Posts: 1953
Re: Survival - Hunger/Thirst/Sleep
« Reply #16 on: June 20, 2011, 01:43:34 AM »
We need the ability to add a couple custom events to a pre-scripted event menu like CAMP, TAVERN, SHOP, etc...
This can be done using the question button event. If you need more options than there are buttons, make one of the buttons 'MORE' or 'NEXT' or similar, and have that button chain to another question button event (which should include a 'PREVIOUS' button or similar). In the first event, select 'Return to question' for the 'NEXT' button.

Well, yes ... I think that works well when you are doing non-standard locations/events/menus ... but if you want to incorporate one of the pre-scripted events that have their own menus ... like TAVERN ... then it gets a little clunky ... because the 'MORE' button is really whats calling the TAVERN event ... and the menu options might seem a little unusual for the player ... for instance, for my project I might end up with something like ...

First menu the player sees in a tavern ....

ORDER FOOD | MORE | EXIT

Player clicks 'MORE' ... and gets...

FIGHT | DRINK | LISTEN | EXIT ....

And to go BACK to the last menu, the player clicks on EXIT ... which is very clunky and would confuse ME in a game ...

It would be better just to have the tavern menu be :   FIGHT | FOOD | DRINK | LISTEN | EXIT

Now, with a tavern, I could probably accomplish this by duplicating most functionality in the existing pre-built tavern event with a question event and my own event chains ... so that can be solved ...

But what about when you want to add a button/question to shops? then you get stuck in the clunky method above.

Of course, since thats what I've got ... I'll make it work ... probably do something like have a shop where the menu was "TALK | BUSINESS | EXIT" ... and the 'BUSINESS' button took you to the normal shop event ... of course, having to use the EXIT button to get back to the 'TALK | BUSINESS | EXIT' menu would still be a little clunky ... but we can't have everything.

Still, just thinking, having the option to add like 1 or 2 question buttons to those menus would be nice.

I see what you're saying now; I hadn't quite fully understood before. By the way, you'd be better off using something like "ORDER FOOD" rather than "FOOD" so that you get unique first letters for each button, which allows for hotkeys.

Another thing: in predefined menus, EXIT usually adopts hotkey "X". If the designer uses a Question Button which includes "EXIT" as one of the options, I think this would automatically use hotkey "E". Is there any way DC could be made automatically to use hotkey "X" when the button name is "EXIT"?

Offline arelim

  • Full Member
  • ***
  • Posts: 158
Re: Survival - Hunger/Thirst/Sleep
« Reply #17 on: June 20, 2011, 09:12:55 AM »
I usually use the mouse ... so I hadn't even thought of the hotkey problem. Good thinking.

Offline SilentThief

  • Dungeon Craft Tester
  • Hero Member
  • ***
  • Posts: 891
Re: Survival - Hunger/Thirst/Sleep
« Reply #18 on: June 20, 2011, 12:42:09 PM »
The basic item quantity must be greater than one for an item to be bundled, and $GIVE_CHAR_ITEM and $TAKE_CHAR_ITEM give or take the basic quantity.

Too bad there isn't an option for give/take item that is some kind of toggle for give/take single from bundle.

I played around with renaming jewelry and using it as food, but got nowhere.

Those jewels don't taste too good, do they? Seriously, I haven't tried this since 0.914, but you had access to coin slots via spells attribute affected box but not using scripts. I think coinslots should be accessible from script, but I might be the only one.

ST

Offline nologgie

  • Non-resident Non-expert
  • Dungeon Craft Tester
  • Hero Member
  • ***
  • Posts: 3465
Re: Survival - Hunger/Thirst/Sleep
« Reply #19 on: June 20, 2011, 01:24:27 PM »
The basic item quantity must be greater than one for an item to be bundled, and $GIVE_CHAR_ITEM and $TAKE_CHAR_ITEM give or take the basic quantity.

Too bad there isn't an option for give/take item that is some kind of toggle for give/take single from bundle.

I think allowing the "bundle" switch for all items would be the easiest, and probably most likely, fix.

I played around with renaming jewelry and using it as food, but got nowhere.

Those jewels don't taste too good, do they? Seriously, I haven't tried this since 0.914, but you had access to coin slots via spells attribute affected box but not using scripts. I think coinslots should be accessible from script, but I might be the only one.

ST

I definitely want the coin slots to be accessible via SA scripts. As you said, some manipulation is possible using spell scripts. I don't have a good method for picking a character's pockets yet, but I'm still trying.

Jewels seem to taste much like any other imaginary food.  ;) They can still be appraised and sold, but the appraisal value has dramatically lessened. A low coin slot might also work as long as the rations aren't sold in shops. Otherwise you could buy one and get your change in rations.
Some days it just doesn't pay to gnaw through the straps.

Offline SilentThief

  • Dungeon Craft Tester
  • Hero Member
  • ***
  • Posts: 891
Re: Survival - Hunger/Thirst/Sleep
« Reply #20 on: June 20, 2011, 06:48:16 PM »
Jewels seem to taste much like any other imaginary food.  ;) They can still be appraised and sold, but the appraisal value has dramatically lessened. A low coin slot might also work as long as the rations aren't sold in shops. Otherwise you could buy one and get your change in rations.

Never thought of it like that... it might give you rations as change. When I played with this idea I made the conversion for the "food" (currency) slot at 1000000, as in it would take 1 million rations to equal a copper piece.
While I never had it change out copper for food, it could happen with the conversion process (buy back percentage equaling out to less than a full piece of copper....)

That complicates a simple idea :(

ST