Commit Graph

8492 Commits (4257b84f84bf408046c1f976ca0467b8bd937d24)
 

Author SHA1 Message Date
Sven Eberhardt 4257b84f84 Fix HUD script errors when cursor does not include inventory control 2016-01-24 18:16:46 -05:00
Maikel de Vries 1cce689a67 boomrace: fix picking up boompacks (now instantly) 2016-01-24 23:28:05 +01:00
Sven Eberhardt 451ea87ab9 Fix another FoW crash 2016-01-24 17:23:20 -05:00
Sven Eberhardt 42d8885877 Fix crash in FoW rendering #1643 2016-01-24 14:44:00 -05:00
Maikel de Vries 488201181b improve collision detection of deployed balloon with the landscape 2016-01-24 20:36:17 +01:00
Maikel de Vries d1d019ab09 improve the hitbox of the balloon for projectile targets
This prevents the one hanging on the balloon from shooting himself down with e.g. a bow.
2016-01-24 20:36:17 +01:00
Mark 93ba7c5954 Vendor Library
Extracted the buy menu of the flagpole to a library, so that other objects can implement a buy menu without having to duplicate the code. An overview of the changes follows:

Library_Base:
- Moved auto-sell functionality to Library_Vendor
- Moved buy and sell functionality to Library_Vendor
- Removed the old engine menu for buying and selling

Library_Vendor:
- Added proplist for accessing local variables, avoiding variable clashes
- Added interfaces GetBuyValue, GetBuyableItems, GetBuyableAmount, ChangeBuyableAmount, GetSellValue
- Changed DoBuy: it uses the interface functions, instead of hardcoded base material
- Changed / merged the existing sell functionality and the flagpole sell functionality in DoSell:
   * does not sell items if QueryOnSell returns true
   * sell sound only audible to seller
   * the sold object tries selling its contents first (for example a bow, if it ever were sellable. This may not hold in the settlement games, but adventures would allow it)
   * the sold object ejects any contents before it is removed. These are usually unsellable objects. Previously they would just be removed together with the object. It has to be tested whether this places the items on the ground or at the center of the sold object
   * removed the "sell all" functionality on right-click for the moment.
- Still has some functions from the old base selling: CanStack and GetSellableContents, for the auto-sell functionality
- Fixed a logical error in AllowBuyMenuEntries
- Distinguish between buyer/seller and payer more, so that the logic can easily be changed in one line later
- Allow for runtime overloads of interface functions
- Changed inconsistent variable naming to a more consistent one
- Added namespaces to all sounds, the "UnCash" sound still does not exist
- Added localization strings for insufficient wealth
- Fixed property name error (missing 'e')
- Buy menu is active by default

Flagpole:
- Replaced the custom sell functionality (how many of these do we have actually??) with the sell functionality from Library_Vendor
- Buying menu is allowed if the rule is active

System.ocg/Object.c
- global functions Buy and Sell ask the target if it is a vendor, instead of whether it is a base, and do the callback there.
- renamed the argument so that it is no longer called "base", but "vendor"
2016-01-24 20:11:27 +01:00
Maikel de Vries c4fa92a6d2 Aerobatics: use jet streams, fix item spawn and restart rule 2016-01-24 18:18:12 +01:00
Maikel de Vries ab9330180f add an object for jet stream control (fast winds) 2016-01-24 18:17:10 +01:00
Maikel de Vries e5a9dd934f add option to respawn rule to keep contents 2016-01-24 18:05:06 +01:00
Günther Brammer d0d27d25f1 Merge script branch 2016-01-24 12:25:52 +01:00
Günther Brammer 4d1f5d95c2 Script: Prevent usage of deleted objects via this()
Apparently, this wasn't done already because of compatibility concerns. The
beginning of a release cycle is the perfect moment to finally complete the
prevention of using deleted objects from script.
2016-01-24 12:25:15 +01:00
Sven Eberhardt d9b8de9ea2 Win32: Fix file deletion from scenario selection dialogue 2016-01-24 00:43:09 -05:00
Sven Eberhardt 28e794654c Add network option to disable UPnP.
Also add some more UPnP failure messages to log.
2016-01-24 00:11:14 -05:00
Sven Eberhardt f2e99ced16 HotIce: Reduce Fire arrow stack count in chests
Fire arrows were dominating the game too much. This should put more emphasize on the other weapons.
2016-01-23 23:27:08 -05:00
Sven Eberhardt 79e26a3f64 HotIce: Fix division by zero when starting with one player. 2016-01-23 23:25:48 -05:00
Sven Eberhardt 7b7b791442 Add [Game] Mode to parkour and arena scenarios to fix league evaluation. 2016-01-23 21:26:13 -05:00
Sven Eberhardt e94c0e38fc Add scenario core field "Mode" (in [Game]) to allow setting game mode independent of goal objects.
To be used by the league so you can properly host race scenarios in the open melee league.
2016-01-23 21:19:22 -05:00
Sven Eberhardt df6d349166 Add safety to light object creation. 2016-01-23 21:09:12 -05:00
Günther Brammer 7c022085ee Improve script bytecode dump formatting slightly 2016-01-24 02:09:15 +01:00
Günther Brammer 27cbdb2177 Remove superfluous mape stubs 2016-01-24 02:09:14 +01:00
Günther Brammer e790d2c327 Remove duplicated stubs for the scriptengine from mape 2016-01-24 02:09:14 +01:00
Günther Brammer 5a570b96f1 Remove now unnecessary stubs from C4ScriptStandaloneStubs 2016-01-24 02:09:14 +01:00
Günther Brammer 6b6dd96719 Move GameScript.GRBroadCast to Game.GRBroadCast
This avoids a dependency on ::Objects from C4ScriptHost.
2016-01-24 02:09:14 +01:00
Günther Brammer e1a38ee010 Move references to ::Objects and ::MaterialMap from C4AulLink to C4Game
This changes the order in which the various parts of the engine are updated
after a definition reload, but they should not interfere with each other.
2016-01-24 02:09:14 +01:00
Günther Brammer a5f797f96b Move miscellaneous global functions from C4Effect.cpp to their users 2016-01-24 02:09:14 +01:00
Günther Brammer 9833c1ef2d Remove never used NeedDefinitionContext
Every function that accepts a definition also accepts an object instead, so
NeedNonGlobalContext is the exception to use.
2016-01-24 02:09:13 +01:00
Günther Brammer b7ecc49a02 Remove a bit of dead code from C4Value 2016-01-24 02:09:13 +01:00
Günther Brammer d81c93b7d4 Add a few C4Script tests 2016-01-24 02:09:13 +01:00
Tobias Zwick a7943714c8 update ala's music license (in the installer) 2016-01-24 00:25:33 +01:00
Maikel de Vries 6a3eaa2716 Aerobatics: new game mode and small improvements 2016-01-24 00:20:04 +01:00
Nicolas Hake 03c0933d6f Merge MSVC cleanup branch 2016-01-23 23:24:50 +01:00
Günther Brammer 78e3457ff7 MSVC: Remove support and workarounds for versions older than 2015
We require that version for its C++14 support anyway.
2016-01-23 23:10:02 +01:00
Günther Brammer a19e7f6ced Use #elif defined() to check for config.h macros instead of plain #elif
This way, the code works with a config.h that does not define those macros.
2016-01-23 23:05:16 +01:00
Günther Brammer 609b64f72b Remove unused macro from config.h.cmake
HAVE_PRECOMPILED_HEADERS is only used internally in CMakeLists.txt.
2016-01-23 23:05:16 +01:00
Günther Brammer 7167459f67 win32: Move PIXELFORMATDESCRIPTOR from C4AbstractApp to CStdGLCtx
That is the only user.
2016-01-23 22:02:52 +01:00
Günther Brammer 34a720ca54 win32: Remove unused CreateContext function taking a HWND 2016-01-23 22:02:52 +01:00
Günther Brammer 37fd0a88c6 win32: Rename C4Window::hRenderWindow to renderwnd to match GTK+ 2016-01-23 22:02:52 +01:00
Günther Brammer 9210c65e85 gtk: Hide usages of X11 behind #ifdef GDK_WINDOWING_X11 2016-01-23 22:02:51 +01:00
Günther Brammer aa931ac623 Drop some dead code in C4App.h and C4WindowGTK.cpp 2016-01-23 20:36:34 +01:00
Günther Brammer 1c15b8f661 gtk: Move OpenURL to the other implementations in PlatfromAbstraction 2016-01-23 20:36:34 +01:00
Günther Brammer 8f48f0275d gtk: Remove unnecessary C4Window::wnd
It was only used to specify a screen for randr, which doesn't need a
particular window.
2016-01-23 20:36:34 +01:00
Günther Brammer 93f12150c4 CMake: Remove obsolete USE_X11 option and add USE_WIN32_WINDOWS
USE_WIN32_WINDOWS was previously defined in PlatformAbstraction.h. Move it
to CMakeLists.txt and config.h like its peers. Replace USE_X11 with USE_GTK
or GDK_WINDOWING_X11 as appropriate.
2016-01-23 20:36:34 +01:00
Günther Brammer 11bbeb2a5b Rename WITH_DEVELOPER_MODE to USE_GTK
This mirrors USE_WIN32_WINDOWS, USE_SDL_MAINLOOP and USE_COCOA.
2016-01-23 20:36:33 +01:00
Günther Brammer d09ed41eea Avoid an OpenGL dependency in C4Surface.h 2016-01-23 20:36:33 +01:00
Maikel de Vries d31792f1d7 increase version to 8.0 alpha 2016-01-23 19:56:53 +01:00
Maikel de Vries 93c20b19a0 improve parkour scoreboard column descriptions 2016-01-23 18:24:30 +01:00
Maikel de Vries d7d2f8f39f fix showing description in the playground item spawn menu 2016-01-23 16:42:37 +01:00
Maikel de Vries 84218d1cbc merge UsageHelp into Description
This is better for the new interaction menu, since only the description is shown for items, but it can be longer now.
2016-01-23 16:28:02 +01:00
Maikel de Vries 7d46ab9f26 add new parkour aerobatics (sky race) (#1550) 2016-01-23 14:46:33 +01:00