Enables: Difference between revisions

From wowdev
Jump to navigation Jump to search
No edit summary
(rewritten/reformatted a few existing sentences, introduced info about flag positions -> work in progress, will update 3.3.5a infos as soon as I have confirmed more, details about enables (explaining their purpose) will follow too)
Line 1: Line 1:
'''Enables''' are how WoW rendering engine controls how the world is painted into your screen. We call it '''Enables''' because that's what the reverse engineering suggests. Altough you may see it called "rendering flags" too.
Rendering flags control how the WoW rendering engine paints the world onto the screen.
We call them '''Enables''', because that's what the reverse engineering suggests.


This is how a normal render pipeline works for any WoW version (pseudocode).
This is how a normal render pipeline works for any WoW version (pseudocode):
  Wow.exe-> StormStaticEntryPoint
  Wow.exe-> StormStaticEntryPoint
   Wow.exe-> PaintScreen  
   Wow.exe-> PaintScreen  
Line 27: Line 28:
  Start rendering again
  Start rendering again


So as you can see, the stars, planets, clouds and environment stuff is first painted, then the map ADTs are drawn, RenderMapObjDefGroups are WMOs and get painted after ADTs, then every liquid is painted, after that every M2 (Doodads) are painted too, and finally NPC/Players (RenderObjects) as the last step.
As you can see, the stars, planets, clouds and environment stuff is painted first, then the map ADTs are drawn, RenderMapObjDefGroups are WMOs and get painted after ADTs, then every liquid is painted, after that every M2 (Doodads) are painted too, and finally NPC/Players (RenderObjects).


== Enables ==
== Offsets & Default Values ==
You should know that poking these Enables may crash your client, specially in early versions of the game (alpha, vanilla, tbc)
The flags are stored in 4 Bytes (= 32 Bits) at a static offset which differs every version.
Changing Enables may crash your client - especially earlier versions pre '''Wrath of the Lich King''' are prone to this.
The following list contains data in the format: [version], offset, default value


The following list of addreses can be used to find '''Enables''' in the mentioned versions:
  [0.5.3]
  ['0.5.3']:
  0x00A4046C
  renderFlags: 0xA4046C,
  0x07104B73
  renderFlagsDefault: 0x07104B73
['0.8.0']:
renderFlags: 0xA96C30,
renderFlagsDefault: 0x1F900B77
['1.1.2']:
renderFlags: 0x69FE7C,
renderFlagsDefault: 0x1F110F77
['1.8.0']:
renderFlags: 0x7EC93C,
renderFlagsDefault: 0x9F110F77
['1.12.0']:
renderFlags: 0x87B2A4,
renderFlagsDefault: 0x9F910F77
['2.4.3']:
renderFlags: 0x9A4510,
renderFlagsDefault: 0x1F104F73
['3.3.5a']:
renderFlags: 0x8D774C,
renderFlagsDefault: 0x1F104F73
['4.3.4']:
renderFlags: 0xA741A8,
renderFlagsDefault: 0x0001BFFF
['5.4.8']:
renderFlags: 0xE371D4,
renderFlagsDefault: 0x0001BFFF
['6.2.3']:
renderFlags: 0xF8422C,
renderFlagsDefault: 0x00011FFF
['7.2.5']:
renderFlags: 0x102FF3C,
renderFlagsDefault: 0x7FF7FFFF
['7.3.5']:
renderFlags: 0x1252CC0,
renderFlagsDefault: 0x7FF7FFFF


Where '''renderFlags''' is the location of '''Enables''' in the memory (WoW.exe + renderFlags) and '''renderFlagsDefault''' is the default value for that version, just in case you have to reset it.
[0.8.0]
0x00A96C30
0x1F900B77


Depending on the WoW version you may see a different rendering mode as none all modes are supported in all the clients. And in all years of development these have evolved for obviously reasons.
[1.1.2]
0x0069FE7C
0x1F110F77


WoW Alpha 0.5.3 is quite special on how Enables work, as you may see some rendering flags that doesn't exist in Vanilla and above.
[1.8.0]
0x007EC93C
0x9F110F77
 
[1.12.0]
0x0087B2A4
0x9F910F77
 
[2.4.3]
0x009A4510
0x1F104F73
 
[3.3.5a]
0x008D774C
0x1F104F73
 
[4.3.4]
0x00A741A8
0x0001BFFF
 
[5.4.8]
0x00E371D4
0x0001BFFF
 
[6.2.3]
0x00F8422C
0x00011FFF
 
[7.2.5]
0x0102FF3C
0x7FF7FFFF
 
[7.3.5]
0x01252CC0
0x7FF7FFFF
 
== Flag Positions ==
Throughout all the years of development the list of available Enables and their respective positions has changed a lot.
Certain Bits might not have any effect at all or their purpose hasn't been determined yet.
 
[1.12.1]
0x00000001 PixelShaders
0x00000002 Specular
0x00000004 MapObjectTextures
0x00000008
0x00000010
0x00000020 ShowQuery
0x00000040 MapObjectLighting
0x00000080 PortalDisplay
0x00000100 TerrainLowDetail
0x00000200 TerrainShadows
0x00000400 TriangleStrips
0x00000800 TerrainLOD
0x00001000 TerrainDoodadCollisionVisuals
0x00002000 TerrainDoodadAABoxVisuals
0x00004000
0x00008000 TrilinearFiltering
0x00010000 FootPrints
0x00020000 Water
0x00040000 Anisotropic
0x00080000 WaterParticulates
0x00100000
0x00200000 TerrainCulling
0x00400000 PortalVisual
0x00800000 DoodadAnimation
0x01000000 CrappyBatches
0x02000000 BSPRender
0x04000000 MapObjects
0x08000000 Terrain
0x10000000 TerrainDoodads
0x20000000 DisableDoodadFullAlpha
0x40000000 DetailDoodads
0x80000000 ZoneBoundaryVisuals
 
[3.3.5a]
0x00000001 showDoodads
0x00000002 showTerrain
0x00000004
0x00000008
0x00000010
0x00000020 TerrainCulling
0x00000040
0x00000080
0x00000100 MapObjects
0x00000200 MapObjectLighting
0x00000400 showFootPrints
0x00000800 MapObjectTextures
0x00001000 showPortals
0x00002000
0x00004000
0x00008000
0x00010000
0x00020000
0x00040000
0x00080000
0x00100000 showDetailDoodads
0x00200000 showCollision
0x00400000
0x00800000
0x01000000 showWater
0x02000000 showParticulates
0x04000000 showHorizonMountains
0x08000000
0x10000000
0x20000000 showTris
0x40000000 showNormals
0x80000000
 
[6.0.1]
0x00000001 showDoodads
0x00000002 showTerrain
0x00000004
0x00000008
0x00000010 showShadow
0x00000020 showMapObjs
0x00000040 showFootPrints
0x00000080 showDetailDoodads
0x00000100 showLowDetail
0x00000200 showWater
0x00000400 showParticulates
0x00000800 projectedTextures
0x00001000 occlusion
0x00002000
0x00004000
0x00008000 terrainTextureLod
0x00010000 hardware PCF
0x00020000
0x00040000
0x00080000
0x00100000 showPortals
0x00200000 showCollision
0x00400000 showOccluders
0x00800000 showTerrainOccluders
0x01000000 showChunkBatches
0x02000000 debugShowZoneBounds
0x04000000 showQuery
0x08000000 showTris
0x10000000 showNormals
0x20000000 showFlightBounds
0x40000000 terrainHoles
0x80000000
 
== WoW Alpha 0.5.3 ==
 
This version is quite special in terms of Enables, as some rendering flags don't exist in Vanilla and beyond.
One great thing about these Enables is, that they can be used to illuminate some parts of WoW that weren't illumated properly, like Dun Garok.
[[File:M2 collision boxes.jpg|thumb|left|M2 Collision Boxes]]
[[File:M2 collision boxes.jpg|thumb|left|M2 Collision Boxes]]
[[File:Looking for the "Lisa" wall.jpg|thumb|left|Looking for the "Lisa" wall]]
[[File:Looking for the "Lisa" wall.jpg|thumb|left|Looking for the "Lisa" wall]]
[[File:Pikes over M2.jpg|thumb|left|Pikes over M2]]
[[File:Pikes over M2.jpg|thumb|left|Pikes over M2]]
One great thing about these Enables is that they can be used to illuminate some parts of WoW that weren't illumated properly, like Dun Garok in WoW 0.5.3.
[[File:Dun Garok without lightning.jpg|thumb|left|Dun Garok ]]
[[File:Dun Garok without lightning.jpg|thumb|left|Dun Garok ]]
[[File:Dun Garok with lightning enabled (80999007).jpg|thumb|left|Dun Garok with lightning]]
[[File:Dun Garok with lightning enabled (80999007).jpg|thumb|left|Dun Garok with lightning]]

Revision as of 02:46, 28 April 2022

Rendering flags control how the WoW rendering engine paints the world onto the screen. We call them Enables, because that's what the reverse engineering suggests.

This is how a normal render pipeline works for any WoW version (pseudocode):

Wow.exe-> StormStaticEntryPoint
 Wow.exe-> PaintScreen 
   Wow.exe-> OnPaint
   Wow.exe-> CGWorldFrame::RenderWorld 
       Wow.exe-> CGWorldFrame::OnWorldRender 
       Wow.exe-> CWorld::Render
           WoW.exe.DayNightRenderSky
               WoW.exe.GxSceneClear
               WoW.exe.DNSky::Render
               WoW.exe.DNStars::Render
               WoW.exe.DNPlanet::Render
               WoW.exe.DNPlanet::Render
               WoW.exe.DNClouds::Render
           WoW.exe.CWorldScene::RenderHorizon
           WoW.exe.CWorldScene::RenderChunks
           WoW.exe.CWorldScene::RenderMapObjDefGroups
           WoW.exe.CWorldScene::RenderOcean
           WoW.exe.CWorldScene::RenderWater
           WoW.exe.CWorldScene::RenderMagma
           WoW.exe.GxXformPop
           WoW.exe.GxRsPop
           WoW.exe.CWorldScene::RenderDoodads
           WoW.exe.CWorldScene::RenderObjects
Start rendering again

As you can see, the stars, planets, clouds and environment stuff is painted first, then the map ADTs are drawn, RenderMapObjDefGroups are WMOs and get painted after ADTs, then every liquid is painted, after that every M2 (Doodads) are painted too, and finally NPC/Players (RenderObjects).

Offsets & Default Values

The flags are stored in 4 Bytes (= 32 Bits) at a static offset which differs every version. Changing Enables may crash your client - especially earlier versions pre Wrath of the Lich King are prone to this. The following list contains data in the format: [version], offset, default value

[0.5.3]
0x00A4046C
0x07104B73
[0.8.0]
0x00A96C30
0x1F900B77
[1.1.2]
0x0069FE7C
0x1F110F77
[1.8.0]
0x007EC93C
0x9F110F77
[1.12.0]
0x0087B2A4
0x9F910F77
[2.4.3]
0x009A4510
0x1F104F73
[3.3.5a]
0x008D774C
0x1F104F73
[4.3.4]
0x00A741A8
0x0001BFFF
[5.4.8]
0x00E371D4
0x0001BFFF
[6.2.3]
0x00F8422C
0x00011FFF
[7.2.5]
0x0102FF3C
0x7FF7FFFF
[7.3.5]
0x01252CC0
0x7FF7FFFF

Flag Positions

Throughout all the years of development the list of available Enables and their respective positions has changed a lot. Certain Bits might not have any effect at all or their purpose hasn't been determined yet.

[1.12.1]
0x00000001 PixelShaders
0x00000002 Specular
0x00000004 MapObjectTextures
0x00000008 
0x00000010 
0x00000020 ShowQuery
0x00000040 MapObjectLighting
0x00000080 PortalDisplay
0x00000100 TerrainLowDetail
0x00000200 TerrainShadows
0x00000400 TriangleStrips
0x00000800 TerrainLOD
0x00001000 TerrainDoodadCollisionVisuals
0x00002000 TerrainDoodadAABoxVisuals
0x00004000 
0x00008000 TrilinearFiltering
0x00010000 FootPrints
0x00020000 Water
0x00040000 Anisotropic
0x00080000 WaterParticulates
0x00100000 
0x00200000 TerrainCulling
0x00400000 PortalVisual
0x00800000 DoodadAnimation
0x01000000 CrappyBatches
0x02000000 BSPRender
0x04000000 MapObjects
0x08000000 Terrain
0x10000000 TerrainDoodads
0x20000000 DisableDoodadFullAlpha
0x40000000 DetailDoodads
0x80000000 ZoneBoundaryVisuals
[3.3.5a]
0x00000001 showDoodads
0x00000002 showTerrain
0x00000004 
0x00000008 
0x00000010 
0x00000020 TerrainCulling
0x00000040 
0x00000080 
0x00000100 MapObjects
0x00000200 MapObjectLighting
0x00000400 showFootPrints
0x00000800 MapObjectTextures
0x00001000 showPortals
0x00002000 
0x00004000 
0x00008000 
0x00010000 
0x00020000 
0x00040000 
0x00080000 
0x00100000 showDetailDoodads
0x00200000 showCollision
0x00400000 
0x00800000 
0x01000000 showWater
0x02000000 showParticulates
0x04000000 showHorizonMountains
0x08000000 
0x10000000 
0x20000000 showTris
0x40000000 showNormals
0x80000000 
[6.0.1]
0x00000001 showDoodads
0x00000002 showTerrain
0x00000004 
0x00000008 
0x00000010 showShadow
0x00000020 showMapObjs
0x00000040 showFootPrints
0x00000080 showDetailDoodads
0x00000100 showLowDetail
0x00000200 showWater
0x00000400 showParticulates
0x00000800 projectedTextures
0x00001000 occlusion
0x00002000 
0x00004000 
0x00008000 terrainTextureLod
0x00010000 hardware PCF
0x00020000 
0x00040000 
0x00080000 
0x00100000 showPortals
0x00200000 showCollision
0x00400000 showOccluders
0x00800000 showTerrainOccluders
0x01000000 showChunkBatches
0x02000000 debugShowZoneBounds
0x04000000 showQuery
0x08000000 showTris
0x10000000 showNormals
0x20000000 showFlightBounds
0x40000000 terrainHoles
0x80000000

WoW Alpha 0.5.3

This version is quite special in terms of Enables, as some rendering flags don't exist in Vanilla and beyond. One great thing about these Enables is, that they can be used to illuminate some parts of WoW that weren't illumated properly, like Dun Garok.

M2 Collision Boxes
Looking for the "Lisa" wall
Pikes over M2
Dun Garok
Dun Garok with lightning