Removing strict binding of selection to footprint by adding optional
choice similar in footprint. If present, that one will be used, else it
will fallback to footprint size.
Allowing to use any selection shape without affecting gameplay, because
foorprint is used for projectile hit detection.
Differential revision: https://code.wildfiregames.com/D2844
Reviewed by: wraitii
This was SVN commit r23900.
Units in formation can occasionally request many short paths (and thus
introduce crippling lag) if their offset is obstructed.
This particularly happen when the formation is idle, since the offset
then always remains obstructed.
To prevent this, it is OK to immediately stop pathing on any motion
message (obstructed, failure, success). This does not break formation
movement since messages are only sent when the formation controller is
not moving (this finishes what was started in 0535eb9b92).
Ideally, this hack could be removed if the short-pathfinder was quick
enough / units were better at aborting.
Fixes concern raised by Freagarach on a7da40ac2f.
Refs #5624 in that the max-short-path range is the source of the lag.
Reviewed By: Angen
Differential Revision: https://code.wildfiregames.com/D2871
This was SVN commit r23867.
Patch By: pcpa and wraitii
Tested By: Nescio, andy5995 and others
Differential Revision: https://code.wildfiregames.com/D2745
This was SVN commit r23794.
Changing Grid.h should recompile faster, as it is now included in fewer
TUs.
Differential Revision: https://code.wildfiregames.com/D2784
This was SVN commit r23774.
This lets it support the JSClass syntax, introduced for components in
5fb88172a2/D2492, which required a workaround before.
As cleanup, remove the prefix logic which was too specific to be in
ScriptInterface, and use an upstream-compatible API that also does more
of what we want.
Based on a patch by: elexis
Differential Revision: https://code.wildfiregames.com/D2644
This was SVN commit r23771.
Range manager has several `std::vector` for fixed-size arrays and 2D
grids. By using proper data structures, the code readability is
improved.
This also moves around the LosVisibility enum.
Comments by: Stan`, nani
Differential Revision: https://code.wildfiregames.com/D2770
This was SVN commit r23769.
This is the same commit as 2abd9cead2 / D1418, fixing noted issues.
This addresses two related issues:
- Units visibly garrisoned on gates keep the gate open.
- Units visibly garrisoned on entities keep their pathfinding blocker
flags.
De-activate the obstruction of visibly-garrisoned entities, fixing the
2nd issue.
Keep a list of entities that cannot move and thus should not count
towards gate-opening logic.
Packing logic is kept separate: it is more related to entities having
'alternate forms' with different capabilities than being currently
incapable of moving.
Based on work by temple
Fixes#2679.
Fixes#5151.
Differential Revision: https://code.wildfiregames.com/D2775
This was SVN commit r23731.
Player-testing has revealed QA issues, so reverting these for now.
Differential Revision: https://code.wildfiregames.com/D2773
This was SVN commit r23714.
This addresses two related issues:
- Units visibly garrisoned on gates keep the gate open.
- Units visibly garrisoned on entities keep their pathfinding blocker
flags.
Remove the block-movement flag from visibly garrisoned entities.
Keep a list of entities that cannot move and thus should not count
towards gate-opening logic.
Packing logic is kept separate: it is more related to entities having
'alternate forms' with different capabilities than being currently
incapable of moving.
Based on work by temple
Comments by: Freagarach
Tested by: Nescio
Fixes#2679Fixes#5151
Differential Revision: https://code.wildfiregames.com/D1418
This was SVN commit r23710.
This fixes an off-by-one error that led to entities sometimes getting
stuck against obstructions.
It also increases the max-range of the short pathfinder to help entities
find their way around corridors and house blocks.
Fixes 2ff8614ce2 (off-by-one error) and reverts the range changes from
32e8ed51aa
Reported By: Freagarach
Fixes#5586 . Refs #5624
Differential Revision: https://code.wildfiregames.com/D2754
This was SVN commit r23699.
This allows Atlas not to rely on eval() to get access to the attack
component.
Add a quick test for the added method.
This fixes the animation speed matching that of the actor instead of the
template.
Remove some dead code after af2abb8cbfFixes: #5129
Reviewed by: @Angen
Comments by: @elexis
Differential Revision: https://code.wildfiregames.com/D2464
This was SVN commit r23592.
This is adding support to handle garrisoned entities defined in map
files by game engine and atlas allowing future extension for atlas ui
and solving recreation of entites on init in D1958. Also solving
deepfreeze described in D2562.
Differential Revision; https://code.wildfiregames.com/D2597
Ticket: #3008
Patch by: Freagarach
Comments by: elexis
This was SVN commit r23529.
Check for player being out of bounds after m_TerritoryCellCounts may be
recomputed.
Differential Revision: https://code.wildfiregames.com/D2046
Reviewed by: @Stan
This was SVN commit r23510.
Fail movement for formationmember when cannot find path to destination
and formationcontroller is not moving so formationmember will enter idle
state or follow next command relying on member stopping movement first.
Introduced in a1dc9cadd8.
Differentail Revision: https://code.wildfiregames.com/D2438
This was SVN commit r23496.
Avoids computing the square of the compared value every call.
Differential Revision: https://code.wildfiregames.com/D2058
Reviewed By: Vladislav
This was SVN commit r23489.
a8f48ff7e0 introduced XeroXMB lowercasing of element and attribute names
as a feature.
cf9d8b9797, 4d390f501c, dda6268466 added bugfixes and TODOs because of
that.
f76d0ffdc6, 44fe226dd2 removed the XeroXMB lowercase feature.
This patch removes the lowercasing GUI bugfixes that don't fix any bug
anymore while increasing code complexity and lowering performance
(string copies).
Do not send mouse coordinates objects for events that do not relate to
the mouse.
Store event names in static const members to:
(1) improve performance, ensuring that the CStr is not reconstructed
every call,
(2) obtain compile errors when misspelling event names,
(3) allow reuse of the strings in inherited and friend classes.
Differential Revision: https://code.wildfiregames.com/D2445
Comments by Matei, Philip on 2006-03-11-QuakeNet-#wfg-Meeting-0126.log
and 2006-06-24-QuakeNet-#wfg-Meeting-0139.log
This was SVN commit r23403.
Allows to place buildings a bit faster and more perfectly aligned. Also
it helps to find a nearest placeable position in some cases.
Reviewed By: elexis
Comments By: Stan, wraitii
Differential Revision: https://code.wildfiregames.com/D2079
This was SVN commit r23330.
Problem description:
When unit gets command to move to the range exactly X units from some
point/entity, what means minRange == maxRange, that triggers computing
goal when distance < minRange with result distance(goal, target) >
maxRange, because minRange computation uses clearance even when is
treating target as circle.
Solution:
Do not use clearance when treating target as circle, so computation when
distance < minimum range is done in same way as computation when
distance > maximum range and so computed goal has correct position.
Reported on forum:
https://wildfiregames.com/forum/index.php?/topic/27384-strange-landing-on-the-island-and-unable-to-attack/
Differential Revision: https://code.wildfiregames.com/D2512
Tested by: gameboy
This was SVN commit r23283.
In 32e8ed51aa have been changed message from MotionChanged to
MotionUpdate and CMessageMotionUpdate::FromJSVal was not implemented to
reflect changes in message structure.
As a result UnitMotionFlying tries to send MotionChanged message which
not only was renamed, but sending it from js is not supported anymore.
Also reported at this thread:
https://wildfiregames.com/forum/index.php?/topic/27294-cheats-error/
Differential Revision: https://code.wildfiregames.com/D2450
Tested by: @gameboy
Tested on: Jenkins/vs2015, Jenkins/gcc6
Fixes: #5626
This was SVN commit r23208.
Replace boost::hash_combine with a lib/hash.h hash_combine performing
the same statement.
Replace inconspicuous global boost hash_value specializations with
std::hash specializations.
No performance difference was observed in three simple MeshManager
measurements.
Remove unused TAG_MASK and h_tag in h_mgr.cpp following 0748c5a75e.
Replace typedef with using keyword and sort header includes.
Differential Revision: https://code.wildfiregames.com/D2441
Tested on: clang 9.0.0, gcc 9.2.0, Jenkins/vs2015, Jenkins/gcc6
This was SVN commit r23191.
Replace std::deque by std::vector
Replace some casts by cpp casts
Move the class and struct declaration to a separate file for clarity.
Fixes db864f10c3 by removing offending function
Refs #5288
Refs D1681
Reviewed by: @vladislavbelov
Differential Revision: https://code.wildfiregames.com/D1682
This was SVN commit r23029.
Remove gui/common/ hack by going through the GUIInterface and fragile
EndGame() hardcoding by saving if and only if a ReplayLogger exists
following 7470e88624, refs #4020.
Refs D2211, D2213.
Differential Revision: https://code.wildfiregames.com/D2197
Based on patch by: irishninja
Tested on: clang 8.0.1, Jenkins
This was SVN commit r22991.
Following d592bf9cb6, paths were computed at the end of turn N, and then
messages were sent at the beginning of turn N+1. However, the path
requests were removed at the end of turn N and so weren't serialised,
and neither were computed paths. This meant rejoiners would OOS when the
game was serialised with pending path results.
To fix this in preparation for threading, the architecture needs to
change slightly so that requests are kept and serialised correctly, and
rejoiners can compute the paths after deserialisation, in order to send
the messages at the beginning of turn N+1.
Fixes#5604
Reported By: elexis
Differential Revision: https://code.wildfiregames.com/D2317
This was SVN commit r22979.
Simply pass the JS value to the Save functions instead of letting those
obtain the data later from the topmost GUI page.
The JS hack incidence appears to be unused since 4b1297b328.
Differential Revision: https://code.wildfiregames.com/D2302
Tested on: clang 8.0.1, Jenkins
This was SVN commit r22922.
This moves the "async" pathfinding computations to a worker, preparing
the architecture for threading.
Tested By: Kuba386, Stan`
Differential Revision: https://code.wildfiregames.com/D1918
This was SVN commit r22902.
Make that function static, so that it can be used for these functions
without slowly having to obtain the ScriptInterface instance using
GetScriptInterfaceAndCBData just to get the JSContext again.
Remove few redundant conversions for CreateObject arguments.
Differential Revision: https://code.wildfiregames.com/D2128
Tested on: gcc 9.1.0, clang 8.0.1, Jenkins
Tedious performance testing in: D2128, D2127
This was SVN commit r22894.
D1987/99a341f379 introduced logic to predict the target movement, which
fixed unit chasing. However, sometimes fleeing units would then predict
that their target will end up in front of them, so they turned around
towards the attacker.
This is fixed by not anticipating the position when it would cause the
vector towards to target to change direction.
Reported By: Freagarach
Tested By: Freagarach
Fixes#5541
Differential Revision: https://code.wildfiregames.com/D2275
This was SVN commit r22885.
These variables might be used uninitialised in very odd cases that don't
happen in svn.
Reported By: elexis
Differential Revision: https://code.wildfiregames.com/D2250
This was SVN commit r22877.
Local entities being in the destruction queue when serialising is not an
issue since those should not affect the simulation anyways. This stops
the game from crashing in some rare situations.
Fixes#4616
Differential Revision: https://code.wildfiregames.com/D1738
This was SVN commit r22865.