Jump to content
  • 0

R > @savealoot and @loadaloot command


Question

2 answers to this question

Recommended Posts

  • 0
Posted (edited)
On 10/9/2018 at 6:45 PM, Quesooo said:

As the tittle said 

 

can i request a savealoot and loadaloot command 

 

thank you masters

Only for allotid not include @autoloot like before

so call @save to input all item you want to save

and then load it using @load

-	script	AutoSetting	-1,{
	end;	
	
OnLoadcommand:
		if (auto_settings & 1 << 0) atcommand "@alootid +"+auto_settings_alid_1;
		if (auto_settings & 1 << 0) atcommand "@alootid +"+auto_settings_alid_2;
		if (auto_settings & 1 << 0) atcommand "@alootid +"+auto_settings_alid_3;
		end;

	
OnSavecommand:
	while(1) {
		switch(
			select(
				"@alootid "+auto_settings_alid_1+" "+auto_settings_alid_2+" "+auto_settings_alid_3+" ["+((auto_settings & 1 << 1) ?"^00C000ON^000000":"^FF0000OFF^000000")+"]"
			)
		)
		{
			case 1:
				if (auto_settings & 1 << 0) {
					auto_settings_alid_1 = 0;
					auto_settings_alid_2 = 0;
					auto_settings_alid_3 = 0;
					auto_settings = auto_settings^1 << 0;
				} else {
					mes "Input Item ID #1";
					input .@itemid1;
					mes "Input Item ID #2";
					input .@itemid2;
					mes "Input Item ID #3";
					input .@itemid3;
					next;
					mes $cf$;
					mes "^808000==================================^000000";
					mes "Item ID #1 ^0000FF"+getitemname(.@itemid1)+"^000000 ("+.@itemid1+")";
					mes "Item ID #2 ^0000FF"+getitemname(.@itemid2)+"^000000 ("+.@itemid2+")";
					mes "Item ID #3 ^0000FF"+getitemname(.@itemid3)+"^000000 ("+.@itemid3+")";
					mes "^808000==================================^000000";
					next;
					if (select("Cancel","Ok") == 1) close;
						auto_settings_alid_1 = .@itemid1;
						auto_settings_alid_2 = .@itemid2;
						auto_settings_alid_3 = .@itemid3;
						auto_settings = auto_settings|1 << 0;
				}
				break;
		}
	}
	end;
		
OnInit:
	bindatcmd("save",strnpcinfo(0)+"::OnSavecommand",0,99);
	bindatcmd("load",strnpcinfo(0)+"::OnLoadcommand",0,99);
	end;
}

 

Edited by hendra814
  • Love 1

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...