mirror of
https://github.com/cemu-project/cemu_graphic_packs.git
synced 2025-04-29 14:59:29 -04:00
New MK8 mods and add give old mods v1 support
This commit is contained in:
parent
0914ce04e0
commit
5c12e9ff97
20 changed files with 689 additions and 49 deletions
19
src/MarioKart8/Cheats/CourseUnlock/patch_CourseUnlock.asm
Normal file
19
src/MarioKart8/Cheats/CourseUnlock/patch_CourseUnlock.asm
Normal file
|
@ -0,0 +1,19 @@
|
|||
[MarioKart8_CourseUnlock]
|
||||
moduleMatches = 0x9F0A90B7, 0xD09700CE ; v4.2(EU/NA/JP), v4.1(EU/NA/JP)
|
||||
.origin = codecave
|
||||
UnlockCourses:
|
||||
lis r30, 0x0303
|
||||
ori r30, r30, 0x0303
|
||||
stw r30, 0(r11)
|
||||
stw r30, 4(r11)
|
||||
lbzx r30, r11, r0
|
||||
blr
|
||||
|
||||
[MarioKart8_CourseUnlock_v42]
|
||||
moduleMatches = 0x9F0A90B7 ; v4.2(EU/NA/JP)
|
||||
;this mod makes every byte at 0x2e6b6668 = 3
|
||||
0x024D74CC = bla UnlockCourses
|
||||
|
||||
[MarioKart8_CourseUnlock_v41]
|
||||
moduleMatches = 0xD09700CE ; v4.1(EU/NA/JP)
|
||||
0x024D7148 = bla UnlockCourses
|
7
src/MarioKart8/Cheats/CourseUnlock/rules.txt
Normal file
7
src/MarioKart8/Cheats/CourseUnlock/rules.txt
Normal file
|
@ -0,0 +1,7 @@
|
|||
[Definition]
|
||||
titleIds = 000500001010EC00,000500001010ED00,000500001010EB00
|
||||
name = Course Unlock
|
||||
path = "Mario Kart 8/Cheats/Course Unlock"
|
||||
description = Unlock Every Course + Mirror Mode!
|
||||
#Credits: Intra
|
||||
version = 7
|
|
@ -0,0 +1,10 @@
|
|||
[MarioKart8_OnlineBattleRating_v42]
|
||||
moduleMatches = 0x9F0A90B7 ; v4.2(EU/NA/JP)
|
||||
.origin = codecave
|
||||
ChangeOnlineBattleRating:
|
||||
li r10, $battlevr
|
||||
stw r10, 0x1a24(r29)
|
||||
blr
|
||||
|
||||
;this mod makes 0x2e6b6664 = $battlevr
|
||||
0x024DCE58 = bla ChangeOnlineBattleRating
|
35
src/MarioKart8/Cheats/OnlineBattleRating/rules.txt
Normal file
35
src/MarioKart8/Cheats/OnlineBattleRating/rules.txt
Normal file
|
@ -0,0 +1,35 @@
|
|||
[Definition]
|
||||
titleIds = 000500001010EC00,000500001010ED00,000500001010EB00
|
||||
name = Change Online Battle Rating
|
||||
path = "Mario Kart 8/Cheats/Online Battle Rating"
|
||||
description = Change Your Online Battle Rating!
|
||||
#Credits: Intra
|
||||
version = 7
|
||||
|
||||
[Default]
|
||||
$battlevr = 1000
|
||||
|
||||
[Preset]
|
||||
category = Battle Rating:
|
||||
name = 1
|
||||
$battlevr = 1
|
||||
|
||||
[Preset]
|
||||
category = Battle Rating:
|
||||
name = 1000
|
||||
Default = 1
|
||||
|
||||
[Preset]
|
||||
category = Battle Rating:
|
||||
name = 2000
|
||||
$battlevr = 2000
|
||||
|
||||
[Preset]
|
||||
category = Battle Rating:
|
||||
name = 3000
|
||||
$battlevr = 3000
|
||||
|
||||
[Preset]
|
||||
category = Battle Rating:
|
||||
name = 4000
|
||||
$battlevr = 4000
|
|
@ -0,0 +1,10 @@
|
|||
[MarioKart8_OnlineRaceRating_v42]
|
||||
moduleMatches = 0x9F0A90B7 ; v4.2(EU/NA/JP)
|
||||
.origin = codecave
|
||||
ChangeOnlineRaceRating:
|
||||
li r8, $racevr
|
||||
stw r8, 0x1a20(r29)
|
||||
blr
|
||||
|
||||
;this mod makes 0x2e6b6660 = $racevr
|
||||
0x024DCE2C = bla ChangeOnlineRaceRating
|
50
src/MarioKart8/Cheats/OnlineRaceRating/rules.txt
Normal file
50
src/MarioKart8/Cheats/OnlineRaceRating/rules.txt
Normal file
|
@ -0,0 +1,50 @@
|
|||
[Definition]
|
||||
titleIds = 000500001010EC00,000500001010ED00,000500001010EB00
|
||||
name = Change Online Race Rating
|
||||
path = "Mario Kart 8/Cheats/Online Race Rating"
|
||||
description = Change Your Online Race Rating!|150cc lobbies start happening at 5000vr.
|
||||
#Credits: Intra
|
||||
version = 7
|
||||
|
||||
[Default]
|
||||
$racevr = 1000
|
||||
|
||||
[Preset]
|
||||
category = Race Rating:
|
||||
name = 1
|
||||
$racevr = 1
|
||||
|
||||
[Preset]
|
||||
category = Race Rating:
|
||||
name = 1000
|
||||
Default = 1
|
||||
|
||||
[Preset]
|
||||
category = Race Rating:
|
||||
name = 2000
|
||||
$racevr = 2000
|
||||
|
||||
[Preset]
|
||||
category = Race Rating:
|
||||
name = 3000
|
||||
$racevr = 3000
|
||||
|
||||
[Preset]
|
||||
category = Race Rating:
|
||||
name = 4000
|
||||
$racevr = 4000
|
||||
|
||||
[Preset]
|
||||
category = Race Rating:
|
||||
name = 5000
|
||||
$racevr = 5000
|
||||
|
||||
[Preset]
|
||||
category = Race Rating:
|
||||
name = 6000
|
||||
$racevr = 6000
|
||||
|
||||
[Preset]
|
||||
category = Race Rating:
|
||||
name = 7000
|
||||
$racevr = 7000
|
94
src/MarioKart8/Cheats/TrophyCheat/patch_TrophyCheat.asm
Normal file
94
src/MarioKart8/Cheats/TrophyCheat/patch_TrophyCheat.asm
Normal file
|
@ -0,0 +1,94 @@
|
|||
[MarioKart8_GoldTrophy]
|
||||
moduleMatches = 0x9F0A90B7, 0xD09700CE ; v4.2(EU/NA/JP), v4.1(EU/NA/JP)
|
||||
.origin = codecave
|
||||
|
||||
WriteTrophies:
|
||||
addi r11, r11, -1
|
||||
mtctr r12
|
||||
_forloopWriteTrophies:
|
||||
stbu r8, 1(r11)
|
||||
bdnz _forloopWriteTrophies
|
||||
blr
|
||||
|
||||
CheckandChangeTrophies:
|
||||
mflr r0
|
||||
;check cheat
|
||||
li r8, $cheattype
|
||||
cmpwi r8, 3
|
||||
beq Cheat3StarEVERYTHING
|
||||
cmpwi r8, 2
|
||||
beq CheatEntireEngineClass
|
||||
cmpwi r8, 1
|
||||
beq CheatSpecificCup
|
||||
b CheckandChangeTrophies_Exit
|
||||
|
||||
CheatSpecificCup:
|
||||
li r8, $trophy
|
||||
addi r11, r7, 0x5c4+$addroffset
|
||||
stb r8, $cup(r11)
|
||||
li r8, $stars
|
||||
addi r11, r7, 0x5c4+$addroffset-0x100
|
||||
stb r8, $cup(r11)
|
||||
b CheckandChangeTrophies_Exit
|
||||
|
||||
CheatEntireEngineClass:
|
||||
li r12, 12
|
||||
li r8, $trophy
|
||||
addi r11, r7, 0x5c4+$addroffset
|
||||
bl WriteTrophies
|
||||
li r8, $stars
|
||||
addi r11, r7, 0x5c4+$addroffset-0x100
|
||||
bl WriteTrophies
|
||||
b CheckandChangeTrophies_Exit
|
||||
|
||||
Cheat3StarEVERYTHING:
|
||||
li r12, 12
|
||||
;50cc
|
||||
li r8, $trophy
|
||||
addi r11, r7, 0x5c4
|
||||
bl WriteTrophies
|
||||
li r8, $stars
|
||||
addi r11, r7, 0x5c4-0x100
|
||||
bl WriteTrophies
|
||||
;100cc
|
||||
li r8, $trophy
|
||||
addi r11, r7, 0x5c4+0x20
|
||||
bl WriteTrophies
|
||||
li r8, $stars
|
||||
addi r11, r7, 0x5c4+0x20-0x100
|
||||
bl WriteTrophies
|
||||
;150cc
|
||||
li r8, $trophy
|
||||
addi r11, r7, 0x5c4+0x40
|
||||
bl WriteTrophies
|
||||
li r8, $stars
|
||||
addi r11, r7, 0x5c4+0x40-0x100
|
||||
bl WriteTrophies
|
||||
;Mirror
|
||||
li r8, $trophy
|
||||
addi r11, r7, 0x5c4+0x80
|
||||
bl WriteTrophies
|
||||
li r8, $stars
|
||||
addi r11, r7, 0x5c4+0x80-0x100
|
||||
bl WriteTrophies
|
||||
;200cc
|
||||
li r8, $trophy
|
||||
addi r11, r7, 0x5c4+0x60
|
||||
bl WriteTrophies
|
||||
li r8, $stars
|
||||
addi r11, r7, 0x5c4+0x60-0x100
|
||||
bl WriteTrophies
|
||||
|
||||
CheckandChangeTrophies_Exit:
|
||||
mtlr r0
|
||||
lwz r8, 0(r29)
|
||||
blr
|
||||
|
||||
[MarioKart8_GoldTrophy_v42]
|
||||
moduleMatches = 0x9F0A90B7 ; v4.2(EU/NA/JP)
|
||||
;modifies near 0x2E6B520C
|
||||
0x024D97F8 = bla CheckandChangeTrophies
|
||||
|
||||
[MarioKart8_GoldTrophy_v41]
|
||||
moduleMatches = 0xD09700CE ; v4.1(EU/NA/JP)
|
||||
0x024d9474 = bla CheckandChangeTrophies
|
171
src/MarioKart8/Cheats/TrophyCheat/rules.txt
Normal file
171
src/MarioKart8/Cheats/TrophyCheat/rules.txt
Normal file
|
@ -0,0 +1,171 @@
|
|||
[Definition]
|
||||
titleIds = 000500001010EC00,000500001010ED00,000500001010EB00
|
||||
name = Gold Trophy / 3 stars
|
||||
path = "Mario Kart 8/Cheats/Grand Prix Trophies"
|
||||
description = Cheat in Grand Prix Trohpies!|Must complete or quit a Grand Prix to save changes.
|
||||
#Credits: Intra
|
||||
version = 7
|
||||
|
||||
[Default]
|
||||
$addroffset = 0
|
||||
$cup = 0
|
||||
$cheattype = 1
|
||||
$trophy = 0
|
||||
$stars = 0
|
||||
|
||||
[Preset]
|
||||
category = Cheat Type
|
||||
name = Change EVERYTHING (200/mirror/150/100/50)
|
||||
$cheattype = 3
|
||||
|
||||
[Preset]
|
||||
category = Cheat Type
|
||||
name = Change Entire Engine Class
|
||||
$cheattype = 2
|
||||
|
||||
[Preset]
|
||||
category = Cheat Type
|
||||
name = Change Specific Cup (activates by cursor moving onto 50cc)
|
||||
$cheattype = 1
|
||||
|
||||
[Preset]
|
||||
category = Engine Class
|
||||
condition = $cheattype != 3
|
||||
name = 50cc
|
||||
$addroffset = 0
|
||||
|
||||
[Preset]
|
||||
category = Engine Class
|
||||
condition = $cheattype != 3
|
||||
name = 100cc
|
||||
$addroffset = 0x20
|
||||
|
||||
[Preset]
|
||||
category = Engine Class
|
||||
condition = $cheattype != 3
|
||||
name = 150cc
|
||||
$addroffset = 0x40
|
||||
|
||||
[Preset]
|
||||
category = Engine Class
|
||||
condition = $cheattype != 3
|
||||
name = Mirror
|
||||
$addroffset = 0x80
|
||||
|
||||
[Preset]
|
||||
category = Engine Class
|
||||
condition = $cheattype != 3
|
||||
name = 200cc
|
||||
$addroffset = 0x60
|
||||
|
||||
[Preset]
|
||||
category = Course
|
||||
condition = $cheattype == 1
|
||||
name = Mushroom Cup
|
||||
$cup = 0
|
||||
|
||||
[Preset]
|
||||
category = Course
|
||||
condition = $cheattype == 1
|
||||
name = Flower Cup
|
||||
$cup = 1
|
||||
|
||||
[Preset]
|
||||
category = Course
|
||||
condition = $cheattype == 1
|
||||
name = Star Cup
|
||||
$cup = 2
|
||||
|
||||
[Preset]
|
||||
category = Course
|
||||
condition = $cheattype == 1
|
||||
name = Special Cup
|
||||
$cup = 3
|
||||
|
||||
[Preset]
|
||||
category = Course
|
||||
condition = $cheattype == 1
|
||||
name = Shell Cup
|
||||
$cup = 4
|
||||
|
||||
[Preset]
|
||||
category = Course
|
||||
condition = $cheattype == 1
|
||||
name = Banana Cup
|
||||
$cup = 5
|
||||
|
||||
[Preset]
|
||||
category = Course
|
||||
condition = $cheattype == 1
|
||||
name = Leaf Cup
|
||||
$cup = 6
|
||||
|
||||
[Preset]
|
||||
category = Course
|
||||
condition = $cheattype == 1
|
||||
name = Lightning Cup
|
||||
$cup = 7
|
||||
|
||||
[Preset]
|
||||
category = Course
|
||||
condition = $cheattype == 1
|
||||
name = Egg Cup
|
||||
$cup = 8
|
||||
|
||||
[Preset]
|
||||
category = Course
|
||||
condition = $cheattype == 1
|
||||
name = Triforce Cup
|
||||
$cup = 9
|
||||
|
||||
[Preset]
|
||||
category = Course
|
||||
condition = $cheattype == 1
|
||||
name = Crossing Cup
|
||||
$cup = 10
|
||||
|
||||
[Preset]
|
||||
category = Course
|
||||
condition = $cheattype == 1
|
||||
name = Bell Cup
|
||||
$cup = 11
|
||||
|
||||
[Preset]
|
||||
category = Trophy
|
||||
name = Gold
|
||||
$trophy = 3
|
||||
|
||||
[Preset]
|
||||
category = Trophy
|
||||
name = Silver
|
||||
$trophy = 2
|
||||
|
||||
[Preset]
|
||||
category = Trophy
|
||||
name = Bronze
|
||||
$trophy = 1
|
||||
|
||||
[Preset]
|
||||
category = Trophy
|
||||
name = None
|
||||
$trophy = 0
|
||||
|
||||
[Preset]
|
||||
category = Stars
|
||||
name = 3
|
||||
$stars = 3
|
||||
|
||||
[Preset]
|
||||
category = Stars
|
||||
name = 2
|
||||
$stars = 2
|
||||
|
||||
[Preset]
|
||||
category = Stars
|
||||
name = 1
|
||||
$stars = 1
|
||||
|
||||
[Preset]
|
||||
category = Stars
|
||||
name = 0
|
||||
$stars = 0
|
|
@ -0,0 +1,26 @@
|
|||
[MarioKart8_UnlockCharacter]
|
||||
moduleMatches = 0x9F0A90B7, 0xD09700CE ; v4.2(EU/NA/JP), v4.1(EU/NA/JP)
|
||||
.origin = codecave
|
||||
|
||||
UnlockCharactersMod:
|
||||
;r11 == 0x2e6b6690
|
||||
lis r30, 0x0303
|
||||
ori r30, r30, 0x0303
|
||||
stw r30, 0x0(r11)
|
||||
stw r30, 0x4(r11)
|
||||
stw r30, 0x8(r11)
|
||||
stw r30, 0xC(r11)
|
||||
stw r30, 0x10(r11)
|
||||
stw r30, 0x14(r11)
|
||||
stw r30, 0x18(r11)
|
||||
sth r30, 0x1C(r11)
|
||||
lbzx r30, r11, r0
|
||||
blr
|
||||
|
||||
[MarioKart8_UnlockCharacter_v42]
|
||||
moduleMatches = 0x9F0A90B7 ; v4.2(EU/NA/JP)
|
||||
0x024D76AC = bla UnlockCharactersMod
|
||||
|
||||
[MarioKart8_UnlockCharacter_v41]
|
||||
moduleMatches = 0xD09700CE ; v4.1(EU/NA/JP)
|
||||
0x024D7328 = bla UnlockCharactersMod
|
7
src/MarioKart8/Cheats/UnlockCharacters/rules.txt
Normal file
7
src/MarioKart8/Cheats/UnlockCharacters/rules.txt
Normal file
|
@ -0,0 +1,7 @@
|
|||
[Definition]
|
||||
titleIds = 000500001010EC00,000500001010ED00,000500001010EB00
|
||||
name = Unlock Characters!
|
||||
path = "Mario Kart 8/Cheats/Unlock Characters"
|
||||
description = Unlock Every Character!
|
||||
#Credits: Intra
|
||||
version = 7
|
24
src/MarioKart8/Cheats/UnlockStamps/patch_UnlockStamps.asm
Normal file
24
src/MarioKart8/Cheats/UnlockStamps/patch_UnlockStamps.asm
Normal file
|
@ -0,0 +1,24 @@
|
|||
[MarioKart8_UnlockCharacter]
|
||||
moduleMatches = 0x9F0A90B7, 0xD09700CE ; v4.2(EU/NA/JP), v4.1(EU/NA/JP)
|
||||
.origin = codecave
|
||||
|
||||
UnlockStamps:
|
||||
;r11 == 0x2e6b6790
|
||||
li r12, 3 ;;
|
||||
li r30, 90
|
||||
mtctr r30
|
||||
addi r30, r11, 10-1
|
||||
_forloopUnlockStamps:
|
||||
stbu r12, 1(r30)
|
||||
bdnz _forloopUnlockStamps
|
||||
|
||||
lbzx r30,r11,r0
|
||||
blr
|
||||
|
||||
[MarioKart8_UnlockCharacter_v42]
|
||||
moduleMatches = 0x9F0A90B7 ; v4.2(EU/NA/JP)
|
||||
0x024D7A6C = bla UnlockStamps
|
||||
|
||||
[MarioKart8_UnlockCharacter_v41]
|
||||
moduleMatches = 0xD09700CE ; v4.1(EU/NA/JP)
|
||||
0x024D76E8 = bla UnlockStamps
|
7
src/MarioKart8/Cheats/UnlockStamps/rules.txt
Normal file
7
src/MarioKart8/Cheats/UnlockStamps/rules.txt
Normal file
|
@ -0,0 +1,7 @@
|
|||
[Definition]
|
||||
titleIds = 000500001010EC00,000500001010ED00,000500001010EB00
|
||||
name = Unlock Stamps!
|
||||
path = "Mario Kart 8/Cheats/Unlock Stamps"
|
||||
description = Unlock All 100 Stamps!
|
||||
#Credits: Intra
|
||||
version = 7
|
|
@ -0,0 +1,21 @@
|
|||
[MarioKart8_UnlockVehicle]
|
||||
moduleMatches = 0x9F0A90B7, 0xD09700CE ; v4.2(EU/NA/JP), v4.1(EU/NA/JP)
|
||||
.origin = codecave
|
||||
|
||||
CheckandChangeCoinAmmount:
|
||||
lwz r0, 0x14e0(r26)
|
||||
cmpwi r0, $coinammount
|
||||
bge CheckandChangeCoinAmmount_Exit
|
||||
li r0, $coinammount
|
||||
stw r0, 0x14e0(r26)
|
||||
CheckandChangeCoinAmmount_Exit:
|
||||
blr
|
||||
|
||||
[MarioKart8_UnlockVehicle_v42]
|
||||
moduleMatches = 0x9F0A90B7 ; v4.2(EU/NA/JP)
|
||||
;this mod makes 0x2e6b6128 = $coinammount
|
||||
0x025A4038 = bla CheckandChangeCoinAmmount
|
||||
|
||||
[MarioKart8_UnlockVehicle_v41]
|
||||
moduleMatches = 0xD09700CE ; v4.1(EU/NA/JP)
|
||||
0x025A3E84 = bla CheckandChangeCoinAmmount
|
18
src/MarioKart8/Cheats/UnlockVehicleParts/rules.txt
Normal file
18
src/MarioKart8/Cheats/UnlockVehicleParts/rules.txt
Normal file
|
@ -0,0 +1,18 @@
|
|||
[Definition]
|
||||
titleIds = 000500001010EC00,000500001010ED00,000500001010EB00
|
||||
name = Unlock Vehicle Parts!
|
||||
path = "Mario Kart 8/Mods/Unlock Vehicle Parts"
|
||||
description = Unlock every non-golden vehicle part!|Must activate by pressing (-) on the main menu to view your playstats.|Then do a race to save the new value.
|
||||
#Credits: Intra
|
||||
version = 7
|
||||
|
||||
[Default]
|
||||
$coinammount = 0
|
||||
|
||||
[Preset]
|
||||
name = Unlock all non-golden parts (sets coins to 2800)
|
||||
$coinammount = 2800
|
||||
|
||||
[Preset]
|
||||
name = Unlock Golden Glider (sets coins to 10000)
|
||||
$coinammount = 10000
|
|
@ -0,0 +1,129 @@
|
|||
#version 430
|
||||
#extension GL_ARB_texture_gather : enable
|
||||
#ifdef VULKAN
|
||||
#define ATTR_LAYOUT(__vkSet, __location) layout(set = __vkSet, location = __location)
|
||||
#define UNIFORM_BUFFER_LAYOUT(__glLocation, __vkSet, __vkLocation) layout(set = __vkSet, binding = __vkLocation, std140)
|
||||
#define TEXTURE_LAYOUT(__glLocation, __vkSet, __vkLocation) layout(set = __vkSet, binding = __vkLocation)
|
||||
#define SET_POSITION(_v) gl_Position = _v; gl_Position.z = (gl_Position.z + gl_Position.w) / 2.0
|
||||
#define GET_FRAGCOORD() vec4(gl_FragCoord.xy*uf_fragCoordScale.xy,gl_FragCoord.zw)
|
||||
#define gl_VertexID gl_VertexIndex
|
||||
#define gl_InstanceID gl_InstanceIndex
|
||||
#else
|
||||
#define ATTR_LAYOUT(__vkSet, __location) layout(location = __location)
|
||||
#define UNIFORM_BUFFER_LAYOUT(__glLocation, __vkSet, __vkLocation) layout(binding = __glLocation, std140)
|
||||
#define TEXTURE_LAYOUT(__glLocation, __vkSet, __vkLocation) layout(binding = __glLocation)
|
||||
#define SET_POSITION(_v) gl_Position = _v
|
||||
#define GET_FRAGCOORD() vec4(gl_FragCoord.xy*uf_fragCoordScale,gl_FragCoord.zw)
|
||||
#endif
|
||||
// This shaders was auto-converted from OpenGL to Cemu.
|
||||
|
||||
// shader e90feef2bca6cb2e
|
||||
const float bloomFactor = $bloom;
|
||||
|
||||
#ifdef VULKAN
|
||||
layout(set = 1, binding = 2) uniform ufBlock
|
||||
{
|
||||
uniform ivec4 uf_remappedPS[4];
|
||||
uniform vec4 uf_fragCoordScale;
|
||||
};
|
||||
#else
|
||||
uniform ivec4 uf_remappedPS[4];
|
||||
uniform vec2 uf_fragCoordScale;
|
||||
#endif
|
||||
TEXTURE_LAYOUT(0, 1, 0) uniform sampler2D textureUnitPS0;
|
||||
TEXTURE_LAYOUT(1, 1, 1) uniform sampler2D textureUnitPS1;
|
||||
layout(location = 0) in vec4 passParameterSem0;
|
||||
layout(location = 1) in vec4 passParameterSem1;
|
||||
layout(location = 2) in vec4 passParameterSem2;
|
||||
layout(location = 0) out vec4 passPixelColor0;
|
||||
// uf_fragCoordScale was moved to the ufBlock
|
||||
int clampFI32(int v)
|
||||
{
|
||||
if( v == 0x7FFFFFFF )
|
||||
return floatBitsToInt(1.0);
|
||||
else if( v == 0xFFFFFFFF )
|
||||
return floatBitsToInt(0.0);
|
||||
return floatBitsToInt(clamp(intBitsToFloat(v), 0.0, 1.0));
|
||||
}
|
||||
float mul_nonIEEE(float a, float b){ if( a == 0.0 || b == 0.0 ) return 0.0; return a*b; }
|
||||
void main()
|
||||
{
|
||||
vec4 R0f = vec4(0.0);
|
||||
vec4 R1f = vec4(0.0);
|
||||
vec4 R2f = vec4(0.0);
|
||||
vec4 R3f = vec4(0.0);
|
||||
vec4 R4f = vec4(0.0);
|
||||
vec4 R123f = vec4(0.0);
|
||||
vec4 R126f = vec4(0.0);
|
||||
vec4 R127f = vec4(0.0);
|
||||
float backupReg0f, backupReg1f, backupReg2f, backupReg3f, backupReg4f;
|
||||
vec4 PV0f = vec4(0.0), PV1f = vec4(0.0);
|
||||
float PS0f = 0.0, PS1f = 0.0;
|
||||
vec4 tempf = vec4(0.0);
|
||||
float tempResultf;
|
||||
int tempResulti;
|
||||
ivec4 ARi = ivec4(0);
|
||||
bool predResult = true;
|
||||
vec3 cubeMapSTM;
|
||||
int cubeMapFaceId;
|
||||
R0f = passParameterSem0;
|
||||
R1f = passParameterSem1;
|
||||
R2f = passParameterSem2;
|
||||
R3f.xyzw = (texture(textureUnitPS0, R1f.xy).xyzw);
|
||||
R1f.xyzw = (texture(textureUnitPS0, R1f.zw).xyzw);
|
||||
R4f.xyzw = (texture(textureUnitPS0, R2f.xy).xyzw);
|
||||
R0f.x = (texture(textureUnitPS1, R0f.xy).x);
|
||||
R2f.xyzw = (texture(textureUnitPS0, R2f.zw).xyzw);
|
||||
// 0
|
||||
backupReg0f = R0f.x;
|
||||
PV0f.x = R3f.y + R1f.y;
|
||||
PV0f.x /= 2.0;
|
||||
PV0f.y = R3f.x + R1f.x;
|
||||
PV0f.y /= 2.0;
|
||||
PV0f.z = R3f.w + R1f.w;
|
||||
PV0f.z /= 2.0;
|
||||
PV0f.w = R3f.z + R1f.z;
|
||||
PV0f.w /= 2.0;
|
||||
R127f.w = (backupReg0f * intBitsToFloat(uf_remappedPS[0].z) + intBitsToFloat(uf_remappedPS[0].w));
|
||||
R127f.w = clamp(R127f.w, 0.0, 1.0);
|
||||
PS0f = R127f.w;
|
||||
// 1
|
||||
R123f.x = (R4f.y * 0.5 + PV0f.x);
|
||||
PV1f.x = R123f.x;
|
||||
R123f.y = (R4f.x * 0.5 + PV0f.y);
|
||||
PV1f.y = R123f.y;
|
||||
R123f.z = (R4f.w * 0.5 + PV0f.z);
|
||||
PV1f.z = R123f.z;
|
||||
R123f.w = (R4f.z * 0.5 + PV0f.w);
|
||||
PV1f.w = R123f.w;
|
||||
R127f.z = mul_nonIEEE(PS0f, intBitsToFloat(uf_remappedPS[1].z));
|
||||
PS1f = R127f.z;
|
||||
// 2
|
||||
R127f.x = (R2f.x * 0.5 + PV1f.y)/2.0;
|
||||
PV0f.x = R127f.x;
|
||||
R127f.y = (R2f.y * 0.5 + PV1f.x)/2.0;
|
||||
PV0f.y = R127f.y;
|
||||
R126f.z = (R2f.z * 0.5 + PV1f.w)/2.0;
|
||||
PV0f.z = R126f.z;
|
||||
R126f.w = (R2f.w * 0.5 + PV1f.z)/2.0;
|
||||
PV0f.w = R126f.w;
|
||||
// 3
|
||||
tempf.x = dot(vec4(PV0f.x,PV0f.y,PV0f.z,PV0f.w),vec4(intBitsToFloat(uf_remappedPS[2].x),intBitsToFloat(uf_remappedPS[2].y),intBitsToFloat(uf_remappedPS[2].z),intBitsToFloat(uf_remappedPS[2].w)));
|
||||
tempf.x = clamp(tempf.x, 0.0, 1.0);
|
||||
PV1f.x = tempf.x;
|
||||
PV1f.y = tempf.x;
|
||||
PV1f.z = tempf.x;
|
||||
PV1f.w = tempf.x;
|
||||
// 4
|
||||
R123f.y = (R127f.w * R127f.z + PV1f.x);
|
||||
PV0f.y = R123f.y;
|
||||
// 5
|
||||
PV1f.x = mul_nonIEEE(PV0f.y, intBitsToFloat(uf_remappedPS[3].z));
|
||||
// 6
|
||||
R2f.x = mul_nonIEEE(R127f.x, PV1f.x * bloomFactor);
|
||||
R2f.y = mul_nonIEEE(R127f.y, PV1f.x * bloomFactor);
|
||||
R2f.z = mul_nonIEEE(R126f.z, PV1f.x * bloomFactor);
|
||||
R2f.w = mul_nonIEEE(R126f.w, PV1f.x * bloomFactor);
|
||||
// export
|
||||
passPixelColor0 = vec4(R2f.x, R2f.y, R2f.z, R2f.w);
|
||||
}
|
26
src/MarioKart8/Enhancements/Bloom/rules.txt
Normal file
26
src/MarioKart8/Enhancements/Bloom/rules.txt
Normal file
|
@ -0,0 +1,26 @@
|
|||
[Definition]
|
||||
titleIds = 000500001010EC00,000500001010ED00,000500001010EB00
|
||||
name = Bloom Adjustment
|
||||
path = "Mario Kart 8/Enhancements/Bloom Adjustment"
|
||||
description = Allows you to adjust how strong the bloom is. Full amount is the default intensity of bloom.
|
||||
#Credits: M&&M
|
||||
version = 6
|
||||
|
||||
[Default]
|
||||
$bloom = 1.0
|
||||
|
||||
[Preset]
|
||||
name = Full Amount (Default)
|
||||
default = 1
|
||||
|
||||
[Preset]
|
||||
name = Half Amount
|
||||
$bloom = 0.5
|
||||
|
||||
[Preset]
|
||||
name = Quarter Amount
|
||||
$bloom = 0.25
|
||||
|
||||
[Preset]
|
||||
name = Disabled
|
||||
$bloom = 0.0
|
|
@ -1,6 +1,5 @@
|
|||
[MK8_AspectRatio_Shared]
|
||||
[MarioKart8_AspectRatio]
|
||||
moduleMatches = 0x9F0A90B7,0xD09700CE,0x1D398493,0xBA6B1E20,0x62A5F023,0x2A2DC82C
|
||||
|
||||
.origin = codecave
|
||||
|
||||
aspectRatio:
|
||||
|
@ -13,56 +12,38 @@ lfs f12, aspectRatio@l(r7)
|
|||
fmuls f7, f9, f12
|
||||
blr
|
||||
|
||||
|
||||
[MK8_AspectRatio_V42]
|
||||
moduleMatches = 0x9F0A90B7
|
||||
|
||||
[MarioKart8_AspectRatio_v42]
|
||||
moduleMatches = 0x9F0A90B7 ; v4.2(EU/NA/JP)
|
||||
0x024AEF70 = bla scaleAspectRatioCalc
|
||||
|
||||
0x100C359C = .float ($width/$height)
|
||||
0x10121E30 = .float ($width/$height)
|
||||
|
||||
|
||||
[MK8_AspectRatio_V41]
|
||||
moduleMatches = 0xD09700CE
|
||||
|
||||
[MarioKart8_AspectRatio_v41]
|
||||
moduleMatches = 0xD09700CE ; v4.1(EU/NA/JP)
|
||||
0x024AEBEC = bla scaleAspectRatioCalc
|
||||
|
||||
0x100C359C = .float ($width/$height)
|
||||
0x10121E30 = .float ($width/$height)
|
||||
|
||||
|
||||
[MK8_AspectRatio_V4]
|
||||
moduleMatches = 0x1D398493
|
||||
|
||||
[MarioKart8_AspectRatio_v4]
|
||||
moduleMatches = 0x1D398493 ; v4.0(EU/NA/JP)
|
||||
0x024AEBEC = bla scaleAspectRatioCalc
|
||||
|
||||
0x100C359C = .float ($width/$height)
|
||||
0x10121D30 = .float ($width/$height)
|
||||
|
||||
|
||||
[MK8_AspectRatio_V3]
|
||||
moduleMatches = 0xBA6B1E20
|
||||
|
||||
[MarioKart8_AspectRatio_v3]
|
||||
moduleMatches = 0xBA6B1E20 ; v3.0(EU/NA/JP)
|
||||
0x024642E8 = bla scaleAspectRatioCalc
|
||||
|
||||
0x100AC25C = .float ($width/$height)
|
||||
0x1010A730 = .float ($width/$height)
|
||||
|
||||
|
||||
[MK8_AspectRatio_V2]
|
||||
moduleMatches = 0x62A5F023
|
||||
|
||||
[MarioKart8_AspectRatio_v2]
|
||||
moduleMatches = 0x62A5F023 ; v2.0(EU/NA/JP)
|
||||
0x024376D4 = bla scaleAspectRatioCalc
|
||||
|
||||
0x1009E9DC = .float ($width/$height)
|
||||
0x100FC030 = .float ($width/$height)
|
||||
|
||||
|
||||
[MK8_AspectRatio_V1]
|
||||
moduleMatches = 0x2A2DC82C
|
||||
|
||||
[MarioKart8_AspectRatio_v1]
|
||||
moduleMatches = 0x2A2DC82C ; v1.0(EU/NA/JP)
|
||||
0x02416760 = bla scaleAspectRatioCalc
|
||||
|
||||
0x10097D94 = .float ($width/$height)
|
||||
0x100F3430 = .float ($width/$height)
|
||||
|
|
|
@ -1,10 +1,11 @@
|
|||
[MK8_DisableFXAA_V42]
|
||||
moduleMatches = 0x9F0A90B7
|
||||
|
||||
[MarioKart8_DisableFXAA_v42]
|
||||
moduleMatches = 0x9F0A90B7 ; v4.2(EU/NA/JP)
|
||||
0x027DF528 = blr
|
||||
|
||||
|
||||
[MK8_DisableFXAA_V41]
|
||||
moduleMatches = 0xD09700CE
|
||||
|
||||
[MarioKart8_DisableFXAA_v41]
|
||||
moduleMatches = 0xD09700CE ; v4.1(EU/NA/JP)
|
||||
0x027DF2F4 = blr
|
||||
|
||||
[MarioKart8_DisableFXAA_v1]
|
||||
moduleMatches = 0x2A2DC82C ; v1.0(EU/NA/JP)
|
||||
0x0271DE0C = blr
|
||||
|
|
|
@ -1,4 +1,7 @@
|
|||
[MK8_LevelOfDetail_V42_V41]
|
||||
moduleMatches = 0x9F0A90B7,0xD09700CE
|
||||
[MarioKart8_LevelOfDetail_v42_v41]
|
||||
moduleMatches = 0x9F0A90B7, 0xD09700CE ; v4.2(EU/NA/JP), v4.1(EU/NA/JP)
|
||||
0x10121DF0 = .float $levelOfDetail
|
||||
|
||||
0x10121DF0 = .float $levelOfDetail
|
||||
[MarioKart8_LevelOfDetail_v1]
|
||||
moduleMatches = 0x2A2DC82C ; v1.0(EU/NA/JP)
|
||||
0x100F33F0 = .float $levelOfDetail
|
||||
|
|
|
@ -1,10 +1,11 @@
|
|||
[MK8_60FPSFullDraw_V42]
|
||||
moduleMatches = 0x9F0A90B7
|
||||
|
||||
[MarioKart8_60FPSFullDraw_v42]
|
||||
moduleMatches = 0x9F0A90B7 ; v4.2(EU/NA/JP)
|
||||
0x024AF384 = b .+0x54
|
||||
|
||||
|
||||
[MK8_60FPSFullDraw_V41]
|
||||
moduleMatches = 0xD09700CE
|
||||
|
||||
[MarioKart8_60FPSFullDraw_v41]
|
||||
moduleMatches = 0xD09700CE ; v4.1(EU/NA/JP)
|
||||
0x024AF000 = b .+0x54
|
||||
|
||||
[MarioKart8_60FPSFullDraw_v1]
|
||||
moduleMatches = 0x2A2DC82C ; v1.0(EU/NA/JP)
|
||||
0x02416B74 = b .+0x54
|
||||
|
|
Loading…
Add table
Reference in a new issue