Skip to content
Guest Big Announcement

How can I add slider For Gravity & speed

Featured Replies

Hi all I made Gravity hack but I want to make slider For Gravity

i know how to make basic switch but I want to make Slider to anyone wants to change it in Shmoo ModMenu

 

this is Gravity function 

__text:00000001008D9E28                 SUB             SP, SP, #0x20
__text:00000001008D9E2C                 STP             X29, X30, [SP,#0x10+var_s0]
__text:00000001008D9E30                 ADD             X29, SP, #0x10
__text:00000001008D9E34                 STR             WZR, [SP,#0x10+var_8]
__text:00000001008D9E38                 STR             XZR, [SP,#0x10+var_10]
__text:00000001008D9E3C                 MOV             X1, SP
__text:00000001008D9E40                 BL              Physics$$INTERNAL_get_gravity
__text:00000001008D9E44                 LDP             S0, S1, [SP,#0x10+var_10]
__text:00000001008D9E48                 LDR             S2, [SP,#0x10+var_8]
__text:00000001008D9E4C                 LDP             X29, X30, [SP,#0x10+var_s0]
__text:00000001008D9E50                 ADD             SP, SP, #0x20
__text:00000001008D9E54                 RET
__text:00000001008D9E54 ; End of function Physics$$get_gravity

 

 

 

 

 

 

How can I but them in : 

   Hide contents

To add a hook with a slider, use this function:

addSliderHook(@"Hook name", @"Description of the hook", font, lower bound for slider, upper bound for slider, function address, the name of the function you are using for the hook, the name of the function that you aren't using for the hook);

Use this line of code to retrieve the slider's value:

float val = [SliderHook getSliderValueForHook:@"hook name here"];

Let's say I wanted to make a hook with a slider that enabled the user to choose their FOV from 60 to 150. I would use this code:

	float (*getFovOrig)(void *_this);
	 
	float _getFovHooked(void *_this){
	return [SliderHook getSliderValueForHook:@"Field of view slider"];
	}
	 
	addSliderHook(@"Field of view slider", @"Use this slider to adjust your FOV from 60 to 150.", font, 60, 150, 0xc392da, (void *)_getFovHooked, (void *)getFovOrig);

 

 

Create an account or sign in to comment

Featured Content

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.