Total War: ATTILA

Total War: ATTILA

View Stats:
WhyXelsink Dec 3, 2018 @ 9:57am
[HUGE DISCOVERY] Optimize Attila to ToB level
Couple of days ago I finally made a huge discovery how to bring ToB optimization level to Attila.

ToB is supposed to be a DLC pack for Attila, but CA decided to release it as a standalone version to make more money. The problem is, with the release of ToB, Attila didn't receive the update of optimization it should've received with that DLC. Instead, we have unoptimized Attila and a new game, basically modded Attila.

In order to make your Attila work like ToB, you have to manually delete and replace shaders inside data.pack and blood.pack.

Follow this guide:

https://steamcommunity.com/sharedfiles/filedetails/?id=1581603370
Last edited by WhyXelsink; Dec 3, 2018 @ 10:36am
< >
Showing 1-15 of 126 comments
Big Boss Dec 3, 2018 @ 1:06pm 
I've noticed using the TOB models and textures in attila also improves optimization, I'm trying to use them in all of my mods to make the game run better
Originally posted by WhyXelsink:
Couple of days ago I finally made a huge discovery how to bring ToB optimization level to Attila.

ToB is supposed to be a DLC pack for Attila, but CA decided to release it as a standalone version to make more money. The problem is, with the release of ToB, Attila didn't receive the update of optimization it should've received with that DLC. Instead, we have unoptimized Attila and a new game, basically modded Attila.

In order to make your Attila work like ToB, you have to manually delete and replace shaders inside data.pack and blood.pack.

Follow this guide:

https://steamcommunity.com/sharedfiles/filedetails/?id=1581603370
Wow.

That's...beautifully simple. Nice!

Going to definitely try this. Thanks!
WhyXelsink Dec 3, 2018 @ 1:24pm 
I'm happy and irritated at the same moment

on one side It's so cool to play Attila with such smooth optimization now
on the other side, It's so ♥♥♥♥♥♥ up that for CA it would take probably 5 minutes to replace that "fxc" folder in data.pack and blood.pack with polished shaders and release an update all of us have been asking for
Originally posted by WhyXelsink:
I'm happy and irritated at the same moment

on one side It's so cool to play Attila with such smooth optimization now
on the other side, It's so ♥♥♥♥♥♥ up that for CA it would take probably 5 minutes to replace that "fxc" folder in data.pack and blood.pack with polished shaders and release an update all of us have been asking for
Lol seriously, right?

"Optimization DLC" for $7.99 incoming, courtesy of $EGA ;)

So what kind of frames are you getting on Attila at all Ultra now? Just curious, because it's going to be some time for me till I can get around to doing this.
WhyXelsink Dec 3, 2018 @ 1:34pm 
look, let me be clear right now

optimization is not about frames, is about will you or will not you lose frames under the certain circumstances

with completely removing old shaders and replacing them with the shaders from ToB the game is smooth af, no huge fps drops during massive battles at all
Werecat101 Dec 3, 2018 @ 2:06pm 
Originally posted by WhyXelsink:
look, let me be clear right now

optimization is not about frames, is about will you or will not you lose frames under the certain circumstances

with completely removing old shaders and replacing them with the shaders from ToB the game is smooth af, no huge fps drops during massive battles at all
ok serious question how many verions of windows have you tried this with?
I run win 7 pro with older Grpahics drivers and have never had FPS related problems. have you tested this fix on win 7?

if you are wondering why I am asking the variables are fairly interesting my Direct-x 9 and GPU drivers dont get updated by automatic updates, people using Windows 10 are subject to updates at regular intervals and those have included Direct-x 9 also the way windows 10 handles some of the graphics creation is slightly different to the system for Windows 7.
Last edited by Werecat101; Dec 3, 2018 @ 2:12pm
Originally posted by WhyXelsink:
look, let me be clear right now

optimization is not about frames, is about will you or will not you lose frames under the certain circumstances

with completely removing old shaders and replacing them with the shaders from ToB the game is smooth af, no huge fps drops during massive battles at all
That's what I meant. Like what mins do you get zoomed now?

In Attila as it is now, vanilla, I can see it drop as low as 10-15 fps zoomed just above large melee.
WhyXelsink Dec 3, 2018 @ 2:09pm 
OS and the guide I've posted do not corelate at all

shaders are for the game

Last edited by WhyXelsink; Dec 3, 2018 @ 2:15pm
Originally posted by steve:
Originally posted by WhyXelsink:
look, let me be clear right now

optimization is not about frames, is about will you or will not you lose frames under the certain circumstances

with completely removing old shaders and replacing them with the shaders from ToB the game is smooth af, no huge fps drops during massive battles at all
ok serious question how many verions of windows have you tried this with?
I run win 7 pro with older Grpahics drivers and have never had FPS related problems. have you tested this fix on win 7?
I'm also curious about that, as I use Win 7 as well.
WhyXelsink Dec 3, 2018 @ 2:10pm 
@Mike, just remind yourself what it felt like to play Tob, it will be the same thing
Werecat101 Dec 3, 2018 @ 2:20pm 
Originally posted by WhyXelsink:
OS and the guide I've posted does not corelate at all

shaders are for the game
well here is a sample of shader coding and if according to you os and Directx are not involved remembering this is a directx game.

look through the sample code and notice D3D11 which are direct3d calls


sample

Here's an example of how you can load shader bytecode:
C++

HRESULT hr = S_OK;

// Use the Direct3D device to load resources into graphics memory.
ID3D11Device* device = m_deviceResources->GetDevice();

// You'll need to use a file loader to load the shader bytecode. In this
// example, we just use the standard library.
FILE* vShader, * pShader;
BYTE* bytes;

size_t destSize = 4096;
size_t bytesRead = 0;
bytes = new BYTE[destSize];

fopen_s(&vShader, "CubeVertexShader.cso", "rb");
bytesRead = fread_s(bytes, destSize, 1, 4096, vShader);
hr = device->CreateVertexShader(
bytes,
bytesRead,
nullptr,
&m_pVertexShader
);

D3D11_INPUT_ELEMENT_DESC iaDesc [] =
{
{ "POSITION", 0, DXGI_FORMAT_R32G32B32_FLOAT,
0, 0, D3D11_INPUT_PER_VERTEX_DATA, 0 },

{ "COLOR", 0, DXGI_FORMAT_R32G32B32_FLOAT,
0, 12, D3D11_INPUT_PER_VERTEX_DATA, 0 },
};

hr = device->CreateInputLayout(
iaDesc,
ARRAYSIZE(iaDesc),
bytes,
bytesRead,
&m_pInputLayout
);

delete bytes;


bytes = new BYTE[destSize];
bytesRead = 0;
fopen_s(&pShader, "CubePixelShader.cso", "rb");
bytesRead = fread_s(bytes, destSize, 1, 4096, pShader);
hr = device->CreatePixelShader(
bytes,
bytesRead,
nullptr,
m_pPixelShader.GetAddressOf()
);

delete bytes;

CD3D11_BUFFER_DESC cbDesc(
sizeof(ConstantBufferStruct),
D3D11_BIND_CONSTANT_BUFFER
);

hr = device->CreateBuffer(
&cbDesc,
nullptr,
m_pConstantBuffer.GetAddressOf()
);

fclose(vShader);
fclose(pShader);


end of sample


now its possible that what they have done is complex shaders that add basic lighting calculations were written for Attila and because they for various reasons worked better on some machines than others, and they reduced the complex shader behaviour and by doing that made the whole system faster and less problematic.
Last edited by Werecat101; Dec 3, 2018 @ 2:28pm
WhyXelsink Dec 3, 2018 @ 2:29pm 
@steve you are making a good point, let me ask you something, is ToB compatible with Windows 7?
WhyXelsink Dec 3, 2018 @ 2:31pm 
by the way, thank you Steve, it was usefull explanation how shaders would work from I can say a person who is closely connected with programming, as I am not a programmer myself
Werecat101 Dec 3, 2018 @ 2:32pm 
ok did you read the last update at the bottom of my last post,

the thing is that I take it you run windows 10 and as such have updated versions of Directx and probably very late drivers for the GPU. the reason I ask is that some people here are running fairly old equipment and as such may not be updating to the latest versions of everything.
WhyXelsink Dec 3, 2018 @ 2:34pm 
that's why I asked you if ToB is supporting Windows 7, if it does, than you are good to go, as we are only using default ToB game files
Last edited by WhyXelsink; Dec 3, 2018 @ 2:35pm
< >
Showing 1-15 of 126 comments
Per page: 1530 50