Jump to content
  • 0

Free Potions Once a Day


GeorgeBrian

Question


  • Group:  Members
  • Topic Count:  3
  • Topics Per Day:  0.00
  • Content Count:  10
  • Reputation:   0
  • Joined:  08/02/19
  • Last Seen:  

Hi, can anybody make it receivable once a day per user account (not per character)?

And also if he already has more than 250 in his inventory, the NPC will refuse the giveaway.

izlude,144,121,3    script    JohnDoe NPC::JohnDoe    1_M_MERCHANT,{
    mes "[JohnDoe]";
    mes "Do you need some Novice Potions?";
    menu "Yes, please.",receive,"I don't need them for now, thank you.",refuse;
    close;

receive:
    mes "Here, take these.";
    getitem 569,250;
    next;
    mes "Good luck!.";
    close;
    end;

refuse:
    mes "Okay, good luck!";
    close;
}

 

Thanks a bunch!

PS: Sorry for  keep asking noob/stupid stuff.

Link to comment
Share on other sites

5 answers to this question

Recommended Posts

  • 0

  • Group:  Content Moderator
  • Topic Count:  55
  • Topics Per Day:  0.02
  • Content Count:  1676
  • Reputation:   703
  • Joined:  12/21/14
  • Last Seen:  

izlude,144,121,3	script	JohnDoe NPC::JohnDoe	1_M_MERCHANT,{
	mes "[JohnDoe]";
	mes "Do you need some Novice Potions?";
	switch(select("Yes, please.:I don't need them for now, thank you.")){
		clear;
		case 1:
			.@TIME$ = "" + gettime(DT_YYYYMMDD);
			if(#JOHNDOE_DAILY$ == .@TIME$){
				mes "you already got the Novice Potions for today";
				mes "try again in the next day";
				end;
			}
			mes "Here, take these.";
			getitem 569,250;
			#JOHNDOE_DAILY$ = .@TIME$;
			mes "Good luck!.";
			end;
		case 2:
			mes "Okay, good luck!";
			end;
	}
}

 

Edited by sader1992
miss <tabs>
  • Upvote 1
  • Love 1
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  23
  • Topics Per Day:  0.01
  • Content Count:  183
  • Reputation:   15
  • Joined:  06/10/12
  • Last Seen:  

create a variable called #VARIABLE
eg:
 

#accbound

 

  • Like 1
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  3
  • Topics Per Day:  0.00
  • Content Count:  10
  • Reputation:   0
  • Joined:  08/02/19
  • Last Seen:  

On 8/11/2019 at 7:48 PM, HD Scripts said:

create a variable called #VARIABLE
eg:


#accbound

 

Hi, thank you for answering.

Yes, but I don't know where and how to put it correctly.

If you don't mind, can you edit my script above and make it complete with those variables?

Thanks a lot.

 

Thanks a lot, sire!

By the way, how to make it account bound?

(Each account can only receive the potions once a day).

 

Link to comment
Share on other sites

  • 0

  • Group:  Content Moderator
  • Topic Count:  55
  • Topics Per Day:  0.02
  • Content Count:  1676
  • Reputation:   703
  • Joined:  12/21/14
  • Last Seen:  

---------------------------------------

*getitembound <item id>,<amount>,<bound type>{,<account ID>};
*getitembound "<item name>",<amount>,<bound type>{,<account ID>};

This command behaves identically to 'getitem', but the items created will be
bound to the target character as specified by the bound type. All items created
in this manner cannot be dropped, sold, vended, auctioned, or mailed, and in
some cases cannot be traded or stored.

Valid bound types are:
 Bound_Account : Account Bound item
 Bound_Guild   : Guild Bound item
 Bound_Party   : Party Bound item
 Bound_Char    : Character Bound item

---------------------------------------

 

  • MVP 1
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  3
  • Topics Per Day:  0.00
  • Content Count:  10
  • Reputation:   0
  • Joined:  08/02/19
  • Last Seen:  

I will try to implement it.

Thank you so much for the assist, sire. You've helped me a lot!

Link to comment
Share on other sites

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.

×
×
  • Create New...