1
0
forked from mirrors/0ad
Commit Graph

17685 Commits

Author SHA1 Message Date
elexis e18598cd62 Fix Vector.js rotate oversight in 7778a7b436 (this.x may not be modified before reading again and sin/cos should not be computed twice).
Extend the tests of rotate in 99494251a1 to reveal the bug.
Add non-static clone functions for vectors (as the static ones were
incorrectly removed in e95f4e9744).
Math.pow performance is investigated separately, refs P85.

Checks and balances by mimo, leper, FeXoR and fatherbushido

This was SVN commit r20272.
2017-10-08 15:25:21 +00:00
Imarok 8bbe94c926 Add spies to the summary screen
Patch by: mmoains
Fixes: #4498
Differential Revision: https://code.wildfiregames.com/D567
This was SVN commit r20271.
2017-10-08 11:35:55 +00:00
mimo 9885cc5b79 petra: tune the proportion of support workers
This was SVN commit r20269.
2017-10-07 08:50:31 +00:00
mimo b5e3b83c9e Add a TerritoryDecayManager component to update territoryMap with the blinking state when territories are recomputed. That's needed by the AI which was up to now not aware of blinking cells.
Differential Revision: https://code.wildfiregames.com/D910
This was SVN commit r20268.
2017-10-07 08:42:39 +00:00
bb af9c25f879 Fix option page tabs xml style.
Following dd7f38e370 and 3312a83f82

Reviewed By: elexis
Differential Revision: https://code.wildfiregames.com/D949
This was SVN commit r20266.
2017-10-06 20:50:00 +00:00
elexis 1fcdc3d7f4 Deepfreeze the map settings object (created from g_GameAttributes.settings by the gamesetup extending the map JSON data) to prevent random map scripts from unintentionally modifying that, refs #4257.
This was SVN commit r20265.
2017-10-06 18:53:24 +00:00
elexis a8b8a33c8e Remove unneeded waterheight init loop from River Archipelago (refs #4354, D467).
Remove unneeded waterheight init loop (with awkward 1 tile sized bump)
that is redundant with the SmoothElevationPainter above from Corinthian
Isthmus (since introduction in 33cb23afa5).

This was SVN commit r20264.
2017-10-06 18:49:09 +00:00
elexis 7778a7b436 Readability improvements of globalscripts vector.js.
In compareLength, use Math.sign to replace a ternary + isNaN check.
In distanceToSquared, Use Math.pow(distance, 2) to avoid repetition of
the distance, inline its value to remove the then unneeded variables.

This was SVN commit r20263.
2017-10-06 18:20:57 +00:00
elexis 99494251a1 Add test for globalscripts vector, refs #4427.
This was SVN commit r20262.
2017-10-06 18:15:09 +00:00
mimo 2f24006afb petra: rework the management of siege units in attacks, to remove some civ hardcodings + some cleanup
This was SVN commit r20260.
2017-10-04 16:29:25 +00:00
mimo 862fd197d9 some cleanups of ai and petra
This was SVN commit r20257.
2017-10-02 17:49:27 +00:00
mimo 35af7390c0 Fix Hierarchical Pathfinder out of bounds bug
Patch by temple

Reviewed By: mimo
Differential Revision: https://code.wildfiregames.com/D926
This was SVN commit r20256.
2017-10-02 17:44:23 +00:00
bb 10277d4ee6 Equal siege status bar sizes
Patch By: temple
Differential Revision: https://code.wildfiregames.com/D942
This was SVN commit r20254.
2017-10-01 16:50:08 +00:00
mimo 365dea222d petra: try to make a better use of ranged siege units
This was SVN commit r20253.
2017-10-01 09:26:07 +00:00
fatherbushido fca5022f9b Tweak the decay special filter: decay time is set in the rubble template. Refs D938.
This was SVN commit r20252.
2017-10-01 05:38:45 +00:00
Imarok 0da0eaea3b Fix repair hotkey and remove build command
Fix f7ff71e8d5
Ack by elexis
Differential Revision: https://code.wildfiregames.com/D358
This was SVN commit r20250.
2017-09-30 22:04:24 +00:00
Imarok 7a5c5100c0 Allow command line options to start with - or --
Reviewed by: mimo
Differential Revision: https://code.wildfiregames.com/D883
This was SVN commit r20249.
2017-09-30 16:12:18 +00:00
Imarok 9d232fd39a Domesticated animals shouldn't be visible in FOW
Reviewed by: Stan
Refs #3201
Differential Revision: https://code.wildfiregames.com/D891
This was SVN commit r20248.
2017-09-30 16:10:13 +00:00
leper 8629b83ed9 Remove unneeded include.
That was a leftover from a previous iteration of the code.

This was SVN commit r20247.
2017-09-30 15:29:13 +00:00
leper 84674911cc Switch back to an unplaceable filter for templates.
This removes FindAllPlaceableTemplates, replaces the few uses of it by
FindAllTemplates,
and makes that ignore all templates starting with special/ in addition
to those starting
with template_.

Now modders can use entirely different template organization schemes
(more folders, different
folders, etc) without having to edit a file that was never well
documented.

In conjunction with a few of the template moving patches preceding this
rubble/ and other/catafalque
are now placeable. The former now does not decay anymore and users that
want that should use the
decay| filter, the latter will be taken care of in #4762.

Return to making FindAllTemplates return all placeable templates again
(switch to unplaceable filter).

To reiterate the main point: Only templates starting with special/ or
template_ will not show up as
placeable in Atlas (or show up to code querying for all (placeable)
templates. If you want to add more
of those use one of these naming schemes (and possibly subfolders in
special/).

Reviewed By: fatherbushido
Differential Revision: https://code.wildfiregames.com/D935
This was SVN commit r20246.
2017-09-30 15:22:51 +00:00
fatherbushido 40cafe5049 Remove unneeded Vision and UnitMotion properties from gaia templates.
Reviewed By: elexis
Differential Revision: https://code.wildfiregames.com/D941
This was SVN commit r20245.
2017-09-30 14:57:12 +00:00
leper b78896dfa6 Make rubble non-decaying by default.
Explicitly specify that the rubble placed on death is decaying.
This breaks quite a few mods, then again the fix is a simple sed
command.
Run within your mod root directory:
sed -i 's,>rubble/,>decay|rubble/,' `find simulation/templates -name
'*.xml'`

For fields you can just edit the few templates manually and specify
decay_60 instead.

Reviewed By: fatherbushido
Differential Revision: https://code.wildfiregames.com/D938
This was SVN commit r20244.
2017-09-30 13:50:39 +00:00
leper ff7511d9fc Move special_filter/ templates to special/filter/.
This should help with simplifying the (un)placeable filtering again.

Reviewed By: fatherbushido
Differential Revision: https://code.wildfiregames.com/D934
This was SVN commit r20242.
2017-09-30 07:14:35 +00:00
leper a85c532f8f Move formations/ templates to special/formations/.
This should help with simplifying the (un)placeable filtering again.

Reviewed By: fatherbushido
Differential Revision: https://code.wildfiregames.com/D933
This was SVN commit r20241.
2017-09-30 06:51:56 +00:00
fatherbushido 8c15a81c58 Removed health leftover from Seleucid wonder.
Patch By: Nescio
Differential Revision: https://code.wildfiregames.com/D936
This was SVN commit r20240.
2017-09-29 18:52:05 +00:00
mimo a9f95feb42 fix missing parenthese in 49758c8337 and some other minor changes"
This was SVN commit r20239.
2017-09-29 16:58:25 +00:00
fatherbushido b1d71bfb43 Add a new function to emit a sound from a position not attached to an entity. Use it to improve the attack impact sound code and allow to emit that sound even if the attacker died meanwhile. Use the sound provided by Pureon for catapult. Fix #4779.
Patch By: Mate-86
Differential Revision: https://code.wildfiregames.com/D921
This was SVN commit r20236.
2017-09-28 19:26:07 +00:00
mimo 49758c8337 petra: various minor fixes
This was SVN commit r20234.
2017-09-27 18:58:51 +00:00
elexis 995f9b5975 Northern lights river cleanup following 7d0cc59136.
This was SVN commit r20233.
2017-09-27 14:35:46 +00:00
fatherbushido bebcd56a84 Leftover in fb6748d723.
This was SVN commit r20231.
2017-09-26 10:06:31 +00:00
fatherbushido fb6748d723 Use relative templates for unit speed. No significant value change. It makes balancing easier and will permit to change the speed of all units by changing one number. Refs #4352.
Differential Revision: https://code.wildfiregames.com/D930
This was SVN commit r20230.
2017-09-25 18:27:18 +00:00
mimo c6c02eb081 petra: refactor a bit the defense code to ease future changes
This was SVN commit r20229.
2017-09-25 17:20:15 +00:00
bb 6b9acadda4 Match house obstructions visually and cleanup some related template data.
No more loot for ptol building
Equal territory influence for small houses

Patch By: temple
Differential Revision: https://code.wildfiregames.com/D723
This was SVN commit r20227.
2017-09-24 16:15:13 +00:00
bb 026b04d345 Improve acoustic GUI notifications
Patch By: Polakrity
Reviewed By: elexis, bb
Differential Revision: https://code.wildfiregames.com/D821
This was SVN commit r20226.
2017-09-24 12:20:11 +00:00
bb b1f0bd2974 Resize storehouse so obstructions matches visually
Patch By: temple
Differential Revision: https://code.wildfiregames.com/D727
This was SVN commit r20225.
2017-09-24 11:28:23 +00:00
bb 9c23af265a Align session panels
Patch By: temple
Reviewed By: elexis, bb
Differential Revision: https://code.wildfiregames.com/D922
This was SVN commit r20224.
2017-09-24 10:13:34 +00:00
mimo 12bd37f70b Revisit the random walk of animals
Reviewed By: O2 JS Simulation, bb
Differential Revision: https://code.wildfiregames.com/D927
This was SVN commit r20223.
2017-09-24 09:44:59 +00:00
elexis d3301a6161 Fix division by zero in 0d0bc32736 and 25682da568 for the gulf map layout with only one player.
This was SVN commit r20222.
2017-09-23 13:28:43 +00:00
elexis 1f1a9ffbf1 Fix oversights in ba36f233fa (missing brace removal in latium) and 635e608776 (missing startAngle argument).
missing starting

This was SVN commit r20221.
2017-09-23 13:23:49 +00:00
Pureon 03862937a6 Removed stereo channel
This was SVN commit r20219.
2017-09-22 21:41:25 +00:00
bb 69ad6f9b97 Make corral obstruction and footprint match the actual building size.
Use correct rubbles and foundation actors also.

Patch By: temple
Differential Revision: https://code.wildfiregames.com/D728
This was SVN commit r20218.
2017-09-22 19:21:58 +00:00
mimo 3fa38fe480 petra: some fixes in attacks (choice of target and withdrawal)
This was SVN commit r20217.
2017-09-22 17:53:01 +00:00
fatherbushido 4e62ad38fe Remove some wrong references in root templates.
Differential Revision: https://code.wildfiregames.com/D923
This was SVN commit r20216.
2017-09-22 16:58:31 +00:00
fatherbushido da03e1a528 Get rid of special_units templates for packable siege units. Refs #1718.
Reviewed By: elexis
Differential Revision: https://code.wildfiregames.com/D925
This was SVN commit r20215.
2017-09-22 16:11:45 +00:00
bb 3d95c43430 Add footprint and obstruction sizes in skirmish farmstead fixing 2e02c88d2c
Using the policy to add the largest sizes of the civ-specific structures
to the default_skirmish template, to prevent overlapping.

Reviewed By: fatherbushido, temple
Differential Revision: https://code.wildfiregames.com/D919
This was SVN commit r20214.
2017-09-22 15:34:03 +00:00
Pureon 6c5b67e890 Some new siege projectile impact sounds
This was SVN commit r20211.
2017-09-21 22:40:39 +00:00
mimo c1684ccd5f ConquestCritical consistency
Patch by Nescio

Reviewed By: mimo
Differential Revision: https://code.wildfiregames.com/D892
This was SVN commit r20210.
2017-09-20 18:00:20 +00:00
mimo 11009c56b7 petra: do not try to defend some structures in blinking territories that the AI has no chance to defend.
(Will only be effective when D910 is commited as currently the blinking
tiles are not transfered to the AI)

This was SVN commit r20209.
2017-09-20 17:54:53 +00:00
fatherbushido 2a46552c2e Fix a wrong sound file reference.
This was SVN commit r20208.
2017-09-20 13:04:16 +00:00
mimo 123f732a15 petra: fix a bug when choosing the best unit for a given task, and cleanup a bit that function from unused stuff
This was SVN commit r20206.
2017-09-19 20:30:10 +00:00