Jump to content
  • 0

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


Question

Posted (edited)

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

2 answers to this question

Recommended Posts

  • 0
Posted
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
  • 0
Posted
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

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