[Finished] The Russian Overkill - 3.0e

Projects that alter game functions but do not include new maps belong here.
Forum rules
The Projects forums are ONLY for YOUR PROJECTS! If you are asking questions about a project, either find that project's thread, or start a thread in the General section instead.

Got a cool project idea but nothing else? Put it in the project ideas thread instead!

Projects for any Doom-based engine (especially 3DGE) are perfectly acceptable here too.

Please read the full rules for more details.

Re: [Finished] The Russian Overkill - 3.0c

Postby Slugrprod » Mon Mar 08, 2021 11:10 am

hey guys, i made a desktop icon for the mod, i'd like to know if you were interested in using it.
Slugrprod
 
Joined: 08 Mar 2021
Operating System: Windows 10/8.1/8/201x 64-bit
OS Test Version: No (Using Stable Public Version)

Re: [Finished] The Russian Overkill - 3.0c

Postby zdusr » Fri Mar 19, 2021 2:10 pm

Hi!

Would it be possible to include fixes for slow super weapons in your next release? Normally it is not a problem but with slaughter maps with 5k and more more monsters such as Okuplok Map (oku2v31.wad) or Holy Hell Revealed (Doom 2 - Holy Hell Revealed v1.5 SD.wad) alt fire of Vindicator and Borsch become so slow that they are practically unusable. However slaughter maps are maps where Russian Overkill shines the best so it needs to be fixed.

The problem lies within use of A_SuperExplode. Ro_SuperExploder is a function that iterates over all actors and damages all monsters within your blast radius. However superweapons call this function hundreds of times. So if you have 50k actors and Vindicator does about 300 times during one altfire explosion then it means that this while loop in this code has to process 12M actors. The damage is dynamically calculated by the code max(0, (1 - diff_len / radius) * damage) which can return value of 0 if monster is outside of blast radius. After that mo.DamageMobj gets called regardless of max(0, (1 - diff_len / radius) * damage) result. This means that when you alt fire Vindicator in map Doom 2 - Holy Hell Revealed v1.5 SD.wad at the place where you initially spawn in map it does about 9 million calls to mo.DamageMobj however only about 8.8k of those 9m are actually dealing more damage than 0. This is very inefficient and slows PC down a lot. I did not make up these numbers myself. I got this information by actually measuring the amount of calls using a_log and sending it's output to text file where I could later count the number of certain log entries. So my first proposal is to change A_SuperExplode so that it would only call DamageMobj when damage is > 0.

The code for the fix is following:
Code: Select allExpand view
         if(damage_dealt > 0){
            mo.DamageMobj(
               user,
               user.target,
               damage_dealt,
               damage_type);
         }


This alone already greatly speeds up all superweapon alt fires. However there is more that can be done to speed up RO in slaughter maps. Vindicator and Borsch do excessive amount of calls to A_SuperExplode. which means that even if previous fix decides not to damage monsters we still experience some slow down due to A_SuperExplode having to iterate over all actors for hundreds of times. I suggest to call it less times and compensate it with more damage output. This way those weapons still do the same amount of damage but wont use as much CPU time.

In Vindicator\Projectile.rxt find VindicatorMegadeath replace it with:
Code: Select allExpand view
Actor VindicatorMegadeath : Ro_SuperExploder
{
   //ReactionTime 200
   +NOINTERACTION
   +FORCERADIUSDMG
   var int user_blasttime;
   var int user_blastratio;
   var int user_blastpower;
   States
   {
   Spawn:
      TNT1 A 0 NoDelay { user_blasttime = 199; user_blastratio = 0; user_blastpower = 0; }
      TNT1 A 2 {
         if(user_blasttime % 3 == 0){
            A_SuperExplode(18000, 384, "Superweapon", 0.1, true);
         }
         user_blasttime--;
         Return A_JumpIf(user_blasttime <= 0,1);
      }
      Wait
      TNT1 A 0 { user_blasttime = 35; }
      TNT1 A 2 {
         user_blastratio += random(96,110);
         user_blastpower -= 100;
         user_blasttime--;
         if(user_blasttime % 3 == 0){
            A_SuperExplode(21000-user_blastpower, 384+user_blastratio, "Superweapon", 0.1, true);
         }
         Return A_JumpIf(user_blasttime <= 0,"Null");
      }
      Wait
   }
}

Compared to original code both calls to A_SuperExplode are wrapped inside if(user_blasttime % 3 == 0){ which basically tells to cause damage only every 3rd iteration. Since I did not change user_blasttime the animation is not 3 times shorter. It still lasts the same amount of time but does 3 times less calls to A_SuperExplode during that time. In A_SuperExplode call I multiplied damage by 3 in order to compensate for 3 times less calls.

Next, take Borsch\Projectile.txt and find BorschHoleDamager and replace it with this:
Code: Select allExpand view
Actor BorschHoleDamager : Ro_SuperExploder
{
   ReactionTime 120
   +FORCERADIUSDMG
    +NODAMAGETHRUST
   +NOINTERACTION
   DamageType "Superweapon"
   States
   {
   Spawn:
      TNT1 A 3 NoDelay {
         //A_Explode(8000,512,1,1,512);
         A_Explode(12000, 512); // The kind of blast that kills.
         A_SuperExplode(12000, 512, "Superweapon", 0.1, false);
         A_SetAngle(Angle + 15);
         A_Countdown;
      }
      Loop
   Death:
      TNT1 A 0
      Stop
   }
}


Here I reduced ReactionTime 3 times and increased one frame duration 3 times with TNT1 A 3 NoDelay. As a result animation lasts the same amount of time but does 3 times less calls to A_Explode and A_SuperExplode. To compensate for damage loss I also multiplied damage by 3 in those calls.


I also created zip file that contains those 3 tiles that I fixed so you dont have to manually edit everything, it's done for you. It only contains the fix itself, it is not a full standalone mode. You need to add those files into RO pk3 file. I do not recommend distributing it as separate file as it creates unnecessary confusion and gets lost over time. Add it to RO.pk3 and then distribute update RO.pk3 instead.

To see the difference load RO with Doom 2 - Holy Hell Revealed v1.5 SD.wad and and alt fire both Vindicator and Borsch with and without this fix. I suggest doing it in room where you spawn initially because it has only 1 monster and therefore you cant blame the slowness on amount of monsters on screen. Also note that both of these explosions are also demanding on graphics card so if animations cause lag with your computer (which can happen due to intel graphics card not being good with translucency) turn your face to opposite direction. Just do something that allows you to estimate the lag. I for example simply used to play around with free look by moving mouse. It can definitely be noticed when when frame rate drops to 1 frame per 2 sec.
You do not have the required permissions to view the files attached to this post.
zdusr
 
Joined: 19 Mar 2021

Re: [Finished] The Russian Overkill - 3.0c

Postby Valken » Sat Mar 20, 2021 12:06 am

I am! I love ROK!
Valken
 
Joined: 08 Jun 2015

Re: [Finished] The Russian Overkill - 3.0c

Postby PillowBlaster » Sat Mar 20, 2021 6:58 am

Re: Superexplosion problem, as that post disappeared for some reason (I saw it, was just too fukken tired to read coherently and respond yesterday) - it will be addressed, I definitely used that function a little too uhhhh, leniently, compared to doctor's orders.
User avatar
PillowBlaster
 
Joined: 24 Jan 2010

Re: [Finished] The Russian Overkill - 3.0c

Postby zdusr » Sat Mar 20, 2021 9:42 am

Hi!

Now the post is back. I am new user here and editing post sent it back to approval queue. Hopefully that post gives you good amount of information on the issue and for testing the fix.
zdusr
 
Joined: 19 Mar 2021

Re: [Finished] The Russian Overkill - 3.0d

Postby PillowBlaster » Fri Apr 30, 2021 2:41 pm

Morning. Evening. On a round Earth, its always sunshine somewhere. And same goes for RO, so have an update!

Spoiler: chang-log
User avatar
PillowBlaster
 
Joined: 24 Jan 2010

Re: [Finished] The Russian Overkill - 3.0d

Postby Valken » Fri Apr 30, 2021 10:28 pm

Glorious!
Valken
 
Joined: 08 Jun 2015

Re: [Finished] The Russian Overkill - 3.0d

Postby Ac!d » Sat May 01, 2021 10:38 am

Found a bug : I've die with the "Ullapool Caber" and the weapon didn't switch out and I can still swing the Stielhandgranates in both hands.
User avatar
Ac!d
Perfection is a way, not an end. - Korean Proverb
 
Joined: 02 Apr 2019
Location: France
Discord: Ac!d#2732

Re: [Finished] The Russian Overkill - 3.0d

Postby zdusr » Sun May 09, 2021 7:49 am

Hi I looked current release.

In my post above viewtopic.php?f=43&t=29915&start=1740#p1184589 I suggested adding if statement (if(damage_dealt > 0){) around mo.DamageMobj call in A_SuperExplode. I see that is not yet done. Any plans to implement this? Dealing 0 damage to monsters who are outside of blast radius does not do anything useful but it still consumes CPU time. And if you have like 41k monsters in your map then it will be very noticeable.
zdusr
 
Joined: 19 Mar 2021

Re: [Finished] The Russian Overkill - 3.0d mod not working

Postby Ushankaboi_771 » Sun May 16, 2021 12:05 pm

hi i wwanted to play Russian Overkill but for some reason when i load the mod it is just normal doom.
is that normal ?
how can i fix it
Ushankaboi_771
 
Joined: 14 May 2021
Discord: Ushanka Boi#2382
Operating System: Windows 10/8.1/8/201x 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: Not Listed

Re: [Finished] The Russian Overkill - 3.0d mod not working

Postby wildweasel » Sun May 16, 2021 12:16 pm

Ushankaboi_771 wrote:hi i wwanted to play Russian Overkill but for some reason when i load the mod it is just normal doom.
is that normal ?
how can i fix it

How are you loading it?
User avatar
wildweasel
change o' pace.
Moderator Team Lead
 
Joined: 15 Jul 2003

Re: [Finished] The Russian Overkill - 3.0d mod not working

Postby Captain J » Sun May 16, 2021 1:09 pm

Ushankaboi_771 wrote:hi i wwanted to play Russian Overkill but for some reason when i load the mod it is just normal doom.
That kinda gives me a hint... Have you unzipped the file after downloading it?
User avatar
Captain J
That's Amoreee
 
 
 
Joined: 02 Oct 2012
Location: A Year old Pizza Box
Discord: DiscussJ#3128

Re: [Finished] The Russian Overkill - 3.0d mod not working

Postby Ushankaboi_771 » Sun May 16, 2021 6:13 pm

wildweasel wrote:
Ushankaboi_771 wrote:hi i wwanted to play Russian Overkill but for some reason when i load the mod it is just normal doom.
is that normal ?
how can i fix it

How are you loading it?
by dragging the mod into GZdoom
Ushankaboi_771
 
Joined: 14 May 2021
Discord: Ushanka Boi#2382
Operating System: Windows 10/8.1/8/201x 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: Not Listed

Re: [Finished] The Russian Overkill - 3.0d

Postby 4zm0d4n666 » Mon May 17, 2021 8:05 am

Tried running the most recent Russian Overkill update (3.0d) on Delta-Touch, GZdoom 3.8.2 and LZdoom, and here's what shows up. The menu is working but if I try to do anything it goes back to the console. The previous versions (also 3.0) worked fine when I played on Delta-Touch, is this version not compatible with old GZdoom anymore? :(
You do not have the required permissions to view the files attached to this post.
4zm0d4n666
 
Joined: 17 May 2021

Re: [Finished] The Russian Overkill - 3.0d

Postby SaveTheDoomer » Sat Jul 17, 2021 1:32 am

I got a similar issue on the latest gzdoom compiled from git, and a crash when the menu is opened, too. Deleting the titlemap.wad from /maps within the pk3 seems to be a workaround.
User avatar
SaveTheDoomer
 
Joined: 11 Apr 2021
Location: Yog-Sothoth stone circle on the dark hills
Operating System: Windows 10/8.1/8/201x 64-bit
OS Test Version: No (Using Stable Public Version)
Graphics Processor: ATI/AMD (Modern GZDoom)

PreviousNext

Return to Gameplay Mods

Who is online

Users browsing this forum: mamaluigisbagel, TheRailgunner, wolf00 and 5 guests