Maps should not be required to define all these globals and use them
with the connotation implied by these utilities.
Split utilityfunctions.js to gaia_entities.js and gaia_terrain.js to
make it more transparent what files contain, refs #4804.
Document these functions #4831.
Refactor stoneMine placing and use for...of loops.
Fix Extinct Volcano call.
Forest utilities will be handled separately.
This was SVN commit r20405.
Thereby fix the distance check of the SimpleObject, refs #4338, D189 and
remove the CELL_SIZE engine constant magic number, refs #4034.
Differential Revision: https://code.wildfiregames.com/D996
Thanks a lot to rapidelectron and temple who independently discovered
this!
This was SVN commit r20396.
Keep the Catmull-Rom spline comment as ambiguous as the definitions we
found.
Differential Revision: https://code.wildfiregames.com/D1003
Reviewed By: fatherbushido
This was SVN commit r20394.
Remove PointXZ class which is essentially a subset of Vector2D, refs
#4834, #4804.
Remove Point3D which is unused and the same as Vector3D without the math
features, refs #4805.
This was SVN commit r20388.
Remove placeTerrain, and createObjectGroup from Map, because that class
should only have getters and setters, refs #4804.
Unify it with the global functions of the same name.
Let Map.createArea only construct and register the Area object with the
Map, but do the place and painter logic in the global function.
This was SVN commit r20387.
Remove initTerrain from Map, because that class should only have getters
and setters, refs #4804.
Unify it with the global initTerrain function.
Remove some redundant calls to that.
This was SVN commit r20386.
Thereby unify the chordal Catmull-Rom spline interpolation of the
ClumpPlacer (C++ bd53b14f58, JS 0e0ed94926),
the copy of that in the PathPlacer (bc805bd357, refs #892) and
the centripetal Catmull-Rom spline of the bicubicInterpolation function
from 93aefe0787, refs #4218
and don't claim the latter to be a uniform Catmull-Rom spline.
Reviewed in part by fatherbushido, discussed in 93aefe0787.
This was SVN commit r20383.
Make pyrogenesis and tests depend on Collada, fixes#404.
This commit includes custom modules for CxxTest and pkg-config support
that can be improved upon in the future. It also includes all necessary
changes to the build scripts, but the new premake5 features are not
fully exploited yet.
With this change, premake5 becomes the default, but CI scripts on Unix
will continue using premake4 for a while, in order to avoid regressions.
Includes code by zsol.
Reviewed by: wraitii, leper
Differential Revision: https://code.wildfiregames.com/D72
This was SVN commit r20381.
Remove camera centering in that function because it contradicts the
modifiability of the camera global (besides being broken and only coming
into play if there are no player entities).
This was SVN commit r20370.
The removed values were in fact arbitrary GUI numbers no map script
should confuse with engine limits.
To not make it my words, quoting FeXoR from #4034:
"I agree removing MIN_MAP_SIZE and MAX_MAP_SIZE and make the parameters
of scaleByMapSize optional with the default being 128 to 512."
This was SVN commit r20368.
Add "melee", "ranged" etc. to the template tag name,
Allow and use specific sounds for slaughter,
Rearrange the templates a bit, and so add missing sounds.
Reviewed By: fatherbushido
Differential Revision: https://code.wildfiregames.com/D757
This was SVN commit r20367.
This new script and the associated configuration files lint our source
code (JS and C++). This will be extended in the future, refs #4833.
Reviewed By: Imarok
Differential Revision: https://code.wildfiregames.com/D213
This was SVN commit r20364.
Keep now unused, yet unalteredly useful paintHeightmap JS function
(until CMapReader::LoadRandomMap can load PMP files, refs #4816),
bicubicInterpolation and randomPlayerPlacementAt.
This was SVN commit r20362.
Document the difference between the two types of classes, refs #4831.
Move RectPlacer (as of 7d0cc59136 unreferenced but possibly useful)to
placer_noncentered.js and remove three redundant checks there.
This was SVN commit r20360.
Define what an Object is, refs #4831.
Remove RandomObject duplication from c02818ceea by just calling the
SimpleObject with a random template, refs #4805.
Remove the tautologous (!fail) check and replace needless multilevel
fail-check nesting with two && operators.
Move default parameters from the function body to the function header
and rename resultObjs to entities.
Throw errors instead of printing something if min > max.
This was SVN commit r20357.
Document what a Group is, refs #4831.
Remove duplicate place function by calling the SimpleGroup from the
RandomGroup, refs #4805.
Move the default parameters from the function body to the function
header, remove duplicate CELL_SIZE division, pointless comment and use
let instead of var.
This was SVN commit r20355.
It should have been added to the painters file instead of to the map if
a copy was acceptable.
Add the only simple capability it added (an unnoticeable random
elevation difference to each vertex) to the SmoothElevationPainter to
make it universally accessible.
That painter also had a bug, because it replaced the roughness with 5 if
0 was given.
This was SVN commit r20354.
Doesn't change the result perceptibly while removing otherwise
incomprehensible magic numbers from 61387e95b2.
The equations are so similar that one might expect that the averaging
was the intended algorithm.
This was SVN commit r20353.
(The spread operator is not faster in sm45 according to my test.)
Differential Revision: https://code.wildfiregames.com/D980
Refs 6590f301c2.
Not accepted by anyone.
This was SVN commit r20351.
Document the two classes, the new function and every step of their
execution, refs #4831.
Unify SmoothElevationPainter height computation duplication, remove
pointless comments, use array functions and the prefix increment
operator.
This was SVN commit r20350.
Remove two unneeded variables and reduce the performance by some
milliseconds by using for...of loops, the destructing assignment and
inlining the unified DX/DZ array.
Fix a wrong comment in the BorderTileClassConstraint of 86d3cdf2d5.
Differential Revision: https://code.wildfiregames.com/D984
Not accepted by anyone
This was SVN commit r20349.
Move the least complex rmgen painters (TileClassPainter,
TileClassPainter, MultiPainter, TerrainPainter) to the top of the
painters file, refs #4804.
Group the TerrainPainter with the LayeredPainter which both draw a
texture on the terrain contrary to the others.
Use for-of loops and remove unneeded variables.
(Diff split for auditability.)
This was SVN commit r20347.