Commit Graph

37 Commits (7a042ecca50bc08aebcb9dd56e4e5c6c78957ec5)

Author SHA1 Message Date
Günther Brammer 7967d94a59 Merge StdFont.cpp and C4Fonts.cpp 2012-11-12 02:30:16 +01:00
Günther Brammer c439c81362 Remove unused C4D_None 2012-11-12 02:41:20 +01:00
Tobias Zwick 348fb8c7a9 clean up mouse controls, reduced cursor graphics to the used ones 2012-11-16 17:29:42 +01:00
Günther Brammer 4b096d71a0 Do not clip parallax objects (fix disappearing moon, #575) 2012-10-30 22:18:27 +01:00
Philipp Kern e037300801 Fix spelling mistake: ressource -> resource. 2012-10-21 22:20:43 +02:00
Armin Burgmeier b4aafdd874 Remove build number aka C4XVER4 2012-10-18 23:54:50 +02:00
Armin Burgmeier 9c1496178b Load Graphics*.mesh files for use with SetGraphics (#480) 2012-10-14 14:37:45 +02:00
Sven Eberhardt 73120db094 DebugRec: CallEveryDefinition puts def names, not localized names into debug rec 2012-10-14 13:33:32 +02:00
Armin Burgmeier 977cf98f82 Always climb up when pressing the direction key against the wall 2012-10-13 18:03:20 +02:00
Günther Brammer 10dd29ee49 Do not scale or tumble while jumping upwards and hitting the feet
Theoretically, the Clonk shouldn't even hit the feet at the start of the
jump, but that's a quest for another time.
2012-10-13 17:14:13 +02:00
Nicolas Hake 27eb5dd65a Allow object interaction with closed borders
Conceptually, the landscape stretches infinitely on both left and right hand
borders of the map. So far, the "closed" part of the border only blocked objects
from passing through. (Additionally, there was a bug where you could scale the
border under certain circumstances.) This patch allows objects to properly
move around on the map borders, including scaling the fake terrain.
2012-10-10 21:28:25 +02:00
Nicolas Hake 9f83a613dc Always reset C4Action::t_attach when executing action (#808)
Not resetting t_attach leads to strange behavior in liquids since detaching from
the landscape usually happens via the Jump action which generally reverts to its
InLiquidAction before t_attach gets reset. By removing the shortcut return after
entering the InLiquidAction, we make sure t_attach gets reset correctly (as well
as immediately executing the correct action instead of doing so after a delay of
one frame).
2012-10-10 21:28:25 +02:00
Günther Brammer c9bcafba56 Simplify DoCon implementation
For example, the solidmask removal is done in
UpdateFace, and might have been needed in Clonk 4 or Clonk Planet, but the
current solidmask code is fine with the call from there.
2012-07-27 16:09:25 +02:00
Günther Brammer 6dac692bd5 DoCon holds the bottom-most vertex in place, not the bottom of the Shape
This makes trees not sink into the landscape when burning.
2012-07-27 17:44:59 +02:00
Günther Brammer 6a0f9b164c Use a constant for the default gravity instead of triplicating it 2012-07-25 17:02:10 +02:00
Günther Brammer 49a0ea7bd2 Support Decel for SCALE, HANGLE and FLIGHT, fall back to Accel
All procedures now use the Accel value if the Decel value is nil, and also
use the default Attach value if that is nil.
2012-07-15 21:47:50 +02:00
Günther Brammer 9f0556250f Clonks don't lose their speed when hitting a wall 2012-07-15 19:05:20 +02:00
Günther Brammer 692fb103f1 DrawVertex uses thinner lines for the cross 2012-06-08 16:19:36 +02:00
Günther Brammer f41590d71f Merge branch 'movement' 2012-07-13 23:27:14 +02:00
Armin Burgmeier 6661f8b8cb Fix a crash when attaching a mesh by definition fails 2012-06-30 22:04:48 +02:00
Günther Brammer 4985c519c6 Switch from SCALE to Walk on top of slopes
The precise rule is that only CNAT_Bottom vertices connect to the
landscape and connect at the bottom, too. It doesn't quite fit with
the other procedure-transitions because the movement code doesn't
consider the bottom vertex to touch the landscape in that situation,
but this is probably less weird than the old cornerscale teleportation.

Also don't transition from FLIGHT to Scale when the ComDir points
away from the wall. That tended to stop the Clonk in its tracks on
uneven ground.
2012-06-19 01:40:37 +02:00
Günther Brammer 24bfd6345d Use Action.Attach even when Action.Procedure is not nil
But default to the previously used value when Attach is not set. Use 0 to
override the default.
2012-06-16 03:01:47 +02:00
Günther Brammer bb292e828d Attached objects use the nearest available point instead of the farthest
This avoids some teleporting when there's some material behind the object
and in front of it. Especially useful for small bumps of material in front
of a wall with the new left/right attachment of the foot vertex of the
Clonk.
2012-06-08 16:20:26 +02:00
Günther Brammer 944ca60910 Tweak the "corner scale" behaviour
Instead of teleporting from sticking with the left/rightmost vertex to the
want to standing on the lowest one at the same position, the Clonk can now
climb using the lowest vertex alone. That means the teleport only needs to
cover only one pixel each in x and y direction to go from sticking to the
side of the landscape pixel to sticking on top of the same pixel.

Also remove some unnecessary x/ydir resets and make comdir in the direction
of the wall the Clonk is scaling keep the up/down direction instead of only
going up.
2012-06-08 16:17:42 +02:00
Günther Brammer 4e71af5489 Script: Add GetProperties function to get the keys of a proplist 2012-05-26 01:32:43 +02:00
Günther Brammer 09d08298bf Replace C4AulContext* this of C4Script engine functions with C4PropList*
This mainly removes some indirection and a superfluous struct.
2012-05-15 03:03:47 +02:00
Günther Brammer 0e6f972de4 Remove unused C4Object* parameter from C4AulExecError 2012-05-15 03:11:23 +02:00
Günther Brammer 3a3ed01c89 Savegames: Save readonly proplists by their name
For example, the proplist in Clonk.ActMap.Walk is saved as DClonk.ActMap.Walk.
Should the script defining the proplist change while the savegame is stored,
the proplist will have the new contents instead of the old ones after savegame
load.

Also, save functions as DFlint.Hit instead of fDFlint.Hit. Loading uses the same
code as static proplist loading.

Curiously, this makes g++ 4.4 use the C4RefCntPointer move constructor,
which was broken until now. Fix it to take a mutable rvalue reference.
2012-06-01 17:27:59 +02:00
Günther Brammer 099cd15e56 Script: Remove unused OnBlastIncinerationDamage callback
Scenarios that want to override the default behaviour of BlastObject should
overload the BlastObject function itself. Objects can simply use the Damage
callback and/or set BlastIncinerate to nil.
2012-05-06 15:37:43 +02:00
Günther Brammer 2510734ad3 Script: Damage callback changed to Damage(Change, Cause, CausedByPlr) 2012-05-06 14:45:35 +02:00
Günther Brammer 752e945b8d Call C4PropList::Freeze in Link, remove now empty AfterLink functions
AfterLink was otherwise only used for the TimerCalls, which are now gone.
2012-05-06 00:06:33 +02:00
Günther Brammer 5e60806439 Move GetNeededMatStr to the other object functions 2012-04-28 22:01:47 +02:00
Günther Brammer 815d5a895a Replace remaining functions in ObjectScript table with template AddFunc 2012-04-28 22:04:43 +02:00
Günther Brammer 8a4181a3be Replace C4AulObjectContext* with a simple C4Object* parameter 2012-04-28 22:04:36 +02:00
Maikel de Vries 6fcc0f6d2e Removed TimerCall in favour of AddTimer script implementation 2012-05-05 12:09:44 +02:00
Maikel de Vries 7857da2c50 Check object rather than def for fire related properties 2012-04-29 10:21:16 +02:00
Günther Brammer 1a29f8625d Reorder engine source file organization a bit
This mostly consists of flattening the hierarchy, splitting the
graphics stuff out of platform, and a few smaller cleanups.
2012-04-27 19:04:43 +02:00