1
0
forked from 0ad/0ad
Commit Graph

20906 Commits

Author SHA1 Message Date
e98fce58a6 Move some position-related functions to PositionHelper.
Renames helper Entity.js to Position.js and moves to there:
- `EntitiesNearPoint` (from Attacking.js).
- `InterpolatedLocation` (from Attacking.js).
- `TestCollision` (from Attacking.js).
- `PredictTimeToTarget` (from Attack.js).

Also adds a test for the helper.

Differential Revision: D2940
Reviewed By: @wraitii
Comments by: @Stan, @vladislavbelov
This was SVN commit r24128.
2020-11-04 18:56:45 +00:00
0addd691d1 Remove some unneeded comments in UnitAI.js.
Differential Revision: D3045
Reviewed By: @bb
This was SVN commit r24127.
2020-11-04 17:50:20 +00:00
2d54653bc3 Little cleanup of PatchRData by reordering includes and correctly formats some loops.
This was SVN commit r24126.
2020-11-04 15:53:33 +00:00
c64f8824d7 Fixes wireframe mode for terrain, continuing remove fixed pipeline dependencies.
Commented By: Stan, wraitii
Tested By: Stan
Differential Revision: https://code.wildfiregames.com/D3056
This was SVN commit r24125.
2020-11-04 15:52:26 +00:00
d7d02a4740 Moves terrain lighting calculation to GPU.
Reviewed By: wraitii
Tested By: OptimusShepard, Stan, wraitii
Differential Revision: https://code.wildfiregames.com/D3052
This was SVN commit r24124.
2020-11-04 12:54:17 +00:00
770280436b Removes FFP option from Atlas and adds ARB/GLSL selection.
Tested By: Stan
Differential Revision: https://code.wildfiregames.com/D3055
This was SVN commit r24123.
2020-11-04 12:21:55 +00:00
6e3db3d84c Removes remaining fixed program used in shader pipelines and adds check on FFP create.
Commented By: Stan
Differential Revision: https://code.wildfiregames.com/D3048
This was SVN commit r24121.
2020-11-03 18:59:27 +00:00
8e547cdce5 Add num pad hotkey equivalents.
Such that now e.g. control groups can be selected using those.

Patch by: @Nescio
Differential Revision: D3029
Accepted by: @wraitii
This was SVN commit r24120.
2020-11-03 18:16:19 +00:00
478f96d0fd Fix Atlas crash in RangeManager following 939002f0dc
939002f0dc changed from vectors to grid which broke resetting when
terrain size changed.
Also use SAFE_ARRAY_DELETE for simplicity.

Reported by: vladislavbelov
Reviewed By: vladislavbelov
Differential Revision: https://code.wildfiregames.com/D2961
This was SVN commit r24117.
2020-10-31 10:21:08 +00:00
413003fe4f Fix a compartment mismatch in XmppClient, causing crashes in MP games.
Added in 9023f4bebb, which changed lobby GUI messages to JS::Values,
requiring a real context. The original code mistakenly inverted the
owning script interfaces.

Given the reproducibility discovered in SM52, the timeline of the bug,
and the nature of the issues encountered in MP, this is a rather safe
fix for #5655.

Reviewed By: Itms
Fixes #5655

Differential Revision: https://code.wildfiregames.com/D2922
This was SVN commit r24116.
2020-10-31 10:13:33 +00:00
726d59a995 Make PlayerHasMarket event-based.
This function is currently polling-based, and called by the GUI on each
turn, which results in a big performance hit.

Use the opportunity to rename the set of functions with more generic
names.

Reviewed By: Freagarach, wraitii
Differential Revision: https://code.wildfiregames.com/D2919
This was SVN commit r24114.
2020-10-29 09:22:48 +00:00
03f9522ff4 Remove useless SDL debug message introduced in 5593f573f4.
Reviewed by: @vladislavbelov
Differential Revision: https://code.wildfiregames.com/D3050
This was SVN commit r24112.
2020-10-27 21:19:33 +00:00
acc254533b Refactors water shader to move refraction in a separate function.
Commented By: Angen, asterix, linkmauve, Stan, wraitii
Reviewed By: Angen
Tested By: Angen, asterix, linkmauve, Stan
Differential Revision: https://code.wildfiregames.com/D2908
This was SVN commit r24110.
2020-10-25 21:00:52 +00:00
Angen
a7b4d42032 Fix handling of fixed ai defined by map after 5ca68a38ef
Gamesetup fails to handle cases with fixed ai 5ca68a38ef.
Removing wrong 'this' and checking for 'undefined' to fix additional
warnings when switching maps.

Differential Revision: D3038
Fixes: #5844

This was SVN commit r24109.
2020-10-24 12:11:24 +00:00
wackyserious
ba1bd070bc New Texture: Oscan Tunics (Carthaginian)
Thread: https://wildfiregames.com/forum/topic/31654-task-oscan-tunic/

This was SVN commit r24107.
2020-10-22 06:37:33 +00:00
wackyserious
c9a61c7c4a New Texture: 1.) Thracian Mercenary (Seleucid and Macedonian) 2.) Rhodian Slinger (Macedonian)
Thread:
https://wildfiregames.com/forum/topic/31815-task-thracian-mercenary-seleucid-texture-update/

This was SVN commit r24106.
2020-10-22 06:10:11 +00:00
1582e80ccf Clean up structure templates.
- Purge unnecessary attack sounds and buildingAI-nodes.
- Define some sounds, health and territoryInfluence in children when
most of them override parent.
- Remove unused `<BuildRestrictions/Category>` reverts 9af7747d76, part
of cdcee291cf, references 5e3049f6b2. Categories can be added when
necessary.

Patch by: @Nescio.
Differential Revision: D3016
This was SVN commit r24104.
2020-10-15 11:07:35 +00:00
93ecc1af4c Fix texture mismatch noticed by wowgetoffyourcellphone. Ptolemies were using black Pharaohs instead of white ones.
Unify textures for kushites and ptolemies.
Add back the kush_struct_02.png file with a proper name this time
Some textures fixes from delenda est.
Delete the old textures and use correctly desaturated version of those.

Refs: 7943d82bfe & d8c7f6da62

This was SVN commit r24103.
2020-10-15 07:14:11 +00:00
Angen
dcdc17b2dd Do not use GPUSkinning without glsl [Crash fix]
Disable GPUSkinning when glsl is disabled, because VertexAttribPointer
is not implemented on ARB/GLES and it is called by GPUSkinning.

Differential Revision: D2423
Reviewed by: vladislavbelov
Fixes: #5635

This was SVN commit r24101.
2020-10-13 16:48:04 +00:00
4eb13e620a Refactors water shader to move refraction in a separate function.
Tested By: Freagarach, Stan
Differential Revision: https://code.wildfiregames.com/D3028
This was SVN commit r24100.
2020-10-12 19:37:45 +00:00
11c94cd92b Use stones instead of arrows for quinqueremes. Noticed by Edwarf.
This was SVN commit r24099.
2020-10-12 16:37:52 +00:00
62a86fe15f Improved patrol icon. Much less like the recycling logo
This was SVN commit r24096.
2020-10-10 16:22:50 +00:00
bb
c93bd91ef6 Do not hardcode attacktypes in the engine/Atlas
fixes 0ad79096bd
refs #252, D368
Reviewed By: vladislavbelov
Comments By: Stan, wraitii
Differential Revision: D2998
This was SVN commit r24095.
2020-10-10 15:12:17 +00:00
76ebb66241 Moves textures samples and calculations in the water shader to related parts of the code.
Fixes visible foams through fog.

This was SVN commit r24093.
2020-10-07 19:03:40 +00:00
5dd0d7752e Refactors water shader to move reflection in a separate function.
Commented By: Stan
Reviewed By: wraitii
Differential Revision: https://code.wildfiregames.com/D3027
This was SVN commit r24092.
2020-10-07 18:38:56 +00:00
d8c7f6da62 Remove a bunch of unused/duplicated textures. The duplicated ones might have an impact on performance for older machines. Script by @vladislavbelov.
This was SVN commit r24089.
2020-10-04 21:01:06 +00:00
Angen
0bfaedb78d Do not allow upgrading when entity is producing and vice versa.
Before this patch, when entity was upgrading and producing and finished
upgrading before production, production was canceled. That meant player
assumed unit/tech will be ready in certain time but it will not. Also
fixing interference between upgrade and production animations.

Differential Revision: D2652
Reviewed by: bb
Comments by: Stan, Freagarach
Fixes: #5749
Refs: #2706

This was SVN commit r24088.
2020-10-04 10:20:20 +00:00
acfd466c32 Fixes crash with mod packing on a wrong path.
Reviewed By: Stan
Differential Revision: https://code.wildfiregames.com/D3026
This was SVN commit r24087.
2020-10-04 10:17:34 +00:00
wackyserious
fd4635e423 New Texture: Brasidas (Sparta)
Thread:
https://wildfiregames.com/forum/topic/28415-feature-hero-upgrades/?do=findComment&comment=401215

This was SVN commit r24086.
2020-10-03 13:53:25 +00:00
wackyserious
ef71863613 Texture and actor file fix: Gauls and Britons (Plus new textures for Briton units)
- Fixed the issues reported by Stan and Nescio (Changeset [24082] and
[24081])

This was SVN commit r24085.
2020-10-03 13:32:55 +00:00
3e372ccd34 Remove Babylonian lion from Persian barracks.
Patch by: @Nescio
Differential Revision: https://code.wildfiregames.com/D3011
This was SVN commit r24083.
2020-10-02 18:28:00 +00:00
wackyserious
bfa95074e2 Texture Update: Gaul actor file and texture update (including Briton elite spearman texture)
Thread:
https://wildfiregames.com/forum/topic/25183-task-celtic-british-roster-britons/page/3/?tab=comments#comment-403079
and
https://wildfiregames.com/forum/topic/23002-task-celtic-unit-textures/page/12/?tab=comments#comment-403032

Reviewed by: Genava55 and wowgetoffyourcellphone
This was SVN commit r24082.
2020-10-02 12:11:55 +00:00
wackyserious
61f82bdb5f Texture Update: Celtic linothorax (Minor detail fix)
Reviewed by: Genava55
This was SVN commit r24081.
2020-10-02 08:51:16 +00:00
de44d6c9d4 Fix missing and incorrect garrison flag.
Noticed by: @Mr.lie
Thread:
https://wildfiregames.com/forum/topic/30470-missing-proppoint-on-actor-gaulswonderxml/?tab=comments#comment-406235

This was SVN commit r24080.
2020-10-02 07:48:49 +00:00
1273307b58 Don't detect audio card when audio is disabled, Fix compilation with --without-audio, fix a few warnings.
Reviewed by: @bb
Comments by: @vladislavbelov, @wraitii
Differential Revision: https://code.wildfiregames.com/D2809
This was SVN commit r24079.
2020-10-02 07:35:59 +00:00
Angen
e18c305ba2 Do not reset compatibilty filter when deleting replays
Differential Revision: D3024
Reviewed by: Freagarach
Fixes: #5824

This was SVN commit r24077.
2020-10-01 16:06:15 +00:00
bb
b0093a43e6 Redo the previous commit by actually parsing the comments in the revision: use getTextSize. This allows some nukes in the OverlayCounterManager.
refs f09083c04d
refs #5385
Differential Revision: D1764
This was SVN commit r24076.
2020-09-28 16:20:52 +00:00
bb
f09083c04d Let the Overlay width depend on the longest string in it
Based on Patch By: ramtzok1
Comments by: elexis, Polakrity, smiley, Stan
Differential Revision: https://code.wildfiregames.com/D1764
fixes #5385

This was SVN commit r24075.
2020-09-28 16:00:06 +00:00
Angen
69a13c2be5 Refactor UpdateMessageSubscriptions in CCmpRangeOverlayRenderer
Introduced in 5fbb224dc0

rewrite 3 ifs to 1 if
merge 2 member variables into 1 member variable
remove 2 function local variables
save one call for CComponentManager as both ifs would or execute or not

code is shorter and looks nicer

Differential Revision: D3009
Reviewed by: bb
This was SVN commit r24072.
2020-09-27 13:12:30 +00:00
bb
fbc570674f Show correct trade info for observers
Reviewed By: Freagarach
Discussed with and code proposal taken from: elexis
Differential Revision: D3014
This was SVN commit r24071.
2020-09-25 21:34:24 +00:00
adca4ba1f4 Introduce subfolders for geology templates.
This moves:
- geology_metal_*.xml -> ore/*_small.xml
- geology_metal_*_slabs.xml -> ore/*_large.xml
- geology_stone_*.xml -> rock/*_small.xml
- geology_stonemine_*_quarry.xml -> rock/*_large.xml

To have folders per resource subtype as was already the case for fish,
treasures and ruins.

Patch by: @Nescio.
Differential Revision: D1010
This was SVN commit r24070.
2020-09-25 08:37:04 +00:00
162b9e2f6b Introduce subfolders for flora templates.
This moves fruit templates to gaia/fruit/ and wood (tree) templates to
gaia/tree, thus sorting them by resource subtype, as is the case for
fish, ruins and treasures already.

Patch by: @Nescio.
Differential Revision: D1009
This was SVN commit r24069.
2020-09-25 08:29:10 +00:00
bb
44b8e87f43 Don't use GetPopulationCount() in Player.js, but use the value it returns directly
refs: 74f08a5083
Proposed By: Freagarach
This was SVN commit r24067.
2020-09-24 17:07:45 +00:00
bb
446b71e71e Remove comment added in 5b314fc0ac, but obselete since 026ce76e3f.
Noticed by: Freagarach
This was SVN commit r24066.
2020-09-24 16:59:25 +00:00
bb
74f08a5083 Clean simulation/components/Player.js
Add caps/period
var => let
don't use getter inside the component

This was SVN commit r24065.
2020-09-23 17:42:36 +00:00
bb
bb5776c079 Disallow gaia to change state, i.e., gaia can't be defeated or win
Reviewed By: Freagarach
Differential Revision: D3013
Fixes #5140

This was SVN commit r24064.
2020-09-23 15:40:48 +00:00
840cc18277 Do not process commands sent by observers.
Differential Revision: D2810
Reviewed by: @bb.
Refs #5140.

This was SVN commit r24063.
2020-09-22 18:28:21 +00:00
bb
ac57eae596 Make fauna names consistent
Patch By: Nescio
Differential Revision: D3012
This was SVN commit r24062.
2020-09-21 21:14:24 +00:00
bb
c2b97cdba0 Safeguard QueryPlayerIDInterface calls
Similar to 31df44673a

This was SVN commit r24060.
2020-09-21 18:54:32 +00:00
4a4a768af6 Add missing credit in 3D work. I missed the fact he was in 2D
Noticed by: @Nescio
This was SVN commit r24059.
2020-09-21 09:05:15 +00:00