Tutorial [Tutorial] Unity mod menu automatic scale according to Screen

IZeuz

Just Crazy
Original poster
Aug 18, 2017
352
85
28
24
Germany
This is a simple way to made your mod menu scale according on the user phone screen size.

Request:
-know c#
-know Unity
-brain.

This tutorial are based for who make mod menu with their own Class

1)

When start make your class, add a variable to define native size of screen:
C#:
public class kkwModMenu : MonoBehaviour {


    //declare native size of screen

    Vector2 nativeSize = new Vector2(1024, 768);

2)

in the function OnGUI add this code(explication are in the code comment)
C#:
void OnGUI()  
    {
        //get scale value
        Vector3 scale = new Vector3 (Screen.width / nativeSize.x, Screen.height / nativeSize.y, 1.0f);
     
        //and apply the scale to all gui scripted here
        GUI.matrix = Matrix4x4.TRS (new Vector3(0, 0, 0), Quaternion.identity, scale);
        // write your own code
        if (GUI.Button(new Rect(20, 20, 160, 20), "Scaled"))
        {
            //your code
        }
    }
this is the most simply way i find to make mod menu aviable and at correct size for most device.

i hope this help you.
 
Thread starter Similar threads Forum Replies Date
moonbunny Tutorial LIST OF ALL PLATINMODS MODDING TUTORIALS TUTORIALS 16
P Tutorial PLATINMODS [HOW TO MAKE MOD MENU] MENU MAKER FOR UNITY GAMES V1.0 PUBLIC-VERSION TUTORIALS 143
G-Bo ッ Tutorial Modding Unity & Its Dll's: Starter Pack + Tutorial TUTORIALS 1
P Tutorial How to Decompile, Compile, and Sign APKs without APK Easy Tool TUTORIALS 7
AndnixSH Tutorial Unity tutorial - Making value adder hack for offline games TUTORIALS 4
ZPictYT Tutorial [Tutorial] How To Dumping Il2cpp Protected File TUTORIALS 12
GNaFF Outdated Tiny Archers Ver. 1.35.05.0 MOD APK | Tutorial Remove | ADS Remove Outdated PMT Android MODs 6
dingdingdong Tutorial A Basic "License-Like" Tutorial For Native Mod (Android Studio) TUTORIALS 9
Qnzboi102 Tutorial [CSR Racing 2 (iOS ONLY) All Versions] Unban Tutorial CSR 2 On A New Profile TUTORIALS 44
AndnixSH Tutorial [Archive] Android Application Reversing Via Android Mobile PDF TUTORIALS 0
A Tutorial CSR2 Modding Tutorial - Get any car you want! 2.3.1 (IOS/ANDROID) TUTORIALS 12
BMD4E Tutorial MessyBinary Android Tutorials TUTORIALS 2
BMD4E Tutorial [GameGuardian tutorial] First Fishing Damage hack TUTORIALS 0
G-Bo ッ How to install Apple MODs / Cheats for iOS Devices without Jailbreak EXCLUSIVE iOS MODS BY iPMT 0
G-Bo ッ How to install Apple MODs / Cheats for iOS Devices with Jailbreak EXCLUSIVE iOS MODS BY iPMT 0
AndnixSH Tutorial IDA tutorial - Bypassing fake update warning TUTORIALS 1
AndnixSH Tutorial [IDA tutorial] How to mod x86 lib .so file (Updated) TUTORIALS 8
AndnixSH Tutorial How to use GameGuardian without root in Virtual space app (with video tutorials) TUTORIALS 5
Alex Zander Tutorial Android FAQ - Frequently Asked Questions! TUTORIALS 4
G-Bo ッ Tutorial BASICS ABOUT ANDROID APK MODDING IN GENERAL | LEARN MODDING TODAY FOR FREE! TUTORIALS 55
Alex Zander Tutorial [IDA Tutorial]How to deal with/hack vectors TUTORIALS 0
Alex Zander Tutorial How To Hack Using IDA #2 TUTORIALS 1
Alex Zander Tutorial IDA Hacking Tutorial #1 TUTORIALS 4
Alex Zander Tutorial How To Hack Using IDA (Mega Tutorial) TUTORIALS 0
G0DYAT0 Tutorial [G0D] Lucky Patcher - Install & Example Tutorial TUTORIALS 3
MrDeso™ Tutorial Android How to Mod Momo Pop Crack Assembly-CSharp Tutorial 2017 TUTORIALS 3
Mika Cybertron Tutorial [Video Tutorial] Ida String Hack TUTORIALS 2
Mika Cybertron Tutorial PMT Team - [Modding-Videotutorial] How To Mod Games TUTORIALS 120
G-Bo ッ Tutorial How to change location for Google Play to unlock country locked games [no root] TUTORIALS 5
G-Bo ッ Why you should root + patch your device? FORUM BASICS & NEWS 0
G-Bo ッ Tutorial [Videotutorial] Very nice Beginners Guide for IDA Modding on Android Games TUTORIALS 13
G-Bo ッ How to sign up and download on www.platinmods.com FORUM BASICS & NEWS 0
G-Bo ッ Tutorial [Videotutorial] How to do the OBB Trick (no root) | OBB Installation Guide EXCLUSIVE ANDROID MODS BY PMT 0
Mika Cybertron Tutorial [VideoTutorial] How To Hack Criminal Case Part #1 TUTORIALS 3
Mika Cybertron Tutorial IDA PRO BASIC (INSTRUCTION OF IDA ) TUTORIALS 6
G-Bo ッ Tutorial Make your own Clash of Clans Private Server! [TUTORIAL]. TUTORIALS 9
G-Bo ッ [Videotutorial] How To Login With Google+ Or Facebook App On Modded Games EXCLUSIVE ANDROID MODS BY PMT 0
G-Bo ッ Tutorial [Videotutorial] How To Install OBB Files On Modded Games (root) EXCLUSIVE ANDROID MODS BY PMT 0
G-Bo ッ [Videotutorial] How To Download With DropAPK Upload-Service FORUM BASICS & NEWS 0
AndnixSH Tutorial Unity mono stuff for Android TUTORIALS 0
AndnixSH Tutorial Create Unity mod menu instance without active class (DLL/Mono backend only) TUTORIALS 1
AndnixSH Modding Tools Unity Assets Bundle Extractor Tools 0
Chewy Tutorial [iOS] How to Hack Simple Unity Games TUTORIALS 38
AndnixSH Tutorial [Source Code] Get Unity Version C# TUTORIALS 0
G OA [Shared] Tales Of Unity [18+] v0.1 MOD APK Age Restricted Games 3
AndnixSH Tutorial Unity camera modding TUTORIALS 8
AndnixSH Tutorial Manually dump il2cpp unity 2019.x.x on Android games TUTORIALS 22
TheArmKing Tutorial Find Unity version of a game for dumping TUTORIALS 5
Mr Ikso Tutorial MOD Menu for il2cpp and native Android Games TUTORIALS 144
AndnixSH Tutorial How to get unity version from any asset file TUTORIALS 6
Similar threads


















































About us

  • Welcome to platinmods.com! We are proud to present you the place which let's dreams come true! Focusing on quality and trust we have spend much time to build a gaming community fitting to your wishes and needs. Actually we offer you the finest MODs and Games of the Android section and we slowly expand to the iOS section as well. But games, Android MODs & iOS MODs are not the only things we can offer you. We have tutorials, tools, a very friendly, active and solid community which will help you with any problem you have =) Your happiness is our goal. We hope you enjoy!

Forum statistics

Threads
27,766
Messages
465,174
Members
1,035,018
Latest member
kuguragamon