Commit Graph

343 Commits (3b0891ba89f7a75f832032036a6aefa2573e325d)

Author SHA1 Message Date
Mark 350088525c Refactoring: Stackable: Use InitialStackCount() where it makes sense 2016-03-08 06:57:53 +01:00
Mark d8a68f5655 Stackable: Unit test for stacking finite and infinite objects 2016-03-08 06:48:34 +01:00
Mark fe5e1bc581 Stackable: Unit test for infinite stack count, basics.
Found a bug: An infinite stack gets removed if you take the entire stack at once.
2016-03-07 17:47:49 +01:00
Mark 45fbc64254 Stackable: Remove obsolete objects. 2016-03-07 06:53:08 +01:00
Mark c7fc982d3e Stackable: Unit tests for the use cases from the stackable documentation. 2016-03-07 06:40:27 +01:00
Mark 8573ed9745 Stackable: Unit test for deeply nested extra-slot objects 2016-03-07 06:13:44 +01:00
Mark df04c2c9c1 Stackable: Unit test 9
Stack objects into a container with non-extra-slot containers.
2016-03-06 21:44:57 +01:00
Mark 4101dc7600 Stackable: Additional test scenarios for unit test 8 2016-03-06 21:30:57 +01:00
Mark d86fe2549d Stackable: Unit test for TryPutInto() with empty containers.
First part of a series of tests. TryPutInto() has to be tested with several container types.
2016-03-06 21:04:28 +01:00
Mark e92f5b6bf9 Stackable: Better logging in unit test
Also corrected some minor details in the test logic, related to InitialStackCount() and MaxStackCount().
2016-03-06 06:49:57 +01:00
Mark 258f3d3b3b Stackable: Unit tests for Stack() and TryAddToStack() 2016-03-04 17:46:24 +01:00
Mark ec35a11013 Stackable: More unit tests
Tests for CalcValue() and TakeObject(). Testing the behaviour in combination with containers that have an extra slot is necessary.
2016-03-04 06:57:47 +01:00
Mark e8b6fda751 Stackable: Unit test
First unit tests for the stackable library
2016-03-03 23:01:52 +01:00
Mark 96e59a0626 Failed attempt at unit test nr. 6 2016-03-03 22:10:10 +01:00
Mark 3c05d53b3a Liquid objects: Added unit test 5 2016-03-03 17:20:58 +01:00
Mark 1786f5b3d9 Liquid objects: Fix unit test, Stackable
Addedv debugging logs, will remove them once all unit tests work. The stackable library function "TryPutInto" was changed slightly.
2016-03-03 17:10:43 +01:00
Mark a7ed516c39 Refactoring: Liquid container
The liquid container library was severely reduced by the changes that the liquid objects bring. The remaining unit tests nearly work.
2016-03-01 22:29:35 +01:00
Mark 0a77b58b6a Steam Engine: Use fuel as liquid, finished
The pump was blocked, because the steam engine did not insert enough material
2016-02-27 14:35:38 +01:00
Mark 7894fb0fc6 Steam Engine: Use fuel liquid, Work in progress 2016-02-27 12:41:46 +01:00
Mark 351e61832c Liquid Container: Fixed liquid objects remaining in existence after test. 2016-02-26 22:38:38 +01:00
Mark 55401f88e3 Liquid object: Fixed unit test 12
Added test for filling an empty barrel partially
2016-02-26 15:42:54 +01:00
Mark 79df36eb6b Liquid object: Refactored object entering system.
Unit test 3 still fails, because the functions are not runtime overloadable. Test 12 fails, because liquid transfer does not work correctly yet. This fill be fixed in the next checkin.

Added debug logging, this has to be removed again later.
2016-02-26 15:19:41 +01:00
Mark af6a31c489 Merge remote-tracking branch 'master' into liquid_container 2016-02-20 21:17:59 +01:00
Mark 862e69655e Liquid object: Test for liquid leaving the container 2016-02-20 21:10:41 +01:00
Mark 7cc88bd909 Liquid Object: Simplified transfer into liquid container.
Unfortunately, now the object is not actually transferred, but removed, and a new one is created or an existing one is filled in the liquid container. The logic could use a rework actually, because everything was more clear when the container stored things in variables.
2016-02-20 21:00:48 +01:00
Mark 9e46d752a9 Liquid Object: Unit test for entering liquid containers
The tests handles the entrance of liquid objects into the container. Will look to simplify the script in the next commit.
2016-02-20 20:14:19 +01:00
Maikel de Vries 46e18f5f9f kill tracing: add test for bomb arrow tumble kill 2016-02-19 22:13:09 +01:00
Mark 8c578931bb Liquid Object: Replaced liquid container logic
The liquid container now stores liquid objects, instead of volume and liquid type. Liquid objects can have be of a specific type, such as Liquid_Water, Liquid_Oil, etc..., but they can also just stay Library_Liquid for other liquids.
The liquid container logic has become more complex now, but still works as before. Transferring liquids to other objects may still need some improvements:
- at the moment, transferring liquids between liquid containers is possible
- maybe liquids objects, such as oil, can enter a liquid container while another liquid is in that container already - will need a unit test for that
- transferring liquid from a liquid container to a structure or crew member should be possible (but is not yet), if the target is not a liquid container but contains liquid containers
2016-02-19 06:53:44 +01:00
Mark 1dbb81554d Refactoring: Removed the flagpole from power system test #21 2016-02-16 21:07:50 +01:00
Mark 6f7152eba6 Fixed bug in barrel stacking and added a unit test for this use case 2016-02-16 21:07:31 +01:00
Mark 1f54927aee Unit test for line connections 2016-02-16 21:04:11 +01:00
Mark be8fd0833c Oil-burning steam engine
The steam engine can burn oil as fuel now. Added test to power system unit test. Still needs support for actually getting oil into the engine.
Fixed a bug in LiquidContainer that would return no liquid if the entire contents are removed. Added unit test for said bug.
Fixed overspilling of connected liquid containers. Pump no longer counts as a liquid container/tank, so that it still spills liquid if no drain is connected.
2016-02-16 21:04:06 +01:00
Mark a0fb0473b3 Barrels function as fuel now.
The steam engine does not remove the barrels, it just empties them. Made power system unit test 19 end if both pumps are pumping, this seems to be the intention of the unit test. Added power system unit test 20: Steam engine fueled by oil barrels.
2016-02-16 21:04:01 +01:00
Mark 611655a9ce Removed comments 2016-02-16 21:03:38 +01:00
Mark 2099146839 Adjusted unit test so that it works with the new interface 2016-02-16 21:03:34 +01:00
Mark 371fdaeaa6 Refactoring: Pump interface names
The pump uses the same function names as the liquid tank now. This is a preparation for the consolidation of the two.
2016-02-16 21:02:56 +01:00
Mark fbdd5eeb09 Refactoring: Pimp, Pipe, SteamEngine
Now it is possible to connect lines from a pump to the steam engine. This is achieved by the steam engine being a liquid tank. It did not seem good to allow connection from pumps to all liquid containers (i.e. barrels). A liquid tank is also a liquid container, they share the same interface, but it is also a structure.

It is not yet possible to fill the steam engine with any liquid though, because it is not defined what kind of liquid it accepts. This will be oil in the future. Furthermore, the behaviour when the pump adds incompatible liquid is not defined yet.
2016-02-16 21:02:28 +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
Mark 2f5cc035b6 Library: Liquid Container
Added unit test.
2016-02-16 21:01:55 +01:00
Maikel de Vries 04877e33da do not test permeable solid mask on the elevator case in master
This messes up so many things as one could have expected. Instead we do the sensible thing and enable it only in the test scenario. For future reference all sequences involving an elevator and NPC clonks are broken with this feature.
2016-02-08 15:27:58 +01:00
Maikel de Vries 2000f741c3 kill tracing: fix relaunching tests 2016-02-01 22:02:09 +01:00
Maikel de Vries c2131ee122 kill tracing: reduce code duplication in tests 2016-02-01 21:21:30 +01:00
Maikel de Vries 00b43d3d60 kill tracing: add test for blasting free objects 2016-02-01 21:21:30 +01:00
Maikel de Vries ce6cbc1cf6 add more kill tracing tests 2016-01-29 18:56:09 +01:00
Maikel de Vries 8cabf67845 clean up tests: remove Teams.txt fix some titles 2016-01-20 19:44:28 +01:00
Maikel de Vries db9e3aa133 remove grapple bow test
Seems to be outdated and can be tested in rope test
2016-01-20 19:30:33 +01:00
Maikel de Vries ac122e4aa3 remove pump test scenario
Does not do anything and the pump is sufficiently tested in the power test.
2016-01-20 19:23:12 +01:00
Clonkonaut 7538a5bd12 Added simple testing scenario for permeable solid masks.
In there, it's also activated for basements and bridges.
2016-01-20 19:17:45 +01:00
Maikel de Vries 775746d78d fix power system tests (due to object changes) 2016-01-20 12:07:46 +01:00
Mark 8719ee8b58 Test scenario for SetGraphics()
Scenario that tests SetGraphics() in various ways: Setting graphics of meshes/sprites to other objects, overlaying objects onto other objects.
The scenario is not in the Issues.ocf folder, because it addresses multiple issues #1458 and #1538 and the status of the issues has not been acknowledged yet.
2016-01-07 19:09:18 +01:00
Maikel de Vries 7b4fe4452f killtracing: more tests and more precise test descriptions 2016-01-05 18:19:49 +01:00
Maikel de Vries af4819aa81 killtracing: add additional tests 2016-01-03 20:18:06 +01:00
Maikel de Vries 471470f1fb killtracing: more tests 2016-01-03 14:39:24 +01:00
Maikel de Vries d6a16f7ff1 killtracing: more tests and overview table 2016-01-03 13:30:11 +01:00
Maikel de Vries 5ba7519b79 killtracing: add test scenario 2016-01-03 09:57:06 +01:00
Armin Burgmeier 0538d1e57f Fix the planet/Tests.ocf/ColorfulLights.ocs test scenario
The TexMap.txt was outdated
2016-01-01 22:28:22 -08:00
Armin Burgmeier 9b9d9e378f Fix PXSAndSmoke.ocs test scenario
It contained an outdated TexMap.
2016-01-01 22:28:21 -08:00
Günther Brammer 00a4c6c428 Replace BorderBound DefCore value with BorderBound object property 2016-01-01 22:18:41 +01:00
Maikel de Vries d4a6c50d4d rope bridge can now be placed by a clonk
There are still some things to fix/implement: breaking of bridge ropes when the posts move to far apart, animations for placement and retraction.
2015-12-27 00:18:17 +01:00
Maikel de Vries 42cf57afb6 improve drawing speed of ropebridge (and further clean up) 2015-12-26 15:57:30 +01:00
Maikel de Vries 5ffc97f2f0 rope bridge clean up and cleaner way to create a bridge
Now use Ropebridge->Create(x1, y1, x2, y2) to make a bridge, this allows for some more clean up in a commit to follow.
2015-12-25 19:27:00 +01:00
Maikel de Vries e4b1fe94ca clean up grapple bow scripts 2015-12-25 16:11:17 +01:00
Maikel de Vries dea3b7f1c3 fix invertion of clonk on top ladder elements (#775) 2015-12-17 19:40:15 +01:00
Maikel de Vries 281733a689 remove Snore.wav from SkeletonAppend test
Not used, no license and it is a test for something unrelated...
2015-12-16 17:41:34 +01:00
David Dormagen dcfb986e34 moved sounds into subfolders
This completes http://forum.openclonk.org/topic_show.pl?tid=3215
2015-12-13 22:14:55 +01:00
Maikel de Vries 6065571742 fix rope particles on ladder and clean up rope related scripts
The ladder only had one of the ropes drawn and the clean up resulted in some small speed up for the rope related objects. See also (#1143).
2015-12-11 23:32:33 +01:00
Maikel de Vries fb5a910d0c add test scenario for rope and related objects 2015-12-08 16:26:21 +01:00
Maikel de Vries 7a8de4fc55 fix power loss bug when producer moves out of base area (#1447) 2015-11-28 18:05:17 +01:00
Maikel de Vries d5ac4e338f power system test: move producer outside of energy range 2015-11-26 23:18:20 +01:00
Maikel de Vries b1228bea2f additional power system test for bug #1447 2015-11-22 11:34:24 +01:00
David Dormagen 08c51288ad added smaller variation of the piranha (new Piranha texture by Matthi) 2015-10-22 10:57:14 +02:00
Maikel de Vries e2c5158275 rename S2AI to AI
This in preparation for a more general AI (in the far future).
2015-10-14 20:44:38 +02:00
Clonkonaut 1178d8f0ce Prevent dead clonks from sitting upright (#1358).
Also added convenient constants defining the animation slots to use for clonk animation.
2015-10-11 14:08:14 +02:00
Sven Eberhardt e39dab3d68 Revert accidental extra changes done in 675db52e38. 2015-10-09 14:52:47 -04:00
Sven Eberhardt 675db52e38 Texture shape coverage fix and mape build fix. 2015-10-09 14:49:31 -04:00
Armin Burgmeier b8ed577c0f Rotate the OGRE coordinate frame by 90 degrees in X
Also rotate all meshes backwards so that everything keeps working. This should
make it more convenient for modellers to create new meshes.
See http://forum.openclonk.org/topic_show.pl?pid=29410#pid29410.
2015-10-03 11:39:08 -04:00
David Dormagen 910aa4efaa squid: updated behavior & added angry squid
The default squid is still friendly (with a new texture now). Setting friendly=false during Place()ment creates red, angry squids.
Being in an ink blot drains a Clonk's breath faster now (because of the panic and increased heart-rate of course).

The friendly squid texture was created by Matthi as well.
2015-10-02 18:34:48 +02:00
Randrian45 8076075c5b added firefly and test scenario for it
squashed:
adjusted fireflies to style guidelines
* fireflys emmit light
+ added firefly and test scenario for it
2015-10-01 18:40:14 +02:00
David Dormagen a8943f88d5 added squid
Model and texture by Matthi.
2015-09-30 18:31:44 +02:00
Maikel de Vries 881f2f817e fixed using two grapple bows 2015-09-05 16:16:38 +02:00
David Dormagen ac738735b2 Merge branch 'master' into Controls
Conflicts:
	planet/Objects.ocd/Vehicles.ocd/Airplane.ocd/Script.c
	src/game/C4Game.cpp
	src/game/C4GraphicsSystem.cpp
	src/gamescript/C4GameScript.cpp
2015-09-02 08:19:34 +02:00
Maikel de Vries a63e8f4955 improve the AI testing scenario 2015-08-19 08:11:43 +02:00
David Dormagen 36544bd56c Merge branch 'master' into Controls
Conflicts:
	planet/Objects.ocd/Libraries.ocd/Producer.ocd/Script.c
	planet/Objects.ocd/Structures.ocd/Foundry.ocd/Script.c
	planet/Objects.ocd/Vegetation.ocd/Branch.ocd/Script.c
	planet/Objects.ocd/Vegetation.ocd/Trunk.ocd/Script.c
	planet/System.ocg/FindLocation.c
2015-08-02 19:24:04 +02:00
David Dormagen d5f4805f18 fixed desync
The desync was caused by PropList->GetProperties returning the properties in an arbitrary order. They are now sorted first.
The debug logs are left in place, because I assume that I will need them again and they prove to be helpful.
2015-08-02 19:12:09 +02:00
Sven Eberhardt 0d48105b46 Added shape library.
Also fixed some coconut tree reproduction issues.
2015-07-31 00:42:01 -04:00
Mark 02fd798631 Colored lights
The color of object lights can now be changed. This includes the following changes:
- added light test scenario, based on DarkCastle, with some lights,
- new functions SetLightColor() and GetLightColor() with C4Script documentation,
- third drawing pass for rendering the light color, the drawing passes are now referenced by enum,
- the blending of light from multiple colored light sources works correctly with alpha blending,
- light color value affects the intensity of the light,
- alpha blending of the light depends on color value and lightness. This means that brighter (= more value) and lighter (= more whiteish) light will be preferred in blending over other lights,
- the object light color is rendered to the lower half of the fow light texture now,
- the shader accesses the brightness/direction information and color information correctly,

The patch was created from the following commits:
dab898a SetLightColor()
f57286e Color texture experiment
d0702f5 Dynamic color
fa14cdf Light test scenario
f99203d Alternate lights
474bade Bugfixes
3113698 Brightness handled better
516fb21 GetLightColor
1d91ec9 Improvements
3cfbf6c Documentation
95ec185 Improvements: Light Shader
a63bffc Scope of alpha
20c7ca0 Improvement: C4FoWLight
17d9123 Undo code style
d79411b Cleaner code

(cherry picked from commit 36dec610e36860b88417e91ce727250673bc2ec2)

Conflicts:
	src/landscape/fow/C4FoWRegion.cpp, merged
2015-06-28 21:28:40 +02:00
David Dormagen 196f528201 Merge branch 'master' into Controls
Conflicts:
	planet/Objects.ocd/HUD.ocd/FancyGridMenu.ocd/DefCore.txt
	planet/Objects.ocd/HUD.ocd/GridMenu.ocd/DefCore.txt
	planet/Objects.ocd/Helpers.ocd/Dummy.ocd/Graphics.png
	planet/Objects.ocd/Items.ocd/Tools.ocd/WindBag.ocd/Script.c
	planet/Objects.ocd/Items.ocd/Weapons.ocd/Javelin.ocd/Script.c
	planet/Objects.ocd/Libraries.ocd/ClonkControl.ocd/Script.c
	planet/Objects.ocd/Libraries.ocd/Constructor.ocd/ConstructionMenu.ocd/Script.c
	planet/Objects.ocd/Libraries.ocd/Constructor.ocd/Script.c
	planet/Objects.ocd/Libraries.ocd/Flag.ocd/Marker.ocd/Script.c
	planet/Objects.ocd/Libraries.ocd/Producer.ocd/Script.c
	planet/Objects.ocd/Structures.ocd/Flagpole.ocd/Script.c
	planet/Objects.ocd/Structures.ocd/Pump.ocd/Script.c
	src/game/C4Game.cpp
	src/gamescript/C4GameScript.cpp
	src/gui/C4GameMessage.cpp
	src/landscape/C4Landscape.cpp
2015-06-03 22:32:36 +02:00
Maikel de Vries 5b12d6c240 deactivate power producers correctly on over production 2015-03-09 21:50:19 +01:00
Maikel de Vries ca04f00a58 add test for underproduction of power 2015-03-09 18:55:18 +01:00
Maikel de Vries 0ed8c2faa5 fix pumping downwards after source emptyness 2015-03-05 20:40:10 +01:00
Maikel de Vries de8ee9d840 fix flag removal effect on power network 2015-02-11 22:42:35 +01:00
Maikel de Vries cba73bafca implement flag ownership and network change on team switch and hostility change 2015-02-11 00:02:45 +01:00
Maikel de Vries e47a08aaf7 clean up more flag related libraries 2015-02-08 15:28:13 +01:00
Maikel de Vries 38e0e0d299 add a test for testing power system performance 2015-02-07 18:17:49 +01:00
Maikel de Vries b59141f905 remove debug logging from power library 2015-02-04 15:56:02 +01:00
Maikel de Vries a5155f6d88 fixed no power need rule 2015-02-04 12:40:29 +01:00
Maikel de Vries 750945ee1c add a test for player elimination effects on power network 2015-02-04 10:35:16 +01:00
Maikel de Vries aea2c7f9d2 fix title for explode container test 2015-02-04 10:35:16 +01:00
Maikel de Vries 5eef390b44 power priorities are updated before network balancing 2015-02-04 10:35:15 +01:00
Maikel de Vries 17c4049563 separate library for power storage 2015-02-04 10:35:15 +01:00
Maikel de Vries c0ff94eb75 normalize power values to multiples of ten
This makes it easier for internal calculations and that value of 10 now represents a single light bulb. It is advisable to only use multiples of 10 for production and consumption values.
2015-02-04 10:35:15 +01:00
Maikel de Vries e7fa8621e2 fix power consumption of elevator 2015-02-04 10:35:15 +01:00
Maikel de Vries c5e36d8f1f fixed object placement in power test after rebase 2015-02-04 10:35:15 +01:00
Maikel de Vries 9d0e079d7d power library local variables in a single proplist
This prevents clashes, all libraries could use a single proplist named lib_*
2015-02-04 10:35:15 +01:00
Maikel de Vries 2c317888ca wind mill is only power producer for itself 2015-02-04 10:35:15 +01:00
Maikel de Vries 86a7728650 add new power test for power producing pumps 2015-02-04 10:35:15 +01:00
Maikel de Vries eec38a9f17 reimplement power network handling by the flag library 2015-02-04 10:35:14 +01:00
Maikel de Vries ac5f9dbce7 correctly implement handling of steady power producers 2015-02-04 10:35:14 +01:00
Maikel de Vries 2d00588dff new power system (work in progress) 2015-02-04 10:35:14 +01:00
David Dormagen 4c69e19219 custom guis: correctly respect margins in grid layout and vertical layout 2015-01-20 20:44:13 +01:00
Sven Eberhardt 3286095755 AI can use grenade launcher. 2015-01-18 19:13:10 +01:00
Maikel de Vries 8b5a1f7e18 fix AI test scenario 2015-01-18 12:47:00 +01:00
David Dormagen bd04722553 Merge branch 'master' into Controls
Conflicts:
	planet/Objects.ocd/HUD.ocd/Controller.ocd/Script.c
	planet/Objects.ocd/Libraries.ocd/ClonkControl.ocd/Script.c
	planet/Objects.ocd/Libraries.ocd/Constructor.ocd/ConstructionMenu.ocd/Script.c
	planet/Objects.ocd/Libraries.ocd/Constructor.ocd/Script.c
	src/game/C4GraphicsSystem.cpp
	src/game/C4GraphicsSystem.h
	src/game/C4Viewport.cpp
	src/gui/C4GameMessage.cpp
2015-01-15 19:57:01 +01:00
Maikel de Vries 75cb5ce800 more tests for exploding containers 2015-01-15 18:31:23 +01:00
Maikel de Vries a0faaf9082 add Test scenario for explosions in containers 2015-01-15 17:46:54 +01:00
Mark 850bf1b9d4 CreateObject/CreateObjectAbove (#1214)
Renamed CreateObject() to CreateObjectAbove() and replaced all occurrences in script files.
Added CreateObject(), the function may need a rewrite though, see comment in code.
Updated documentation
2015-01-11 19:02:03 +01:00
Mark 10b343dba9 Append and include skeletons (#1180)
Appending and including skeletons works now. Documentation updated.
Skins such as appendto.Clonk.Farmer.skeleton are handled as if the skin name were not included: appendto.Clonk.skeleton

This also changes a bit the structure of how meshes are reloaded in general,
in particular mesh materials are only reloaded once and not once per
C4DefGraphics instance. (Fix crash on reload with included skeletons, cherry picked from commit 2f69aa4850ab7a4b621e5f30cbc537d40f32c0df)

Fix linking of C4Script standalone tool (cherry picked from commit b03a332b73463b378c94e4e92b66d45b923b3b9c)
2015-01-06 18:25:08 +01:00
David Dormagen f89b8c8319 Merge branch 'master' into Controls
Conflicts:
	planet/Objects.ocd/Environment.ocd/Cloud.ocd/DefCore.txt
	planet/Objects.ocd/Libraries.ocd/ClonkControl.ocd/Script.c
	planet/Objects.ocd/Libraries.ocd/Constructor.ocd/ConstructionMenu.ocd/DefCore.txt
	planet/Objects.ocd/Libraries.ocd/PowerConsumer.ocd/Script.c
	planet/Objects.ocd/Libraries.ocd/PowerProducer.ocd/Script.c
	planet/Objects.ocd/Libraries.ocd/Producer.ocd/Script.c
	planet/System.ocg/ClonkControl.c
	src/gui/C4MouseControl.cpp
	src/landscape/C4PXS.cpp
2014-12-25 15:24:19 +01:00
Maikel de Vries 2d1647ea77 improved prioritizing of power consumers 2014-12-19 21:47:08 +01:00
Maikel de Vries 22dfab63aa clean up scripts of power library 2014-12-19 14:56:01 +01:00
Maikel de Vries c6802b8776 increase game content version entries to 6.0 2014-12-12 22:58:16 +01:00
Maikel de Vries d72338f167 add test scenario for power system 2014-10-18 15:41:49 +02:00
David Dormagen c09e9880e2 Merge branch 'master' into Controls
Conflicts:
	planet/Objects.ocd/Libraries.ocd/ClonkControl.ocd/Script.c
2014-10-13 18:54:05 +02:00
David Dormagen 6a875a1b29 CustomGuis: renamed several script functions to be more consistent; removed Gui_AddMargin as it is obsolete
All calls that reference an existing Gui window now start with "GuiUpdate" (exception: GuiClose). All other functions are always to be called DURING menu creation and layouting.
The "Margin" property replaces Gui_AddMargin.

find . -type f -name "*.c" -print0 | xargs -0 sed -i 's/CustomGuiOpen/GuiOpen/g'
find . -type f -name "*.c" -print0 | xargs -0 sed -i 's/CustomGuiClose/GuiClose/g'
find . -type f -name "*.c" -print0 | xargs -0 sed -i 's/CustomGuiSetTag/GuiUpdateTag/g'
find . -type f -name "*.c" -print0 | xargs -0 sed -i 's/CustomGuiUpdate/GuiUpdate/g'
find . -type f -name "*.c" -print0 | xargs -0 sed -i 's/Gui_AddCloseButton/GuiAddCloseButton/g'
find . -type f -name "*.c" -print0 | xargs -0 sed -i 's/Gui_UpdateText/GuiUpdateText/g'
find . -type f -name "*.c" -print0 | xargs -0 sed -i 's/Gui_AddSubwindow/GuiAddSubwindow/g'
2014-10-11 11:51:26 +02:00
David Dormagen 049088be78 CustomGUIs: major rework of layouting & controls; better integration of C4GUI 2014-10-11 11:29:02 +02:00
Armin Burgmeier af6163b797 Add test scenario for many lava PXS and smoke particles 2014-10-08 18:33:46 -04:00
Sven Eberhardt d4eb45f6b2 Set titles for a few scenarios in Tests.ocf.
So you can distinguish between them in the startup menu.
2014-10-03 21:58:33 +02:00
David Dormagen 952f06b173 Merge branch 'master' into Controls
Conflicts:
	planet/Objects.ocd/Libraries.ocd/ClonkControl.ocd/Script.c
2014-09-29 11:47:09 +02:00
Sven Eberhardt 3308503381 Improve parameter test scenario 2014-09-26 22:11:11 +02:00
Sven Eberhardt abab7be591 Added scenario achievements displayed as small symbols beside the scenario name in the startup selection screen.
They can be used e.g. to show that you have finished a scenario on different difficulty levels.
2014-09-24 23:08:40 +02:00
Sven Eberhardt 378bda5546 Added custom scenario parameters (SCENPAR_*).
Can currently only be set in network games in the lobby. In the future, maybe we can find a place somewhere in the scenario selection dialogue.
2014-09-23 23:02:52 +02:00
David Dormagen 5722339e83 Merge branch 'master' into Controls
Conflicts:
	planet/Objects.ocd/HUD.ocd/Controller.ocd/Script.c
	planet/Objects.ocd/Libraries.ocd/Structure.ocd/Script.c
	src/gamescript/C4GameScript.cpp
	src/gui/C4GameMessage.cpp
	src/gui/C4Gui.h
	src/gui/C4GuiDialogs.cpp
	src/gui/C4GuiWindow.cpp
2014-08-13 11:52:41 +02:00
Sven Eberhardt 220617655b Merge branch 'underwater' 2014-07-10 23:13:55 +02:00
David Dormagen 75e776cb04 custom GUIs: added "Margin" property
The property can be used to give GUI windows a margin. Either the same margin in all directions (Margin = "1em") or different margins (Margin = ["1em", "2em", "10$", "0.5em"] - [left, top, right, bottom]).
2014-02-26 22:37:12 +01:00
David Dormagen 4346da8e4e custom GUIs: replace position properties X/Y/Wdt/Hgt with Left/Right/Top/Bottom that take strings instead of arrays, also change absolute unit from pixels to em
Before you'd define the X coordinate of the top-left corner of a window with X = [500, -40], now you do Left = "50%-4em". The em values currently do not scale with font-size yet, but it is important to do the formal change as early as possible to not have to do all work twice. Scaling of font and thus menus can be implemented later.
2014-02-17 15:46:36 +01:00
David Dormagen fa4638d6c0 custom GUIs: change order of arguments of GuiAction_SetTag from (target, id, tag) to (tag, id, target) 2014-02-16 17:18:34 +01:00
David Dormagen a0a76c051d custom GUI: removed "CreateCustomMenu" which was only a wrapper for "CreateObject" - use "CreateObject" now
This should reduce the confusion about why the function behaves so differently from Gui_Open: the style objects only provide an interface for those easy GUIs, they are not really part of the GUI system.
2014-02-15 18:59:33 +01:00
David Dormagen 06ac00ace8 Merge branch 'master' into Controls
Conflicts:
	CMakeLists.txt
	Makefile.am
	planet/Objects.ocd/HUD.ocd/Controller.ocd/Script.c
	planet/Objects.ocd/Items.ocd/Weapons.ocd/Club.ocd/Script.c
	planet/Objects.ocd/Libraries.ocd/ClonkControl.ocd/Script.c
	src/control/C4Control.cpp
	src/control/C4Control.h
	src/gamescript/C4GameScript.cpp
2014-02-15 14:44:57 +01:00
David Dormagen 5fa7c54842 MenuTest scenario: minor visual tweaks 2014-02-15 14:40:51 +01:00
David Dormagen 410a0ff5cb made the user-data parameter of a GUI_Call-action-callback the first (before player number, menuID etc.) to be more intuitive 2014-02-15 14:39:56 +01:00
David Dormagen a10c9316ef renamed DynamicParticles* to Particles* and CreateParticleEx to CreateParticle 2013-12-17 22:32:01 +01:00
Tobias Zwick a54eed6b9b add name to One Million Particles so it can be found from ingame gui 2013-12-05 10:39:45 +07:00
David Dormagen 3c34857c0f added particle test scenario that spawns a million particles (and heavy effects afterwards)
The honorable goal of the particle system should be that this scenario always runs fluently. Even though optimizing the drawing will not be possible after a certain point, the particle system should scale down the drawing automatically to allow for a fluent game.
2013-12-01 23:50:54 +01:00
Sven Eberhardt af52ef8dca GrappleBow test: Sandbox scenario for using the grapple bow on various landscape shapes. 2013-09-08 13:00:37 +02:00
David Dormagen 7b0e614564 added (first) Coral 2013-07-11 21:11:55 +02:00
David Dormagen d5fbb5f17d the water in the underwater-testscenario does not freeze anymore, killing all the fishes gruesomely 2013-07-07 15:53:28 +02:00
David Dormagen fde942790e added Fish, Piranha, Testscenario and FuzzyLogic library 2013-07-02 21:33:57 +02:00
David Dormagen 337126fcb9 renamed MenuWindow to GuiWindow
added HP-Bar-test to MenuTest.ocs
bugfix
2013-05-09 13:28:45 +02:00
David Dormagen dd851fbea2 Merge branch 'master' into Menus 2013-04-28 17:07:56 +02:00