Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  

Author Topic: If something is set to repeat, then do not delete it?  (Read 499 times)

The-Moon

  • Bay Watcher
    • View Profile
If something is set to repeat, then do not delete it?
« on: March 12, 2008, 12:22:00 am »

Or make a option that repeats, but does not remove the order no matter what, unless you tell it too.

I would like to keep my brewery's set to brew drinks for ever. I don't want to have to remake the order every time we run out of barrels, in a minute theres going to be about 5 barrels free from the drink pile alone... hehe

Im assuming this is planned, but if not then i suggested it anyways. If you have this planned already toady, disregard this thread and delete it.

Logged
There is absolutely no time, to be taking time for granted. ~Busta Rhymes

Mephansteras

  • Bay Watcher
  • Forger of Civilizations
    • View Profile
Re: If something is set to repeat, then do not delete it?
« Reply #1 on: March 12, 2008, 12:48:00 am »

Yeah, that'd be pretty nice.

In the meantime, just queue up a bunch of Brew Drink orders at the job manager screen. I usually have about 3 batches of 30 queued up at any one time. Takes them a long time to go through that, and the job manager will automatically reschedule canceled jobs until they're complete.

In fact, I have most of my jobs scheduled through that screen. Just makes life easier.

Logged
Civilization Forge Mod v2.80: Adding in new races, equipment, animals, plants, metals, etc. Now with Alchemy and Libraries! Variety to spice up DF! (For DF 0.34.10)
Come play Mafia with us!
"Let us maintain our chill composure." - Toady One

Tamren

  • Bay Watcher
  • Two dreams away
    • View Profile
Re: If something is set to repeat, then do not delete it?
« Reply #2 on: March 12, 2008, 01:26:00 am »

The problem with repeat orders is that if they are NOT deleted then the game crashes with an endless loop of "job impossible" messages. Probably anyway, my knowledge of the system and similar bugs points in that direction.

One of way of fixing this I proposed quite a while ago was to add an order to the managers menu. Basically its not about ordering up 30 odd items. Instead the manager issues a standing order for a specific item to be produced when stocks reach a certain level.

So if you set it to something like "make booze if ingredients >20" then orders for booze to be made would be sent out periodically until the amount of ingredients drops below 20. If you set it to >0 then any and all available ingredients will be turned into booze automatically.

Logged
Fear not the insane man. For who are you to say he does not percieve the true reality?

Slappy Moose

  • Bay Watcher
    • View Profile
Re: If something is set to repeat, then do not delete it?
« Reply #3 on: March 12, 2008, 09:34:00 am »

quote:
Originally posted by Tamren:
<STRONG>
One of way of fixing this I proposed quite a while ago was to add an order to the managers menu. Basically its not about ordering up 30 odd items. Instead the manager issues a standing order for a specific item to be produced when stocks reach a certain level.</STRONG>

Wow, make a thread for that.

I would totally endorse that!

You could do all kinds of stuff with that: keep booze or food levels at at least 20, make sure you always have 50 crafts to trade, make sure your marksdwarves have at least 30 extra arrows laying around...

MAKE A THREAD SO I CAN YELL AT EVERYBODY BECAUSE THATS A ReALLY GOOD IDEA!

Logged
Zaneg Thazor: Armok Reincarnate Story http://www.bay12games.com/forum/index.php?topic=19291.msg196691#msg196691

[Healthcare Update Thread] Personally, I can't wait for doctors to get possessed and start surgically attaching axes to champion soldier's arms.

JustinKace

  • Bay Watcher
    • View Profile
Re: If something is set to repeat, then do not delete it?
« Reply #4 on: March 12, 2008, 05:28:00 pm »

Even just having the job queue auto-suspend would be better than the jobs deleting themselves.
Logged
K

Draco18s

  • Bay Watcher
    • View Profile
Re: If something is set to repeat, then do not delete it?
« Reply #5 on: March 12, 2008, 06:20:00 pm »

quote:
Originally posted by Slappy Moose:
<STRONG>Wow, make a thread for that.</STRONG>

It's around somewhere already.  I think there are actually 2 threads where it was discussed.

Logged

Forumsdwarf

  • Bay Watcher
    • View Profile
Re: If something is set to repeat, then do not delete it?
« Reply #6 on: March 13, 2008, 12:56:00 am »

Suggestions in this category have been offered many, many times.

The key issues were two:

First, an "Auto-task" option for all workshops, not just weaving and tanning, where the task is automatically performed when it can be but ignored otherwise.

Second, an inventory-sensitive option for manager orders.  One guy actually thought of linking stockpile inventory levels to production orders, which was pretty clever.
But the real meat is having some kind of inventory-to-production-order pathway.  "Carve 30 bone bolts on condition [bones > 40]", "Make Ash on condition [ash < 40]", etc.

Logged
"Let them eat XXtroutXX!" -Troas

Shurikane

  • Bay Watcher
    • View Profile
    • http://www.shurikane.com
Re: If something is set to repeat, then do not delete it?
« Reply #7 on: March 13, 2008, 09:14:00 am »

Signed.  We need a functionality like that.  Would drastically reduce micromanagement and recurring thirst/hunger problems because the job cancel got drowned out by a bunch of other messages at the same time.
Logged

briktal

  • Bay Watcher
    • View Profile
Re: If something is set to repeat, then do not delete it?
« Reply #8 on: March 13, 2008, 09:39:00 am »

I'd love to be able to turn on auto process plants, auto brew and auto cook instead of a) having to manually add them whenever I notice they need to be done or b) have constant job cancelled spam from manager tasks
Logged

The-Moon

  • Bay Watcher
    • View Profile
Re: If something is set to repeat, then do not delete it?
« Reply #9 on: March 13, 2008, 09:40:00 am »

Sounds like you guys are talking about having a option to make in game scripts for jobs and tasks.

Which i fully support that.

Logged
There is absolutely no time, to be taking time for granted. ~Busta Rhymes

zagibu

  • Bay Watcher
    • View Profile
Re: If something is set to repeat, then do not delete it?
« Reply #10 on: March 13, 2008, 11:01:00 am »

That would be great, yeah. But are there any complex conditions for starting jobs that justifies a full-blown script language, or do we just need a lower limit on stock supplies?
Logged
99 barrels of beer in the pile
99 barrels of beer!
If some dwarves know the way to the pile
0 barrels of beer in the pile!

Shurikane

  • Bay Watcher
    • View Profile
    • http://www.shurikane.com
Re: If something is set to repeat, then do not delete it?
« Reply #11 on: March 13, 2008, 05:25:00 pm »

I don't think it would be all that hard to implement.  For optimization's sake, the if clause would be run only every X amount of frames so the game world doesn't get queried all the time.

So let's say you want a persistent production of blocks.  Every, say, hour in DF time, the game would run something algorithmically akin to:

If Stone.Amount > 0 && Production == False Then
     Make Block;
     Production = True
End If

The job would be set to repeat until there is no more available stone.

Once this happens, the Production variable gets reset to false and the workshop goes into listening mode again, waiting for stone to become available.

Logged

Exponent

  • Bay Watcher
    • View Profile
Re: If something is set to repeat, then do not delete it?
« Reply #12 on: March 13, 2008, 05:33:00 pm »

quote:
Originally posted by zagibu:
<STRONG>That would be great, yeah. But are there any complex conditions for starting jobs that justifies a full-blown script language, or do we just need a lower limit on stock supplies?</STRONG>

I can think of one.  I would like to use seeds and plants for cooking, but I don't want to run out of seeds (and I don't want to cook too many plants if I need to get seeds out of them instead).  So I'd like to be able to cook until my seed/plant quantity fell below a certain amount.  So while the original idea was to perform activity X that creates item Y as long as item Y was below a certain quantity, I'd like to perform activity X that creates item Y as long as item Z is above a certain quantity.

It's not absolutely vital, but if we're thinking about expanding in this sort of direction, this would be one of the first tasks that I'd like it to be capable of handling.

As for simply not cancelling a repeat job, I think I'd be satisfied for now if we could simply specify some value greater than 30 in the manager menu.  Like in the thousands or millions.  Something that isn't going to run out anytime soon.  I can't imagine how that would require any complex programming, or result in any unwanted side-effects.  At worst, the save file would have to store 2 (or 4) byte values instead of 1 byte values for job quantities.  There could always be some problem that I'm missing, though.  30 seems like an arbitrary (and arbitrarily low) number, but maybe it was in fact chosen for a reason.

Logged

Draco18s

  • Bay Watcher
    • View Profile
Re: If something is set to repeat, then do not delete it?
« Reply #13 on: March 13, 2008, 05:36:00 pm »

quote:
Originally posted by Exponent:
<STRONG>I can think of one.  I would like to use seeds and plants for cooking, but I don't want to run out of seeds (and I don't want to cook too many plants if I need to get seeds out of them instead).  So I'd like to be able to cook until my seed/plant quantity fell below a certain amount.  So while the original idea was to perform activity X that creates item Y as long as item Y was below a certain quantity, I'd like to perform activity X that creates item Y as long as item Z is above a certain quantity.</STRONG>

If cooked_food.amount <200> 100, then
make fancy_meal

Logged