Jump to content
  • 0

callfunc on item help || give specific item that is character bounded


AinsLord

Question


  • Group:  Members
  • Topic Count:  257
  • Topics Per Day:  0.08
  • Content Count:  737
  • Reputation:   18
  • Joined:  11/21/15
  • Last Seen:  

here is the script i found here by @Euphy 

this is a weapon box that they can choose weapon

function	script	Shinbox	{
setarray .@Jobs$[0], "Spear:Shuriken";
setarray .@Items[0], 47001, 47002;
set .@menu$,"";
for(set .@i,0; .@i<getarraysize(.@Jobs$); set .@i,.@i+1)
 set .@menu$, .@menu$+.@Jobs$[.@i]+":";
getitem .@Items[select(.@menu$)], 1;
return; }

here's my concern

1. when i click the item and shows the list i clicked shuriken item 2 doesnt show and give this error on my console

[Error]: buildin_getitem: Nonexistant item 0 requested.
[Debug]: Source (NPC): FAKE_NPC (invisible/not on a map)

2. when i clicked the spear selection the item 2 will come out not the 1st item

3. how can i make the items bounded on character

 

thnx for the help

Edited by whodhell
Link to comment
Share on other sites

2 answers to this question

Recommended Posts

  • 0

  • Group:  Forum Moderator
  • Topic Count:  93
  • Topics Per Day:  0.02
  • Content Count:  10015
  • Reputation:   2348
  • Joined:  10/28/11
  • Last Seen:  

function	script	Shinbox	{
	setarray .@Jobs$, "Spear", "Shuriken";
	setarray .@Items, 47001, 47002;

	.@size = getarraysize(.@Jobs$);
	for(.@i = 0; .@i < .@size; .@i++)
		.@menu$ = .@menu$ + .@Jobs$[.@i] + ":";
	getitembound .@Items[select(.@menu$) - 1], 1, Bound_Char;
                              
	return; 
}

 

  • MVP 1
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  257
  • Topics Per Day:  0.08
  • Content Count:  737
  • Reputation:   18
  • Joined:  11/21/15
  • Last Seen:  

3 minutes ago, Emistry said:

function	script	Shinbox	{
	setarray .@Jobs$, "Spear", "Shuriken";
	setarray .@Items, 47001, 47002;

	.@size = getarraysize(.@Jobs$);
	for(.@i = 0; .@i < .@size; .@i++)
		.@menu$ = .@menu$ + .@Jobs$[.@i] + ":";
	getitembound .@Items[select(.@menu$) - 1], 1, Bound_Char;
                              
	return; 
}

 

thnx @Emistry ur d'best

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...