Sven Eberhardt
244650bb17
Add base material to player spawn object.
...
Set the default to a lot of clonks. This is useful so the "respawn at flagpole" rule works as expected even if users don't know about the base material setting.
2016-10-09 13:27:20 -04:00
Sven Eberhardt
b0e42e35d1
Sequence: Default action to empty sequence
2016-10-09 13:27:20 -04:00
Mark
2957a777b3
Goal: Extracted function NotifyPlayerHUD
...
Removed duplicate code in the process.
2016-10-09 11:53:25 +02:00
Mark
35e8a43f82
Goal: Optimize HUD updates
...
No more lacking behind the fulfillment status.
2016-10-09 11:50:06 +02:00
Mark
84dd95df34
Goal controller: Player parameters for goal display functions
...
Allows goals with different symbols per player.
2016-10-09 11:34:13 +02:00
Mark
9fcd3ee13e
Goal controller: Extracted functions
...
Made the variable names consistent between GoalSubMenu() and OnGoalUpdate();
Extracted the functions GetGoalSymbol() and GetGoalGraphics();
2016-10-09 11:26:47 +02:00
Mark
b18a7b7a3f
Goal controller: Readability
...
The change in call structure should not make that much of a difference in performance.
2016-10-09 11:18:10 +02:00
Mark
0d22f58b52
Goal controller: Get short description only once.
2016-10-09 11:13:12 +02:00
Mark
0732b7dc87
Goal controller: Code cleanup
2016-10-09 11:11:51 +02:00
Mark
b235c5e9e4
Goal controller: Simplified code
2016-10-09 11:11:28 +02:00
Mark
f52159b835
Goal controller: Variable definitions
2016-10-09 10:58:37 +02:00
Mark
be207737bc
Goal controller: Slight optimization
...
No need to call the function twice. This is trivial though, the call is not expensive usually.
2016-10-09 10:51:48 +02:00
Sven Eberhardt
c05ee7e644
Add gravestone inscription editor props
2016-10-08 23:29:50 -04:00
Mark
7c169c7905
Moved object interaction menu sidebar icons to separate overloadable functions
2016-10-08 17:46:39 +02:00
Maikel de Vries
2505dc77f1
add room door to Decoration.ocd
...
This is a door which leads to nowhere, but they can be connected via script or serve other purposes. Graphics by Apfelclonk.
2016-10-06 18:43:04 +02:00
Clonkonaut
f37eda9508
Moved HUD proplist definitions to separate, overloadable functions.
...
See http://forum.openclonk.org/topic_show.pl?pid=32552#pid32552 for more information.
2016-10-06 01:47:45 +02:00
Lukas Werling
ddb34ab5cb
Disallow interaction with actively controlled Clonks
...
This prevents inventory stealing which is undesirable in cooperative
scenarios with competitive elements (e.g. some races) and confusing to
players.
2016-10-05 22:14:40 +02:00
Maikel de Vries
89be9bd158
implement scenario saving for liquid tank, pump & pipe
2016-10-03 18:07:49 +02:00
Sven Eberhardt
4756fb0ba1
Unify moving brick graphics size.
...
Otherwise, there were still graphics artifacts sometimes.
2016-10-03 00:02:46 -04:00
Sven Eberhardt
76ce8089af
Fix display of moving bricks with size<4.
2016-10-02 23:47:02 -04:00
Sven Eberhardt
d48dbfba82
Add optional size parameter to Particles_Flash
2016-10-02 23:47:01 -04:00
Maikel de Vries
1483620b2b
fix c4script runtime error in power system when pump is initialized
2016-10-02 23:23:20 +02:00
Maikel de Vries
48d98d708e
fix script error in keypad
2016-10-02 08:03:14 +02:00
Maikel de Vries
b0ff00439f
fix possible script error in pump
2016-10-01 19:18:23 +02:00
Maikel de Vries
2073fb0f0a
improve picture graphics of animals
2016-10-01 16:32:29 +02:00
Maikel de Vries
1eb17613bc
keypad: allow alternative graphics for its buttons
2016-10-01 16:32:29 +02:00
Maikel de Vries
df43ab86f2
add IsAnimal to animals for finding them
2016-10-01 16:32:29 +02:00
Sven Eberhardt
9299ec4223
Fix max energy in AI test scenario
2016-10-01 10:26:43 -04:00
Sven Eberhardt
b317afbadc
Fix division by zero on progress bars with max=0
2016-10-01 10:26:25 -04:00
Sven Eberhardt
d04476ad0b
Allow oversize and rotation of fence
2016-09-30 22:23:11 -04:00
Sven Eberhardt
0604a815d0
Fix undefined constant in keypad
2016-09-30 21:40:57 -04:00
Maikel de Vries
fa977149e9
make firefly use insect swarm library
2016-09-30 18:58:42 +02:00
Maikel de Vries
b42a4b824b
insect swarm: fix movement issues
2016-09-30 18:58:42 +02:00
Maikel de Vries
32f5b1cb25
add keypad to decoration objects
...
This can control lots of things and triggers on entering the correct code.
2016-09-26 17:15:37 +02:00
Lukas Werling
10622a9b61
Add generic A* implementation for path finding in graphs
2016-09-26 16:30:47 +02:00
Maikel de Vries
0e76c85531
make line overlap check a global function
...
This avoids code duplication and really is a Math.c function.
2016-09-24 17:30:19 +02:00
Maikel de Vries
fb38acb946
allow setting plr view/zoom at player start object
2016-09-23 20:21:34 +02:00
Maikel de Vries
18424aaaa7
add rule to control pump speed
2016-09-23 09:26:06 +02:00
Maikel de Vries
4c7d27ec64
bats require less space on placement
2016-09-23 09:18:57 +02:00
Maikel de Vries
3df960851c
_inherited() for trees to access library functionality
2016-09-20 15:11:32 +02:00
Maikel de Vries
823b13d764
add simple string to integer conversion function
...
Just a basic one in C4Script for now.
2016-09-18 11:30:35 +02:00
Lukas Werling
db12ed7c99
Remove FindSubstring as it's really really slow
...
Use RegexSearch() instead, which is 100 times faster for large strings
(see benchmark results below).
Example benchmark:
global func TestFindSubstring(int iterations)
{
var result;
for (var i = 0; i < iterations; i++)
{
result = FindSubstring(hamlet, "and");
}
return result;
}
global func TestRegexSearch(int iterations)
{
var result;
for (var i = 0; i < iterations; i++)
{
result = RegexSearch(hamlet, "and");
}
return result;
}
global func RunBenchmark(int iterations)
{
StartScriptProfiler();
Log("FindSubstring: %d iterations", iterations);
var substr = TestFindSubstring(iterations);
Log("RegexSearch: %d iterations", iterations);
var regex = TestRegexSearch(iterations);
StopScriptProfiler();
if (!DeepEqual(regex, substr))
Log("Results differ: %v vs %v", substr, regex);
}
Results:
FindSubstring: 100 iterations
RegexSearch: 100 iterations
Profiler statistics:
==============================
48903ms Global.FindSubstring
48903ms Global.TestFindSubstring
47979ms Global.TakeString
00504ms Global.TestRegexSearch
00016ms Global.PushBack
==============================
2016-09-17 20:08:43 +02:00
Maikel de Vries
4b54b86d30
add function to find substrings
2016-09-16 17:25:22 +02:00
Mark
ae1de739b0
Wooden Bridge: Return other bridge in CombineWith()
...
Apparently the return value is not used anywhere; the change allows chaining multiple bridges in a comfortable call.
2016-09-15 19:25:16 +02:00
Mark
58d42b8fd8
Library Lamp: Extracted functions.
...
Did this change a long time ago, probably for re-using functions in a derived object.
2016-09-15 19:17:17 +02:00
Sven Eberhardt
0cdad64934
Fix goal and rule displays ( #1811 )
2016-09-14 21:46:16 -04:00
Sven Eberhardt
22af9f0e8c
Fix landscape placement functions ( #1820 , #1821 )
2016-09-14 21:30:57 -04:00
Sven Eberhardt
61b1ab08ad
Editor: More shortcuts; show helper shortcuts in tools menu
2016-09-10 01:17:40 -04:00
Sven Eberhardt
d3d7256fec
Fix missing achievement in Krakatoa's Krach ( #1819 )
2016-09-10 01:17:39 -04:00
Sven Eberhardt
53b365a6d2
Editor: Add shortcuts, menu items, tooltips
2016-09-08 01:56:01 -04:00
Sven Eberhardt
b95d1387a4
Editor: Add "reset to saved scenario" command
2016-09-07 01:53:54 -04:00
Maikel de Vries
f76e056cea
add new items to knowledge in worlds
2016-09-06 17:06:05 +02:00
Maikel de Vries
17f98bd235
add helper functions chars
2016-09-06 17:06:05 +02:00
Sven Eberhardt
282a561462
Add editor props and user actions for boiling lava and acid
...
Also optimize the timer
2016-09-06 00:06:37 -04:00
Sven Eberhardt
6aeeff0545
Add Library_Stackable editor props
2016-09-05 20:19:25 -04:00
Sven Eberhardt
db986e3dd7
Allow repeated ejection of infinite material stack counts in bucket and barrel
2016-09-05 20:08:30 -04:00
Sven Eberhardt
3330c592e3
Improve PlayerStart initial material setting to allow specification of weapon ammo, stackable stack count and liquid contents
2016-09-05 20:01:47 -04:00
Sven Eberhardt
34058e13f9
Fix default assignment of selected object in user action filtered object evaluators
2016-09-05 02:00:00 -04:00
Sven Eberhardt
117ddac8b4
Auto-unstick animals and objects on ground in saved scenarios
2016-09-05 01:59:59 -04:00
Sven Eberhardt
31ead2507a
Add Unstick() script function
...
Also add a position parameter to Stuck() script function.
2016-09-05 01:59:58 -04:00
Sven Eberhardt
6a78a9facb
Fix scenario saving of some animal and plant properties
2016-09-04 02:52:03 -04:00
Sven Eberhardt
ebfebca87b
Sequence: "Start Game" trigger uses first player as triggering player
2016-09-04 02:15:09 -04:00
Sven Eberhardt
dc77020586
Add user actions: Invincibility and invisibility
2016-09-03 22:07:10 -04:00
Sven Eberhardt
692ff39c0e
Add invisibility EditorProp to all object
...
Also localize some property names.
2016-09-03 22:07:10 -04:00
Sven Eberhardt
392dc7b49e
Fix portrait reset when switching skin to non-extended decoration skin in editor while decoration definition is loaded
2016-09-03 22:07:08 -04:00
Sven Eberhardt
bae26bb0d7
Add user action: Set clonk direction
2016-09-03 22:07:08 -04:00
Maikel de Vries
8e75b8fed9
allow branch placement in alternative materials
2016-09-03 19:38:52 +02:00
Maikel de Vries
914d0f4f8e
fix scenario saving of waterfall
2016-09-03 19:37:39 +02:00
David Dormagen
4dd9be0e46
chippies: fix unintended growth through animal library
...
Inclusion of the library buffed the damage wild chippies do by 100%. This is unintended. Chippies grow (and get stronger) through sucking blood.
A commit that changes this behavior should address this directly. (This commit also makes chippies gain size a bit faster - as a compromise.)
The additional check in StartGrowth reduces overhead in the animals (and possibly plants) library. It is kept in this commit to give reviewers an example case for the check.
2016-09-02 09:34:19 +02:00
Sven Eberhardt
bdbce1c4c9
Fixes and EditorProps for plant reproduction
2016-09-01 23:54:27 -04:00
Sven Eberhardt
31121d682c
Rename option default value function property to DefaultValueFunction
...
It was "Get" and later "Set", which was always a bit confusing.
2016-09-01 18:32:24 -04:00
Sven Eberhardt
3b7e36abd8
Adjust chippie to use animal library for reproduction
...
(It still reproduces independently after sucking out a clonk)
2016-09-01 02:24:43 -04:00
Sven Eberhardt
9cec9b5071
Make animal library properties editor-adjustable
...
Allows e.g. placement of animals that do not reproduce.
2016-09-01 02:23:42 -04:00
Sven Eberhardt
cd4e419aef
Disallow interaction menu on hostile and neutral clonks
...
Stealing items in melees or taking quest items from NPCs is a bit odd.
2016-08-30 19:54:58 -04:00
Sven Eberhardt
4c56b41de0
Fix color group in "any" value evaluator of user actions
2016-08-30 19:42:31 -04:00
Sven Eberhardt
c487c530e4
Fix respawn at flagpole position
2016-08-30 14:45:41 -04:00
Sven Eberhardt
f3f475e38a
Fix Time default initialization and add editor props
2016-08-30 02:00:02 -04:00
Sven Eberhardt
e7c11cf590
Add user action evaluators: Enter+Exit object
2016-08-30 01:40:18 -04:00
Sven Eberhardt
76227e4e6c
Add user action color evaluators: Player color, random color, RGB
2016-08-30 00:30:22 -04:00
Sven Eberhardt
48d8ad8de9
Add UserAction evaluators: for integer/player/object in list
2016-08-29 15:18:21 -04:00
Sven Eberhardt
c72135db1f
Add user action comment
2016-08-29 00:41:48 -04:00
Sven Eberhardt
cc2f626063
Add UserAction conditional value evaluator
...
i.e. operator ? :
2016-08-29 00:32:52 -04:00
Sven Eberhardt
bda3cb5640
Add UserActions to deactivate/reactivate player control
2016-08-28 22:18:58 -04:00
Sven Eberhardt
4caa9ee217
Fix disappearing health bars after crew reactivation and savegame reload ( #1629 , #1740 )
2016-08-28 22:13:08 -04:00
Sven Eberhardt
b763982f45
Fix scenario saving as network client to not delete saved scenario after game end ( #1814 )
2016-08-28 00:56:15 -04:00
Sven Eberhardt
f796716655
Fix cotton scenario saving
2016-08-28 00:20:39 -04:00
Sven Eberhardt
5da1a0d5c1
Fix some sequence progress bugs
2016-08-28 00:16:58 -04:00
Sven Eberhardt
96842e2961
Sequence test uses first local player as triggering player
2016-08-27 22:20:03 -04:00
Sven Eberhardt
61b75f002f
Add extra clonk skins to skin selection menu in editor props
2016-08-27 19:04:50 -04:00
Sven Eberhardt
b339db9ea7
UserAction particles: Add fire and ring particles
...
Also sort particle type list by name.
2016-08-27 17:45:01 -04:00
Sven Eberhardt
0e3b1865ea
UserAction: Add more options for particle creation
...
Also fix collision behaviour setting to work.
2016-08-27 17:38:25 -04:00
Sven Eberhardt
147e70ace9
Fix sequence and dialogue progress mode saving
2016-08-27 17:17:48 -04:00
Sven Eberhardt
065d8536da
UserAction evaluators: Sort constant value above other evaluators
2016-08-27 17:15:20 -04:00
Sven Eberhardt
dfefa7df6f
UserAction goto and log: Put parameters directly into enum
2016-08-27 17:14:51 -04:00
Sven Eberhardt
6b9df3118c
Sort UserAction evaluators and groups by name
...
Also merge effect group into ambience group.
2016-08-27 16:46:59 -04:00
Sven Eberhardt
e2e9248d89
UserAction: Clarify HideFullName property comment
2016-08-27 16:46:58 -04:00
Maikel de Vries
788ba6e0c4
allow swapping source and drain pipe at the pump
2016-08-27 17:10:30 +02:00
Maikel de Vries
a15ac3742e
add icon for swap
2016-08-27 17:10:30 +02:00
Sven Eberhardt
dba7e773ab
UserAction variable evaluators: Default name to empty string constant
2016-08-27 10:01:33 -04:00
Sven Eberhardt
4a14ce735e
Fix UserAction type "Any" evaluators
...
Their callback function was not registered if they weren't duplicates from a non-any type
2016-08-27 09:59:25 -04:00