Right clicking items causes them to not decrease. Simply put, infinite items.
{ Game : Terraria.exe
Version:
Date : 2022-09-29
Author : Iscariot
This script does blah blah blah
}
[ENABLE]
aobscan(rclick,FF 89 B4 00 00 00 8B 45 F0) // should be unique
alloc(newmem,$1000)
label(code)
label(return)
newmem:
code:
//dec [ecx+000000B4]
jmp return
rclick:
jmp newmem
nop
return:
registersymbol(rclick)
[DISABLE]
rclick:
db FF 89 B4 00 00 00
unregistersymbol(rclick)
dealloc(newmem)
{
// ORIGINAL CODE - INJECTION POINT: Terraria.UI.ItemSlot::PickupItemIntoMouse+F7
Terraria.UI.ItemSlot::PickupItemIntoMouse+D1: 53 - push ebx
Terraria.UI.ItemSlot::PickupItemIntoMouse+D2: E8 71 CD FF FF - call Terraria.UI.ItemSlot::AnnounceTransfer
Terraria.UI.ItemSlot::PickupItemIntoMouse+D7: A1 00 5D AD 06 - mov eax,[06AD5D00]
Terraria.UI.ItemSlot::PickupItemIntoMouse+DC: FF 80 B4 00 00 00 - inc [eax+000000B4]
Terraria.UI.ItemSlot::PickupItemIntoMouse+E2: 83 FE 1D - cmp esi,1D
Terraria.UI.ItemSlot::PickupItemIntoMouse+E5: 74 16 - je Terraria.UI.ItemSlot::PickupItemIntoMouse+FD
Terraria.UI.ItemSlot::PickupItemIntoMouse+E7: 8B 45 F0 - mov eax,[ebp-10]
Terraria.UI.ItemSlot::PickupItemIntoMouse+EA: 3B 78 04 - cmp edi,[eax+04]
Terraria.UI.ItemSlot::PickupItemIntoMouse+ED: 0F 83 11 02 00 00 - jae Terraria.UI.ItemSlot::PickupItemIntoMouse+304
Terraria.UI.ItemSlot::PickupItemIntoMouse+F3: 8B 4C B8 08 - mov ecx,[eax+edi*4+08]
// ---------- INJECTING HERE ----------
Terraria.UI.ItemSlot::PickupItemIntoMouse+F7: FF 89 B4 00 00 00 - dec [ecx+000000B4]
// ---------- DONE INJECTING ----------
Terraria.UI.ItemSlot::PickupItemIntoMouse+FD: 8B 45 F0 - mov eax,[ebp-10]
Terraria.UI.ItemSlot::PickupItemIntoMouse+100: 3B 78 04 - cmp edi,[eax+04]
Terraria.UI.ItemSlot::PickupItemIntoMouse+103: 0F 83 FB 01 00 00 - jae Terraria.UI.ItemSlot::PickupItemIntoMouse+304
Terraria.UI.ItemSlot::PickupItemIntoMouse+109: 8B 4C B8 08 - mov ecx,[eax+edi*4+08]
Terraria.UI.ItemSlot::PickupItemIntoMouse+10D: 83 B9 B4 00 00 00 00 - cmp dword ptr [ecx+000000B4],00
Terraria.UI.ItemSlot::PickupItemIntoMouse+114: 7F 1E - jg Terraria.UI.ItemSlot::PickupItemIntoMouse+134
Terraria.UI.ItemSlot::PickupItemIntoMouse+116: B9 78 36 5D 08 - mov ecx,085D3678
Terraria.UI.ItemSlot::PickupItemIntoMouse+11B: E8 88 B8 C6 F4 - call 046530C8
Terraria.UI.ItemSlot::PickupItemIntoMouse+120: 8B D8 - mov ebx,eax
Terraria.UI.ItemSlot::PickupItemIntoMouse+122: 8B CB - mov ecx,ebx
}
HP wont decrease. Lava and other DoT effects may still cause damage. Didnt test it.
{ Game : Terraria.exe
Version:
Date : 2022-09-29
Author : Iscariot
This script does blah blah blah
}
[ENABLE]
aobscan(playerhp,29 82 04 04 00 00) // should be unique
alloc(newmem,$1000)
label(code)
label(return)
newmem:
code:
//sub [edx+00000404],eax
jmp return
playerhp:
jmp newmem
nop
return:
registersymbol(playerhp)
[DISABLE]
playerhp:
db 29 82 04 04 00 00
unregistersymbol(playerhp)
dealloc(newmem)
{
// ORIGINAL CODE - INJECTION POINT: Terraria.Player::Hurt+11E9
Terraria.Player::Hurt+11BF: 0F B6 45 10 - movzx eax,byte ptr [ebp+10]
Terraria.Player::Hurt+11C3: 50 - push eax
Terraria.Player::Hurt+11C4: 6A 00 - push 00
Terraria.Player::Hurt+11C6: F2 0F 10 45 DC - movsd xmm0,[ebp-24]
Terraria.Player::Hurt+11CB: F2 0F 2C D0 - cvttsd2si edx,xmm0
Terraria.Player::Hurt+11CF: 8B 8D 44 FF FF FF - mov ecx,[ebp-000000BC]
Terraria.Player::Hurt+11D5: E8 0E 00 49 1D - call Terraria.CombatText::NewText
Terraria.Player::Hurt+11DA: F2 0F 10 45 DC - movsd xmm0,[ebp-24]
Terraria.Player::Hurt+11DF: F2 0F 2C C0 - cvttsd2si eax,xmm0
Terraria.Player::Hurt+11E3: 8B 95 9C FD FF FF - mov edx,[ebp-00000264]
// ---------- INJECTING HERE ----------
Terraria.Player::Hurt+11E9: 29 82 04 04 00 00 - sub [edx+00000404],eax
// ---------- DONE INJECTING ----------
Terraria.Player::Hurt+11EF: 83 7D 0C FF - cmp dword ptr [ebp+0C],-01
Terraria.Player::Hurt+11F3: 0F 85 A2 00 00 00 - jne Terraria.Player::Hurt+129B
Terraria.Player::Hurt+11F9: 8B 85 9C FD FF FF - mov eax,[ebp-00000264]
Terraria.Player::Hurt+11FF: C6 80 ED 06 00 00 01 - mov byte ptr [eax+000006ED],01
Terraria.Player::Hurt+1206: 33 D2 - xor edx,edx
Terraria.Player::Hurt+1208: 89 55 8C - mov [ebp-74],edx
Terraria.Player::Hurt+120B: 0F B6 45 18 - movzx eax,byte ptr [ebp+18]
Terraria.Player::Hurt+120F: 85 C0 - test eax,eax
Terraria.Player::Hurt+1211: 74 09 - je Terraria.Player::Hurt+121C
Terraria.Player::Hurt+1213: C7 45 8C 08 00 00 00 - mov [ebp-74],00000008
}
Only things I'm interested in so I'm sharing.