Commit Graph

40 Commits (4c5dfac952ece858c8e8ff0769069216c541dd57)

Author SHA1 Message Date
Nicolas Hake 4c5dfac952 Remove or use unused variables in Objects, System 2018-07-24 14:19:26 +02:00
Maikel de Vries a4d20d79d5 cable cars: extend order interface and let producer order more components at a time 2018-04-16 11:13:32 +02:00
Maikel de Vries 1e060d6124 cable cars: improve deliveries and producer requests fuel 2018-04-12 09:21:00 +02:00
Maikel de Vries a70ab8b843 cable cars: let steam engine request coal when needed 2018-04-01 20:54:12 +02:00
Mark ee0917d7e8 Fix #1951: Disabled putting water in airplane and lorry
Removing liquid collection from the lorry is a side effect, but it is not bad. The lorry behavior was weird anyway, because you could for example put lava and wood in it, without the wood burning etc.
2017-12-29 12:59:36 +01:00
Clonkonaut 808e7fa866 Producer: allow construction material substitution for products via script.
All item can now define substitute components like this:
public func GetSubstituteComponent(id component)
{
	if (component == Rock) // Rock is in the regular components
		return Metal; // Rock can be replaced by Metal, amount is the same

	if (component == Wood) // Wood is in the regular components
		return [Cloth, Wipf]; // Wood can be replaced by either Cloth or Wipf, amount is the same
}
2017-10-27 13:19:59 +02:00
Clonkonaut 3c87d0f135 Work save regarding cable cars/lorries.
Started to work on a few station configuration options and combining these with producers for requesting materials (which now kind of works).
2017-10-04 01:19:46 +02:00
Maikel de Vries 42c8dbc2c8 make producer continue directly after production finishes 2016-12-25 17:48:07 +01:00
Clonkonaut afc565a419 Re-enabled automatic bucket emptying (#1867). 2016-12-18 00:50:35 +01:00
Maikel de Vries 7ef0fc5568 don't let producers empty extra slots (#1864) 2016-12-16 21:37:47 +01:00
Mark d356d9db3d Fix inherited() calls
The ... operator should be added so that the parameters are passed down. In some cases even the named parameters were not passed down.
2016-11-26 18:57:31 +01:00
Sven Eberhardt 5db45c0f47 Merge branch 'master' into qteditor 2016-08-06 21:45:19 -04:00
Clonkonaut 48b5f27f14 Fix effect removal of 'IntUpgradeProductProgressBar' when closing the interaction menu of a producer (#1796). 2016-07-25 17:42:15 +02:00
Sven Eberhardt 58faf41068 Sequence: Add more triggers.
* Player enters circular region
* Game starts (after player joins)
* Player joins
* Player removed
* All goals fulfilled
* Clonk death
* Construction of structure
* Production of item
2016-07-22 01:51:29 -04:00
Mark e1413a941d Producer: Commented out log output
This was there for debugging purposes only.
2016-06-01 20:42:03 +02:00
Mark ffcbdc7fd0 Fixed producers unit test #7
The problems here were:
- the foundry cannot take 400 water from ice if it has a fill limit
- the pump cannot pump anything into the object if it has no fill limit
2016-06-01 19:10:46 +02:00
Maikel de Vries e92e7a2e2c fix producer components call after liquid_container branch merge 2016-05-21 13:34:34 +02:00
Maikel de Vries 1df322b7ff adapt objects and scenarios to new component implementation 2016-05-21 13:34:34 +02:00
Mark 52542d7977 Refactoring: Liquids: Removed GetLiquidID() and changed CreateLiquid()
CreateLiquid() can be called from definition context now, to create a certain amount of liquid.
2016-03-25 19:34:36 +01:00
Mark db061b5cad Refactoring: Simplified script.
Unit tests still pass.
2016-03-25 16:31:17 +01:00
Mark b491260fac Refactoring: Producers: Removed another special case from IsCollectionAllowed()
This special case was handled by the fact that liquid items are components anyway, and the ice object is handled differently.
2016-03-24 22:26:09 +01:00
Mark 0ef237988e Refactoring: Producers: Removed special case in IsCollectionAllowed()
The special case can be handled in RejectCollect(). Unit tests passed.
2016-03-24 22:20:55 +01:00
Mark ff89f337de Refactoring: Producers: Readability
Renamed some parameters and variables
2016-03-24 22:16:08 +01:00
Mark 29870b5e6d Producers: Code formatting 2016-03-24 21:28:09 +01:00
Mark fc3d6a69f0 Producers: More unit tests for basic operation
Added tests for adding to the queue and clearing the queue. The other tests are dummies for now. Found out that the parameter 'abort' in ClearQueue() was never used.
2016-03-24 18:27:23 +01:00
Mark 18ad5894e2 Producers: Producers can convert ice to water
This special case is a relic, because I do not know whether this is actually a use case that is required in a scenario. All unit tests in the producers test pass now.
2016-03-24 16:19:15 +01:00
Mark 2e3a984b20 Producers: Fixed objects with liquid need
Liquids are handled as objects now, so that the function GetLiquidNeed() in the objects is obsolete. Adjusted the collection function accordingly.
2016-03-18 06:35:44 +01:00
Mark 072f599cdb Refactoring fuel: Removed the 'get_partial' parameter.
This was used inconsistently and without regard to correctness, so it is better removed altogether. In case of incomplete objects, the incomplete object always returns the reduced amount.
2016-03-01 17:19:39 +01:00
Mark 4f19651f0e Removed liquid need objects 2016-03-01 06:58:16 +01:00
Mark 3591681f32 Liquid objects: Removed check liquid logic from producer
The liquid objects cannot be converted from one to another. The fuel object will be removed again, it does not make sense that "burnt fuel" can be transferred from one object to another.
2016-03-01 06:47:12 +01:00
Mark 7561779d8c Producers handle fuel and liquid with liquid objects 2016-02-27 15:04:37 +01:00
Mark 9b17e41900 Liquid objects: Adjusted producer 2016-02-16 21:08:14 +01:00
Mark da87ac2d69 Bugfix: Called wrong function 2016-02-16 21:08:04 +01:00
Mark 7707c7237e Producer: Liquid can be extracted from the producer itself 2016-02-16 21:07:55 +01:00
Mark 6f557520e8 Refactoring: Renamed Set/GetLiquidName to Set/GetLiquidType 2016-02-16 21:02:09 +01:00
Mark 9d17cff91e Refactoring: Removed old barrel functions
Replaced old barrel functions with the liquid container library calls
2016-02-16 21:01:59 +01:00
David Dormagen 5f25baa058 producers: show progress of current product (#1549)
This is solved via another entry in the production menu (below the products), which is updated by an effect, that is being told the menu ID/target by the interaction menu through a callback.
This setup allows for very intrusive changes to the interaction menu with only few lines of code!
2016-01-20 10:36:50 +01:00
Maikel de Vries 82b090c7ca producer library does not request power if producer is not a consumer (#1602) 2016-01-12 22:17:41 +01:00
David Dormagen 8d9d3a1ef9 producer: use infinity symbol instead of text "always"
After some testing, the text turned out to be the worse solution. At least Sven complained that the text was split into two lines on his resolution from 1997.
2015-12-11 20:42:15 +01:00
Maikel de Vries 004bd3c59e move structure related libraries to separate subfolder 2015-11-28 15:40:25 +01:00