Autoload Scripts Tutorial

  • Hello Guest! Welcome to ConsoleCrunch, to help support our site check out the premium upgrades HERE! to get exclusive access to our hidden content.
  • Unable to load portions of the website...
    If you use an ad blocker addon, you should disable it because it interferes with several elements of the site and blocks more than just adverts.
  • Read Rules Before Posting Post Virus Scans with every program.

SwizzyPlays

Active Poster
CC Dev Team
Active Member
Sep 16, 2015
350
268
123
Hello guys here is a quick tut on how to make "Mod Settings" or auto loads for your menu! A couple days ago I couldn't figure out how to do but I eventually figured it out!

AUTO LOADS SCO'S TUTORIAL
This is a simple auto loader that you could perfect if you wanted! I am not that good at coding lol so this was useful to me!

How to set the autoload function
void godmodescript(void)
{
if (GET_NUMBER_OF_INSTANCES_OF_STREAMED_SCRIPT("godmode_uclip") == 0)
{
REQUEST_SCRIPT("godmode_uclip");
//name of sco. Example used here: godmode_uclip
while (!HAS_SCRIPT_LOADED("godmode_uclip"))
WAIT(0);

START_NEW_SCRIPT("godmode_uclip", 1024);
MARK_SCRIPT_AS_NO_LONGER_NEEDED("godmode_uclip");
}
}

Where to call the function(main)
void main(void)
{

protections_load();
godmodescript();
//Where the function is called, I have other set as above & below!
NETWORK_GHOST();
loadmod();
menu_core_startup();
draw_startup();
disablemenuinpause();

while(true)
{
WAIT(0);

if (!IS_STRING_NULL(load_script) && !script_loaded)
load_script_prioritized();

// Core menu function (Catch button press. Set menu).
if (IS_STRING_NULL(load_script))
menu_core();

// Draw background/header/text.
drawWindow();
//drawwindow2();

// Draw button input.
drawFrontend();

drawHeader();
//drawHeader2();
//drawFoot();
//drawFoot2();
menu_draw();

DESTROY_MOBILE_PHONE();

TERMINATE_ALL_SCRIPTS_WITH_THIS_NAME("disablemenu");
HIDE_HELP_TEXT_THIS_FRAME();
HIDE_HUD_AND_RADAR_THIS_FRAME();
}
}



Hope this helped someone! One thing that this does cause is that everytime you open your menu up the sco's reload. Other than that its good!
 
  • Like
Reactions: Devilsdesign
General chit-chat
Help Users
  • No one is chatting at the moment.
  • @ QM|T:
    you going to use it
  • @ lurch6661:
    when i find it ill send it
  • @ lurch6661:
    i dont have 9.00
  • @ QM|T:
    :xD: me either hahaha
  • @ lurch6661:
    lol
  • @ QM|T:
    lol
  • @ lurch6661:
    man i got some white widow
  • @ QM|T:
    nice
  • @ lurch6661:
    its a sativa though
  • @ QM|T:
    it is what it is right haha
  • @ lurch6661:
    i actually have been making thc chocolate
  • @ lurch6661:
    lol yup
  • @ QM|T:
    haha ok
  • @ lurch6661:
    so what kinda soundbar did u get
  • @ lurch6661:
    i just pawned one for 2 00 bucks
  • @ QM|T:
    thi one is from LG wireless it was 250 euros
  • @ QM|T:
    this
  • Chat Bot:
    rr88comse4 is our newest member. Welcome!
  • @ lurch6661:
    blast this
  • @ QM|T:
    nice
  • @ QM|T:
    but i have to go im going to my moms house
  • @ QM|T:
    ck later on tho
  • @ lurch6661:
    ok bro tc
  • @ QM|T:
    tc bro
      @ QM|T: tc bro