GithubHelp home page GithubHelp logo

beyond-all-reason / spring Goto Github PK

View Code? Open in Web Editor NEW
186.0 5.0 97.0 281.09 MB

A powerful free cross-platform RTS game engine

Home Page: https://beyond-all-reason.github.io/spring/

License: Other

CMake 1.19% Lua 2.74% C++ 86.55% C 6.25% Awk 1.00% Java 0.15% Makefile 0.25% Shell 0.32% CSS 0.04% PHP 0.03% Smarty 0.01% GLSL 0.42% HTML 0.45% NSIS 0.12% Python 0.33% Objective-C 0.03% Perl 0.09% sed 0.01% Assembly 0.02% Dockerfile 0.01%

spring's Introduction

Recoil is an open source real time strategy game engine

Get the engine sources

git clone https://github.com/beyond-all-reason/spring -b BAR105 --recursive

Recoil is a fork and continuation of an RTS engine version 105.0

Visit our Discord for help, suggestions, bugs, community forum and everything Recoil related.

Installation

You can use a pre-compiled binary, usually, you want to use an installer or a package prepared for your OS:

Compiling

Detailed instructions for how to compile Recoil can be found here or here

Use BAR105 as the primary branch.

Verify you're seeing tags:

>>> git tag
spring_bar_{BAR105}105.0-430-g2727993
spring_bar_{BAR105}105.1.1-1005-ga7ea1cc
spring_bar_{BAR105}105.1.1-1011-g325620e
spring_bar_{BAR105}105.1.1-1032-gf4d6126
spring_bar_{BAR105}105.1.1-1039-g895d540
spring_bar_{BAR105}105.1.1-1050-g5075cc0
...

If you aren't seeeing these (often, when you've cloned your fork of the repository and not the upstream version), try the following:

git remote add upstream [email protected]:beyond-all-reason/spring.git
git fetch --all --tags

Check out the BAR105 branch in this case:

git checkout upstream/BAR105 -b BAR105

The most simple set of commands will be:

cmake .
make

License

Our Terms are documented in the LICENSE.

spring's People

Contributors

abma avatar ashdnazg avatar badosu avatar beherith avatar cleanrock avatar dzosz avatar gajop avatar googlefrog avatar hoijui avatar imbaczek avatar jk3064 avatar lhog avatar lostsquirrel1 avatar madrman avatar majboredom avatar marcushutchings avatar n0u avatar p2004a avatar renefritze avatar rlcevg avatar rtri avatar rwestberg avatar sanguinariojoe avatar spliff avatar sprunk avatar tomjn avatar tvo avatar verybadsoldier avatar xiphux avatar zerver avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

spring's Issues

Look at optimizing Cursor Anims

Currently cursor anims are like GIF, but with PNG.
frames and duration set, per cursor per cursor size.

Possibly this could be better atlassed + GPUed.
Nothing wrong with it visually, and should not become blurry...

Crash on loading the new Tabula map with AMD ([t=00:00:06.866775][f=-000001] Error: [TexMemPool::AllocRaw] failed to allocate bitmap of size 268435456u from pool of total size 268435456u)

Infolog paste: https://pastebin.com/gJbFyWjm

Stack Trace:
C:\Users\user\Documents\My Games\Spring\engine\104.0.1-1956-g0092498\spring.exe 0x0071CA55 /usr/lib/gcc/x86_64-w64-mingw32/9.3-posix/include/c++/bits/stl_vector.h:1496
C:\Users\user\Documents\My Games\Spring\engine\104.0.1-1956-g0092498\spring.exe 0x007CCAEA /usr/lib/gcc/x86_64-w64-mingw32/9.3-posix/include/c++/bits/atomic_base.h:419
C:\Users\user\Documents\My Games\Spring\engine\104.0.1-1956-g0092498\spring.exe 0x0042C7FC rts/Rendering/MatrixUploader.h:20
C:\Users\user\Documents\My Games\Spring\engine\104.0.1-1956-g0092498\spring.exe 0x00436BB2 rts/Game/Game.cpp:291
C:\Users\user\Documents\My Games\Spring\engine\104.0.1-1956-g0092498\spring.exe 0x00436DCE rts/Game/Game.cpp:302
C:\Users\user\Documents\My Games\Spring\engine\104.0.1-1956-g0092498\spring.exe 0x0083C631 rts/System/SafeUtil.h:24
C:\Users\user\Documents\My Games\Spring\engine\104.0.1-1956-g0092498\spring.exe 0x0083624A /usr/lib/gcc/x86_64-w64-mingw32/9.3-posix/include/c++/thread:138
C:\Users\user\Documents\My Games\Spring\engine\104.0.1-1956-g0092498\spring.exe 0x008417E4 rts/System/SpringApp.cpp:807
C:\Users\user\Documents\My Games\Spring\engine\104.0.1-1956-g0092498\spring.exe 0x0082B04F rts/System/Main.cpp:48
C:\Users\user\Documents\My Games\Spring\engine\104.0.1-1956-g0092498\spring.exe 0x00F15E49 rts/System/Main.cpp:100
C:\Users\user\Documents\My Games\Spring\engine\104.0.1-1956-g0092498\spring.exe 0x004013B4 x86_64-w64-mingw32-x86_64-w64-mingw32-crt/./mingw-w64-crt/crt/crtexe.c:341
C:\Users\user\Documents\My Games\Spring\engine\104.0.1-1956-g0092498\spring.exe 0x004014DB x86_64-w64-mingw32-x86_64-w64-mingw32-crt/./mingw-w64-crt/crt/crtexe.c:197
C:\Windows\SYSTEM32\ntdll.dll 0x00052651 ??:0

MSVC support, C++17, and other things

Hello,

I am a mainly Windows game developer interested in getting into spring development, however I'm facing a few issues trying to compile it on MSVC. I assume this is not supported, since the only docs about building for MSVC + Windows are from almost 10 years ago.

However, I'm almost getting it to work, slowly but surely. First, vcpkg helped me a ton in setting up the dependencies, after I was going crazy trying to install them manually, so we might write this down somewhere if another MSVC dev like me comes and wants to build it. So that helped, except for all the includes that are broken because the system is assumed to be Linux, I guess (things like ZLIB headers which are probably almost always reachable on a Linux system)

But here I'm hitting something which doesn't make sense at all. First, the standard has been explicitly set to C++17 for MSVC recently, but did someone manage to build it this way ? On my machine and with VS2019, clearly that can't possibly build. If not, it doesn't make sense to commit things like this: ca1e054 as it's just making things even harder for devs that are new to the codebase

Then the next, harder question, why do the CMake files even pretend to be building with C++17 ? The codebase does not seem at all to be C++17 compliant. For starters, there are tons of random_shuffle which does not exist in C++17. How can the CMake files setup a build for C++17 when the codebase is not C++17 ? That doesn't make much sense to me currently. I guess one possible answer is that you are purposefully building with C++17 language feature, but also purposefully using an older version of the STL ? I don't even know if that can possibly work though, but only explanation I can come up with

If someone can shed light on those questions (MSVC build steps, or status, and C++17 compliance), this will probably help me get into this project that I would really like to contribute to :)

Animated CEG textures

From Sanctuary Discord:
https://t.co/aGCdAMxlSe?amp=1

the real trick is to have them animated :D whats going on there is each texture is actually a grid of image frames, and the uvs are being shuttled around to give it an animated appearance. so while theres only one quad thats showing a whole movie :> this lets us save huge amounts of particles which is great, since the number that would be needed to make the equivalent effect would be huge.

Only doable with GL_TEXTURE_2D_ARRAY, thus GL3.0 level capabilities.

Investigate HW cursor failure

i just launched 2 campaign games and gave 1500 peewees, hw cursor was fine, then i reconnect to some multiplayer match and there it is again. new launch, reconnecting 2x to that multiplayer game was fine, starting a campaign this time, spawning 1500 pw and yup, its there again. 3 times in a row the 3rd game it starts to happen from the get go

Fix unit clumping / pushing / pushresistance

The video is a nice example of the issue:

VideoCompressor_20210407013807827.mp4

But you could also just test with 20 armflash, and see how they are clumping togther and pushing eachother like crazy. or try with hovers, same behaviour.

fiddling with mass or footprint does not help with this issue

pushresistant = true, kinda works. but causes units to get stuck, and sometimes even ignore move orders

@ivand

Attend https://github.com/beyond-all-reason/Beyond-All-Reason/issues/239

grep -irn GetCameraState

activity_broadcast.lua:51: local GetCameraState = Spring.GetCameraState
activity_broadcast.lua:56: local prevCameraState = GetCameraState()
activity_broadcast.lua:83: local cameraState = GetCameraState()
camera_lockcamera.lua:27:local GetCameraState = Spring.GetCameraState
camera_lockcamera.lua:258: local prevCameraState = GetCameraState()
camera_lockcamera.lua:264: for stateindex in pairs(GetCameraState()) do
camera_lockcamera.lua:323: local state = GetCameraState()

Increase Rockettrail parts for smoother curves

Since we now know that trails are 5x less costly as thought before, i'd like to increase the amount of trail things for curved trails.
This probably gets recalculated every 8 gameticks (not sure), but i'd like to see what 4 or even 2 does.

Mostly needed for the Missile launcher (not the starburst).
It might be in this line? https://github.com/beyond-all-reason/spring/blob/BAR/rts/Sim/Projectiles/WeaponProjectiles/MissileProjectile.cpp#L222

This could make the engine trails interesting and even better again than our current work around with CEGS.
We could remove all missile ceg trails, which are relatively costly and look bad in tight corners/turns.

Add shadowSampler option for Lua Texture

Currently, shadowSampler texture is not possible to setup because GL_TEXTURE_COMPARE_MODE is always set to GL_NONE.
The proposition is to

  • add compareFunc to [Lua/LuaTextures.h]:Texture struct, which would correspond to GL_TEXTURE_COMPARE_FUNC
    Note: ShadowSampler might require setting both GL_TEXTURE_COMPARE_MODE and GL_TEXTURE_COMPARE_FUNC, but it looks logical to simplify for Lua into 1 parameter: compareFunc, which is either 0 (default, compareMode == GL_NONE) or one of GL_LESS,GL_EQUAL,etc (compareMode == GL_COMPARE_REF_TO_TEXTURE).
  • replace following at [Lua/LuaTextures.cpp]:ApplyParams(tex&):
    from
    glTexParameteri(tex.target, GL_TEXTURE_COMPARE_MODE, GL_NONE);
    to
    glTexParameteri(tex.target, GL_TEXTURE_COMPARE_MODE, tex.compareFunc? GL_COMPARE_REF_TO_TEXTURE : GL_NONE);
    if (tex.compareFunc) glTexParameteri(tex.target, GL_TEXTURE_COMPARE_FUNC, tex.compareFunc);
  • account for compareFunc field at [Lua/LuaOpenGL.cpp]:CreateTexture(..) and ChangeTextureParams(..)

P.S. I may not be totally correct with how compareMode setup works, correct me if I'm wrong.

GCC + debug preset cannot build unitsync

[ 71%] Linking CXX shared library ..\..\unitsync.dll
CMakeFiles\unitsync.dir/objects.a(LuaConstEngine.cpp.obj): In function `__spring_glOrtho_noCC':
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:56: undefined reference to `__imp_glOrtho'
CMakeFiles\unitsync.dir/objects.a(LuaConstEngine.cpp.obj): In function `__spring_glOrtho':
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:59: undefined reference to `__imp_glTranslatef'
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:60: undefined reference to `__imp_glScalef'
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:61: undefined reference to `__imp_glOrtho'
CMakeFiles\unitsync.dir/objects.a(LuaConstEngine.cpp.obj): In function `__spring_glFrustum_noCC':
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:70: undefined reference to `__imp_glFrustum'
CMakeFiles\unitsync.dir/objects.a(LuaConstEngine.cpp.obj): In function `__spring_glFrustum':
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:73: undefined reference to `__imp_glTranslatef'
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:74: undefined reference to `__imp_glScalef'
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:75: undefined reference to `__imp_glFrustum'
CMakeFiles\unitsync.dir/objects.a(LuaParser.cpp.obj): In function `__spring_glOrtho_noCC':
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:56: undefined reference to `__imp_glOrtho'
CMakeFiles\unitsync.dir/objects.a(LuaParser.cpp.obj): In function `__spring_glOrtho':
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:59: undefined reference to `__imp_glTranslatef'
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:60: undefined reference to `__imp_glScalef'
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:61: undefined reference to `__imp_glOrtho'
CMakeFiles\unitsync.dir/objects.a(LuaParser.cpp.obj): In function `__spring_glFrustum_noCC':
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:70: undefined reference to `__imp_glFrustum'
CMakeFiles\unitsync.dir/objects.a(LuaParser.cpp.obj): In function `__spring_glFrustum':
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:73: undefined reference to `__imp_glTranslatef'
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:74: undefined reference to `__imp_glScalef'
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:75: undefined reference to `__imp_glFrustum'
CMakeFiles\unitsync.dir/objects.a(LuaUtils.cpp.obj): In function `__spring_glOrtho_noCC':
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:56: undefined reference to `__imp_glOrtho'
CMakeFiles\unitsync.dir/objects.a(LuaUtils.cpp.obj): In function `__spring_glOrtho':
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:59: undefined reference to `__imp_glTranslatef'
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:60: undefined reference to `__imp_glScalef'
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:61: undefined reference to `__imp_glOrtho'
CMakeFiles\unitsync.dir/objects.a(LuaUtils.cpp.obj): In function `__spring_glFrustum_noCC':
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:70: undefined reference to `__imp_glFrustum'
CMakeFiles\unitsync.dir/objects.a(LuaUtils.cpp.obj): In function `__spring_glFrustum':
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:73: undefined reference to `__imp_glTranslatef'
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:74: undefined reference to `__imp_glScalef'
G:/_programming/zero-k/spring-m/rts/Rendering/GL/myGL.h:75: undefined reference to `__imp_glFrustum'
collect2.exe: error: ld returned 1 exit status
mingw32-make[3]: *** [tools\unitsync\CMakeFiles\unitsync.dir\build.make:1128: unitsync.dll] Error 1
mingw32-make[2]: *** [CMakeFiles\Makefile2:2222: tools/unitsync/CMakeFiles/unitsync.dir/all] Error 2
mingw32-make[1]: *** [CMakeFiles\Makefile2:2229: tools/unitsync/CMakeFiles/unitsync.dir/rule] Error 2
mingw32-make: *** [Makefile:542: unitsync] Error 2

Looks like unitsync doesn't pick up glstub.c definitions of missing functions.

Loading a saved scenario is broken

When playing a scenario, you can save a game (by pressing a button, I did it in a paused state), but after loading it, the following game-breaking issues make it useless:

  1. Some units can't fire. This means neither automatically, nor when pointing them at an enemy.
  2. Animations for many units stop working. They move, but the walking animation doesn't play.
  3. Ghosts of the units you start a scenario with, appear in their original positions, but can't be selected.
  4. It looks like all wrecks become invisible. They can still be found by area Resurrect or Reclaim.

Video: https://www.youtube.com/watch?v=PCbbHlaui3Y
Savefile: Save.zip

This behavior is observed for at least a month. Current version: Beyond All Reason (Spring 105.1.1-475-gd112b9e BAR105).

Prefer dedicated GPU over integrated on Windows

See https://springrts.com/mantis/view.php?id=6437 (I figured nobody looks there) and also ZeroK-RTS/Zero-K-Infrastructure#2758 .

If there is both an integrated and a dedicated graphics card, it seems that the integrated card often gets used by default. Apparently sticking the following somewhere changes the default to the dedicated one:

/* If both an integrated and a dedicated graphics card are found,
 * make the dedicated one used by default (usually superior).
 * nVidia and AMD achieve this via the presence of a magic var. */
extern "C"
{
  __declspec(dllexport) int AmdPowerXpressRequestHighPerformance = 1; // AMD
  __declspec(dllexport) unsigned long NvOptimusEnablement = 0x00000001; // nVidia
}

Audio cable change issue

When I change my audio cable from one device to another the sound in BAR vanishes. The rest of the system works fine but BAR stops outputting noise.

Subsequent to posting this I realised going from lobby to battle will mean sound comes back on. If I unplug mid battle though the sound goes off again and doesn't resume.

Spring.SpawnExplosion inside ProjectileCreated crashes Spring

Not urgent (neither BAR nor ZK do this, it was discovered by some random modder, and can be worked around).

Here's a snippet to reproduce:

function gadget:ProjectileCreated()
    -- rule out recursion
    if already then return end
    already = true  

    Spring.SpawnExplosion(100, 100, 100, 1, 1, 1, -- position/direction, dont seem to matter
         {} -- explosion params; the contents don't matter, empty is valid
    )
end

Calling it from elsewhere works (checked gadget:GameFrame, script.Shot, and script.FireWeapon).

math.random(x, y) returning float instead of int

Calling math.random(x, y) inside a unitDef file is returning a float, as if it was a call to math.random(). It should be returning an int in the range (x, y).

Calls inside widgets, gadgets, and menu work as expected.

Investigate crash in 6e473161205c6381c703411de7f09d8a

https://www.beyondallreason.info/replays?gameId=6e473161205c6381c703411de7f09d8a has crashed for some and desynced for others.

Investigation showed crash happened here:

void CCommandAI::WeaponFired(CWeapon* weapon, const bool searchForNewTarget)
{
	if (!inCommand)
		return;

	const Command& c = commandQue.front();

unit in question is stiletto (id = 27371), gameFrame = 62697

commandQue was empty, which caused the crash.

The unit was in the middle of releasing its salvo against a former enemy unit that that has just been captured (has become allied).

Additional check for non commandQue.empty() fixes the crash but I'm not sure it's a proper fix.

Fill-up construction wireframe has changed.

image

The construction wireframe for energysolar in ZK does not show any switches suddenly between the three construction animation states with no fill-up in between. I recall there being some underground piece hax involved to make the construction blueprint of the unit show as open rather than closed, which is probably the cause. Regardless, this works in the engine ZK is on.

I have come across this issue before and suggested tags to set the maximum and minimum heights that the build animation should range over, the save the engine from trying to deal with edge cases.

Engine Rockettrails Particle Count Very High

Rockettrails from starburst + missilelauncher seem to always leave trails (thought they get counted in-game in particle counter).

Test Setup:

  • Spawn like 10 armafus + 10 armmmkr + 50 armjuno
  • Speed up to let it stockpile
  • Press ALT-B for stats / particle count
  • Launch all 50 armjuno at once.

Particle count should be around 25.000
Though technically this should be able to be reduced to something like 5.000 or even 2.500.

Reducing flighttime from armjuno (from 400 to 50) reduces particle cost by factor of 5.
Effect however, is visually identical - so something 'hidden' is counted as particle (or secretly also calculated).

TraceScreenRay fails to hit map on areas that are flattened by buildings being built on them.

Quite a few things are now known about this issue:

  1. The oldest engine I tested this also had the bug, it was in engine 1486.
  2. When a building is built by a constructor, the edges of the flattened area randomly miss on TraceScreenRay
  3. If the buildings are /give-en, then the bug is not present
  4. If the terrain is restored underneath /given buildings, the bug becomes visible.
  5. Explosions and craters do not show this behaviour
  6. The issue can relatively easily be checked by this widget that traces the screen along a regular grid, and draws a red rectangle if the trace fails.
function widget:GetInfo()
    return {
        name      = "ScreenTrace",
        desc      = "Trace the screen along a regular grid, drawing a red rectangle on any ray that does not hit the ground",
        author    = "beheriht",
        date      = "2021 summer heat",
        license   = "Bacon",
        layer     = 10000,
        enabled   = true  --  loaded by default?
    }
end

local resolution = 10

local vsx, vsy
function widget:ViewResize(newX,newY)
	vsx, vsy = Spring.GetViewGeometry()
end

function widget:Initialize()
	widget:ViewResize()
end

function widget:DrawScreen()
	gl.Color(1.0, 0.0, 0.0, 0.75)  --red
	for x = 1, vsx, resolution do
		for y = 1, vsy, resolution do
			local _ , coords = Spring.TraceScreenRay(x, y, true) 
			if coords and coords[2] and coords[2] > -1000 then
				--gl.Color(0.0, 1.0, 0.0, 0.5) -- green
				--gl.Rect(x, y, x+ resolution/2, y+resolution/2) -- x y w h
			else
				--gl.Color(1.0, 0.0, 0.0, 0.75)  --red
				gl.Rect(x, y, x+ resolution, y+ resolution) -- x y w h
			end
		end
	end
end

Fix strange behavior strategic icons (low angle camera = floating icons in sky)

Probably found in :
https://github.com/beyond-all-reason/spring/blob/fdebe587b90eac92790e2c55a5198e6a4a57d2a6/rts/Rendering/UnitDrawer.cpp
and
https://github.com/beyond-all-reason/spring/blob/fdebe587b90eac92790e2c55a5198e6a4a57d2a6/rts/Rendering/UnitDrawer.h
and
https://github.com/beyond-all-reason/spring/blob/fdebe587b90eac92790e2c55a5198e6a4a57d2a6/rts/Rendering/UnitDrawer.h

Behavior is a glitchy on low angle camera shots

Reproduce

  1. Start map (Colorado V2 f.e.)
  2. Place some scattered units across map to see the icons go wrong
  3. Use Spring Cam / CTRL-F3
  4. Hold Middle Mouse + ALT + Move mouse to get lower angles and look around
  5. Move camera position around the map
    = you will see some strange floating icons in the sky

See a quick video here: https://discord.com/channels/549281623154229250/549282926596980738/877336995163176961

floatingicons

font substitution is not working for windows

Spring natively supports unicode, but this only really works if you have the characters for non-latin languges eg chinese/korean/japanese.

Most fonts do not have these characters because there are so many of them, so text rendering usually does font substitution - asked to render a character which selected font does not have, it picks a glyph from a font that does have it.

This is by default not working in Spring on Windows, presumably because it requires a fontconfig cache. Generating this cache on WIndows is supposed to occur by invoking Spring witht the --gen-fontconfig CLI parameter, but it seems to somehow fail:

image

image

Comments on spring/spring@2225f0f suggest that parts of that commit may be noop but i have no idea if that's relevant.

Cegs obscure other cegs too much

So a videopreview of what i mean is clearly seen here: https://discord.com/channels/549281623154229250/551411485901979659/876260266357186640

Lots of smoke-ceg particles obscure other cegs behind them.
So there seems like max ammount of cegs to be 'layered'.

Problem is in big battles, with lots of explosions and smoke, the smoke is generally larger/higher up, and this obscures all other flashes/explosions/flames that are happening on the ground/below.

This is something that has been plaguing Spring games in general for quite some time.
This limitation/bug is what makes intense battles a lot less intense as they are, since smoke will hide all the fire-y explosions.
But since the smoke remains transparant, you can see the terrain/units behind it, but it seems if explosions/projectiles 'just don't work anymore' (or that the particle system partly broke) since there is just nothing happening behind the smoke.

Idea/Suggestions:

  1. Increase amount of layered cegs to be displayed. If performance allows it, i'd increase this a lot.
  2. Make it somehow possible to set a limit to 'smokey' cegs and keep room for other explosions behind smoke-cegs
  3. Have some cegs have priority/always show, like flames/sparks/flashes/etc.

explosion-ceg-limit-layers

Replace manual commands with `make install`

Good first issue if you're into devops is refactoring the build to remove all these cp and rm's: https://github.com/beyond-all-reason/spring/blob/BAR/.github/workflows/build.yml#L348-L435

This is supposed to be replaced with make install, so a few things need to happen:

  • Install prefix needs to be supplied during cmake configuration
  • manual cp/mkdir commands replaced with make install
  • the whole thing needs to be tested, so at first probably inside a docker container, secondly on github runner: the file has commented section that allows to log in into the running (&paused) workflow, so the section must be moved before or after make install step, un-commented, and upon login tested if it does everything as expected (installs into correct directory, the files structure is consistent with status quo, etc). The last step can be done at your own github fork of BAR/spring.

Stale quadtree for projectile collisions

Copied from mantis:
image
Apparently the unit here is considered to be exclusively in quad 870 at the time of this screenshot. This causes projectiles and rays that do collision tests without considering quad 870 to erroneously not collide with it. This has been noticed by players of ZK in two situations:

  • Widow missing units with its short range LightningCannon.
  • Anti-Air missiles penetrating bombers.

It probably happens a lot more, but doesn't impact gameplay in a hugely noticeable way. With some investigation I'd expect to find it impacting balance in a few ways. Now that I think of it, high duration beam lasers sometimes flicker through mobile units for a frame. This may well be related.

On the mantis ticket esainane claims that quad membership updates at 2Hz, barring any sudden changes in position. There are two suggested fixes so far.

  • The hacky performant method: When projectiles check for collision, add the target of the projectile to the units to be checked in addition to the units found via the quadtree search.
  • The perfect but potentially slow method: Update the quadtree at 30Hz rather than 2Hz.

See:

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.