This commit is mainly intended to ease packaging for linux.
Unless environment variable AQUARIA_DATA_PATH is set, there are two
directories which are checked by the game:
If AQUARIA_DEFAULT_DATA_DIR is defined, it will chdir there for main
operation. If it's not defined, it chdirs into the directory where
the executable is located.
Then, if AQUARIA_EXTRA_DATA_DIR is defined, it will mount this directory
and all contents into the working path, so that the files present there
will override those from the working directory when accessed by the game.
Setting the environment variable AQUARIA_DATA_PATH will disable this
behavior altogether and use *only* AQUARIA_DATA_PATH as working dir.
Fixes regression introduced in 0784d1b9df.
With a std::list it was okay to create shots while iterating with an
iterator, but not so with a std::vector.
Now using index access, which is safe with push_back() operations.
This fixes a glitch in the final boss' last form. Due to a missing
Beam::trace() call, the beam's angle was not updated,
and it always pointed into the upper left corner.
castSong() existing in the global Lua namespace caused it to be removed
and stored as an interface function as soon as a script was loaded.
The function was apparently never used in the game or other mod scripts,
thus renaming it now should be safe.
With this change, shots are no longer stored in a std::list.
In the current code, the global shot store may be modified while iterating,
this did not cause problems with the list implementation,
but would easily crash if a shot is removed while iterating.
To fix this, a 2nd vector stores shots to be deleted from the global store
and does so when no iteration is in progress and modifying the vector is
safe.
Added functions:
getFirstShot -- for iterating over all shots on the map
getNextShot
shot_setFirer
shot_setExtraDamage
shot_getExtraDamage
shot_getDamage
shot_getDamageType
shot_getName
This corrects render pass overriding, especially Li's arm, which was supposed
to be in front of the hug; and being eaten by a grouper, where Naija stayed
visible because the grouper skeletal's render pass was not set correctly.
This simplifies a few things. First, the values of DamageType are now continous,
with the benefit that they can now be stored in a std::bitset.
Second, this repairs entity_getNearestEntity(..., ET_AVATAR) or DT_ENEMY as param,
because these were 0, but the game expected -1 as universal value.
This way, any entity was returned when querying for ET_AVATAR or DT_ENEMY.
Now, 0 is the universal/NONE value, which should avoid mistakes like this.
- Map markers are now spawned on the player position, not above
- 66% alpha for world map icons, this way some of the stuff below the icon
can be seen.
- Unified and increased zoom-in distance. This way the view no longer forcefully
resets to another zoom level when selecting maps of different layers
(i.e. first an interior map, then zoom in, then select a regular map),
which was a little jarring. The increased zoom level is useful for
close-ups on tiny areas like the sun temple.
The first one caused the music to stop randomly on scene changes,
reproducible by changing maps with different music while holding 'G'
button to speed up time.
For some reason this caused the music to stop playing during the crossfade.
Wasn't able to find the root cause, so I added a little hack to kick the
music back on track if it stops unexpectedly.
The second one was a simple string case issue; mostly noticable because of
map background sounds not playing in loop mode.
(this is possibly a regression from an earlier patch, not sure)