Jump to content

Question

12 answers to this question

Recommended Posts

  • 0
Posted
  On 8/15/2023 at 6:40 PM, MAARS said:

Nice, but your request still lack context, what are you trying to do ?

Expand  

i just want opcode high value for speed

  On 8/16/2023 at 4:19 AM, AMIYA said:

Have you tried it?

 

Like this ?

 

X1, x2

 

 X0, x1
 

Expand  

you get stuck when you use that, only fmov

  • 0
Posted

[ @KabutHitam ]
---

  Quote

i just want opcode high value for speed

Expand  

From what I understand, you're trying to set a large possible value. You can use this template:
---
[ Float 0-65535 ]

MOVW R0, #(1-65535)
VMOV SO, R0
VCVT.F32.S32 S0, S0
VMOV R0, S0
BX LR

---
[ Float 65535 - 131072 ]: R0 = R0 + R1

MOVW R0, #(0-65535)
MOVW R1, #(0-65535)
ADD R0, R0, R1
VMOV SO, R0
VCVT.F32.S32 SO, S0
VMOV RO, SO
BX LR

---
[ Float 131072 - 429503284]: R0 = (R0 x R1) + R1

MOVW R0, #(0-65535)
MOVW R1, #(0-65535) --multiply here
MUL R0, R0, R1
MOVW R1, #(0-65535) --addition here
ADD R0, R0, R1
VMOV S0, R0
VCVT.F32.S32 S0, S0
VMOV R0, S0
BX LR

---
*Above mnemonic are replicable for getting a really high value.
*Do note that most function has it's own Max Limit, so you need to change them first (example: MaxHP & MinHP)
*( credit: @BadCase )

  • 0
Posted
  On 8/16/2023 at 7:50 PM, Xaviesz said:

[ @KabutHitam ]
---

From what I understand, you're trying to set a large possible value. You can use this template:
---
[ Float 0-65535 ]

MOVW R0, #(1-65535)
VMOV SO, R0
VCVT.F32.S32 S0, S0
VMOV R0, S0
BX LR

---
[ Float 65535 - 131072 ]: R0 = R0 + R1

MOVW R0, #(0-65535)
MOVW R1, #(0-65535)
ADD R0, R0, R1
VMOV SO, R0
VCVT.F32.S32 SO, S0
VMOV RO, SO
BX LR

---
[ Float 131072 - 429503284]: R0 = (R0 x R1) + R1

MOVW R0, #(0-65535)
MOVW R1, #(0-65535) --multiply here
MUL R0, R0, R1
MOVW R1, #(0-65535) --addition here
ADD R0, R0, R1
VMOV S0, R0
VCVT.F32.S32 S0, S0
VMOV R0, S0
BX LR

---
*Above mnemonic are replicable for getting a really high value.
*Do note that most function has it's own Max Limit, so you need to change them first (example: MaxHP & MinHP)
*( credit: @BadCase )

Expand  

How to use GameGuardian to modify so many assembly codes?

  • 0
Posted (edited)

[ @huanggua ]
---

  Quote

How to use GameGuardian to modify so many assembly codes?

Expand  

Make sure that you're know the difference between Arm and Thumb. The difference between both is that: Arm uses 4 hexes / 8 bytes, meaningwhile, Thumb usually uses only 2 hexes / 4 bytes. For example:

  Quote

Assembly: NOP
Arm: 00 F0 20 E3
Thumb: 00 BF

Expand  

---
It is important because you can only change one instruction with another one WITH the same hex length. You can replace the next instruction to fit your long-patches, but make sure that: if it's a function, you need to ends it with:

Arm32: BX LR
Arm64: RET

---

Edited by Xaviesz
  • 0
Posted
  On 8/17/2023 at 6:05 PM, Xaviesz said:

[ @huanggua ]
---

Make sure that you're know the difference between Arm and Thumb. The difference between both is that: Arm uses 4 hexes / 8 bytes, meaningwhile, Thumb usually uses only 2 hexes / 4 bytes. For example:

---
It is important because you can only change one instruction with another one WITH the same hex length. You can replace the next instruction to fit your long-patches, but make sure that: if it's a function, you need to ends it with:

Arm32: BX LR
Arm64: RET

---

Expand  

Do you mean that, for example, after I find the address of the MAXHP function, I can use GameGuardian to modify this value and some subsequent values to MOVW R0, #(1-65535)

VMOV SO, R0

VCVT.F32.S32 S0, S0

VMOV R0, S0

BX LR ?

Maybe I didn't express myself clearly, see if you can understand now.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.