Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <natives.h>
- #include <common.h>
- #include <strings.h>
- #include <types.h>
- #include <consts.h>
- bool StringChecker(char *Line, char *SafeLine, int Length, uint Hash)
- {
- int SafeLength;
- uint StringHash;
- SafeLength = GET_LENGTH_OF_LITERAL_STRING(Line);
- StringHash = GET_HASH_KEY(Line);
- if(!COMPARE_STRING(Line, SafeLine)) return false;
- if(SafeLength != Length) return false;
- if(StringHash != Hash) return false;
- return true;
- }
- /*bool StringChecker(char *Line, char *SafeLine, int Length, uint Hash)
- {
- int SafeLength;
- uint StringHash;
- SafeLength = GET_LENGTH_OF_LITERAL_STRING(Line);
- StringHash = GET_HASH_KEY(Line);
- if(!COMPARE_STRING(Line, SafeLine)) return false;
- if(SafeLength != Length) return false;
- if(StringHash != Hash) return false;
- return true;
- }
- void string_check(void)
- {
- if(StringChecker("Toofaces2 Private", modmanager_header, 23, 863453295) && (StringChecker(Line, modmanager_subheader, 49, 827635247)) // Remember return true; on every line
- {
- print("String is fine");
- }
- else
- {
- float x,y,z;
- print("~r~Strings Edited. File Terminating.");
- // Below is just to add insult to injury, add or subtract as you please
- WAIT(1000);
- GET_CHAR_COORDINATES(GetPlayerPed(), &x, &y, &z);
- SET_CHAR_VISIBLE(GetPlayerPed(), 0);
- ADD_EXPLOSION(x, y, z, EXPLOSION_SHIP_DESTROY, 50.0f, true, true, 0.0f);
- SET_PLAYER_CONTROL(GetPlayerPed(), false);
- SET_CHAR_HEALTH(GetPlayerPed(), 0);
- FORCE_LOADING_SCREEN(true);
- print("~r~LOL!");
- TERMINATE_THIS_SCRIPT();
- }
- /*if(StringChecker(Line, modmanager_subheader, 49, 827635247)) return true;
- if(StringChecker(Line, modmanager_footer, 20, 829003475)) return true;
- if(StringChecker(Line, protection, 37, 922876274)) return true;
- if(StringChecker(Line, mod_menus, 28, 1003150641)) return true;
- if(StringChecker(Line, quick_weapons, 37, 1070466459)) return true;
- if(StringChecker(Line, quick_handling, 38, 928753672)) return true;
- if(StringChecker(Line, quick_fun, 33, 920863472)) return true;
- if(StringChecker(Line, mapmod_loader, 32, 829877563)) return true;
- if(StringChecker(Line, game_modes, 41, 9209987635)) return true;
- if(StringChecker(Line, dev Tools, 30, 922873452)) return true;
- if(StringChecker(Line, premium Menu, 45, 938762536)) return true;
- // return false; // Remember return false; after all protected strings
- } */
Advertisement
Add Comment
Please, Sign In to add comment