Jump to content
  • 0

How to trigger this setarray?


celeron0134

Question


  • Group:  Members
  • Topic Count:  66
  • Topics Per Day:  0.02
  • Content Count:  194
  • Reputation:   1
  • Joined:  12/13/16
  • Last Seen:  

Hello good day ,, can i trigger this?

setarray .@indices[1], EQI_HEAD_TOP, EQI_ARMOR, EQI_HAND_L, EQI_HAND_R, EQI_GARMENT, EQI_SHOES, EQI_ACC_L, EQI_ACC_R, EQI_HEAD_MID, EQI_HEAD_LOW;
	for(.@i = 1; .@i<getarraysize(.@indices); ++.@i) {

		if(getequipisequiped(.@indices[.@i])) {

			.@menu$ = .@menu$ + F_getpositionname(.@indices[.@i]) + "-[" + getequipname(.@indices[.@i]) + "]";
			.@equipped = 1;

		}
		.@menu$ = .@menu$ + ":";

	}

how can i trigger EQI_HEAD_TOP or EQI_SHOES

if(getequipisequiped(.@indices[EQI_HEAD_TOP])) {
    mes "Yup this is the headgear";
    close;
}

if(getequipisequiped(.@indices[EQI_SHOES])) {
    mes "Yup this is the Footgear";
    close;
}

so when i picked any headgear it will go to their respective ifs
 

Link to comment
Share on other sites

3 answers to this question

Recommended Posts

  • 0

  • Group:  Members
  • Topic Count:  66
  • Topics Per Day:  0.02
  • Content Count:  194
  • Reputation:   1
  • Joined:  12/13/16
  • Last Seen:  

setarray .@indices[1], EQI_HEAD_TOP, EQI_ARMOR;

i tried but failed

 setarray .@indices[1], ""+EQI_HEAD_TOP+"::OnHead", ""+EQI_ARMOR+"::OnArmor";

so it when a headgear is picked it will go on the OnHead Label.. if Armor is picked it will go OnArmor Label

Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  162
  • Topics Per Day:  0.05
  • Content Count:  1546
  • Reputation:   192
  • Joined:  07/23/14
  • Last Seen:  

3 hours ago, celeron0134 said:

setarray .@indices[1], EQI_HEAD_TOP, EQI_ARMOR;

i tried but failed

 setarray .@indices[1], ""+EQI_HEAD_TOP+"::OnHead", ""+EQI_ARMOR+"::OnArmor";

so it when a headgear is picked it will go on the OnHead Label.. if Armor is picked it will go OnArmor Label

Are you trying to call a function on a player picking loots and will automatically equipped?

  • Upvote 1
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  66
  • Topics Per Day:  0.02
  • Content Count:  194
  • Reputation:   1
  • Joined:  12/13/16
  • Last Seen:  

5 hours ago, Radian said:

Are you trying to call a function on a player picking loots and will automatically equipped?

thx for the reply.. but no.. im trying to make a script for enchantment

anyways i did figure it out.. using cases.. thanks a lot tho for giving attention to my question

 

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