Jump to content
  • 0

refine slot for shadow equipment


hendra814

Question


  • Group:  Members
  • Topic Count:  55
  • Topics Per Day:  0.01
  • Content Count:  1191
  • Reputation:   161
  • Joined:  06/12/12
  • Last Seen:  

Hi,

i have safe refine to limit, but all i want to know from this script is the slot number represents which equipment

like 0 for headgear or what?

cause i don't know where to find this detail, and i want add safe refine for shadow equipment.

Please some give me guide.

here the script

prontera,171,225,4	script	Great Refiner	826,{
setarray .@slots[0],2,3,4,5,6,7,8,9,10;
for( set .@a,0; .@a < getarraysize(.@slots); set .@a,.@a + 1 ) {
     if( getequipisequiped(.@slots[.@a]) ) {
                  if( .@slots[.@a] == 8 || .@slots[.@a] == 9) {
                       switch( getequipweaponlv(.@slots[.@a]) ) {
                            case 0:
                                 set .@r, 4;
                                 break;
                            default:
                                 set .@r, 8 - getequipweaponlv(.@slots[.@a]);
                                 break;
                            }
                       } else { set .@r, 4; }
		  set .@refinefix,.@r-getequiprefinerycnt(.@slots[.@a]);
          if(getequiprefinerycnt(.@slots[.@a]) < .@r && getequipisenableref(.@slots[.@a]) ) {
               for( set .@i,0; .@i < .@refinefix; set .@i,.@i + 1)
					successrefitem .@slots[.@a];
               }
      }
      sleep2 100;
}

}

 

Edited by hendra814
Link to comment
Share on other sites

3 answers to this question

Recommended Posts

  • 0

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

not really sure about the script

but when i see it i remember the Global_Functions

the F_getpositionname

you don't use it in your script but it look like the script working on it ?

E:/GitHub/rathena/npc/other/Global_Functions.txt

function	script	F_getpositionname	{
	switch( getarg(0,999) ) {
		case EQI_ACC_L:		return "Accessory 1";
		case EQI_ACC_R:		return "Accessory 2";
		case EQI_SHOES:		return "Shoes";
		case EQI_GARMENT:	return "Robe";
		case EQI_HEAD_LOW:	return "Head 3";
		case EQI_HEAD_MID:	return "Head 2";
		case EQI_HEAD_TOP:	return "Head";
		case EQI_ARMOR:		return "Body";
		case EQI_HAND_L:	return "Left hand";
		case EQI_HAND_R:	return "Right hand";
		case EQI_COSTUME_HEAD_TOP:	return "Upper Costume Headgear";
		case EQI_COSTUME_HEAD_MID:	return "Middle Costume Headgear";
		case EQI_COSTUME_HEAD_LOW:	return "Lower Costume Headgear";
		case EQI_COSTUME_GARMENT:	return "Costume Garment";
		case EQI_AMMO:			return "Arrow/Ammunition";
		case EQI_SHADOW_ARMOR:	return "Shadow Armor";
		case EQI_SHADOW_WEAPON:	return "Shadow Weapon";
		case EQI_SHADOW_SHIELD:	return "Shadow Shield";
		case EQI_SHADOW_SHOES:	return "Shadow Shoes";
		case EQI_SHADOW_ACC_R:	return "Shadow Accessory 2";
		case EQI_SHADOW_ACC_L:	return "Shadow Accessory 1";
		default:
			return "Unknown";
	}
}

as i see 

setarray .@slots[0],2,3,4,5,6,7,8,9,10;

0 and 1 not in the array so you mean the accessorys ?

if( .@slots[.@a] == 8 || .@slots[.@a] == 9) {

= the weapons ?

if you meant to use the F_getpositionname function then it's up and the shadow equipments are in it but i don't really think that the script completed ? not really sure

  • Love 1
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  55
  • Topics Per Day:  0.01
  • Content Count:  1191
  • Reputation:   161
  • Joined:  06/12/12
  • Last Seen:  

6 hours ago, sader1992 said:

not really sure about the script

but when i see it i remember the Global_Functions

the F_getpositionname

you don't use it in your script but it look like the script working on it ?

E:/GitHub/rathena/npc/other/Global_Functions.txt


function	script	F_getpositionname	{
	switch( getarg(0,999) ) {
		case EQI_ACC_L:		return "Accessory 1";
		case EQI_ACC_R:		return "Accessory 2";
		case EQI_SHOES:		return "Shoes";
		case EQI_GARMENT:	return "Robe";
		case EQI_HEAD_LOW:	return "Head 3";
		case EQI_HEAD_MID:	return "Head 2";
		case EQI_HEAD_TOP:	return "Head";
		case EQI_ARMOR:		return "Body";
		case EQI_HAND_L:	return "Left hand";
		case EQI_HAND_R:	return "Right hand";
		case EQI_COSTUME_HEAD_TOP:	return "Upper Costume Headgear";
		case EQI_COSTUME_HEAD_MID:	return "Middle Costume Headgear";
		case EQI_COSTUME_HEAD_LOW:	return "Lower Costume Headgear";
		case EQI_COSTUME_GARMENT:	return "Costume Garment";
		case EQI_AMMO:			return "Arrow/Ammunition";
		case EQI_SHADOW_ARMOR:	return "Shadow Armor";
		case EQI_SHADOW_WEAPON:	return "Shadow Weapon";
		case EQI_SHADOW_SHIELD:	return "Shadow Shield";
		case EQI_SHADOW_SHOES:	return "Shadow Shoes";
		case EQI_SHADOW_ACC_R:	return "Shadow Accessory 2";
		case EQI_SHADOW_ACC_L:	return "Shadow Accessory 1";
		default:
			return "Unknown";
	}
}

as i see 


setarray .@slots[0],2,3,4,5,6,7,8,9,10;

0 and 1 not in the array so you mean the accessorys ?


if( .@slots[.@a] == 8 || .@slots[.@a] == 9) {

= the weapons ?

if you meant to use the F_getpositionname function then it's up and the shadow equipments are in it but i don't really think that the script completed ? not really sure

 

Thanks ,

now i know that number mean.

i will try to modified my script later.

Edited by hendra814
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  55
  • Topics Per Day:  0.01
  • Content Count:  1191
  • Reputation:   161
  • Joined:  06/12/12
  • Last Seen:  

46 minutes ago, Arthenaz said:

setarray .@slots[1], EQI_SHADOW_ARMOR, EQI_SHADOW_WEAPON, EQI_SHADOW_SHIELD, EQI_SHADOW_SHOES, EQI_SHADOW_ACC_R, EQI_SHADOW_ACC_L;
for(set .@i,1; .@i<getarraysize(.@slots); set .@i,.@i+1) {
		if(getequipisequiped(.@slots[.@i])) {
			set .@menu$, .@menu$ + F_getpositionname(.@slots[.@i]) + " - [ " + getequipname(.@slots[.@i]) + " ]";
			set .@equipped,1;
		}
		set .@menu$, .@menu$ + ":";
	}
                                          

EQI_COMPOUND_ON (-1)      - Item slot that calls this script (In context of item script)
EQI_ACC_L (0)             - Accessory 1
EQI_ACC_R (1)             - Accessory 2
EQI_SHOES (2)             - Footgear (shoes, boots)
EQI_GARMENT (3)           - Garment (mufflers, hoods, manteaux)
EQI_HEAD_LOW (4)          - Lower Headgear (beards, some masks)
EQI_HEAD_MID (5)          - Middle Headgear (masks, glasses)
EQI_HEAD_TOP (6)          - Upper Headgear
EQI_ARMOR (7)             - Armor (jackets, robes)
EQI_HAND_L (8)            - Left hand (weapons, shields)
EQI_HAND_R (9)            - Right hand (weapons)
EQI_COSTUME_HEAD_TOP (10) - Upper Costume Headgear
EQI_COSTUME_HEAD_MID (11) - Middle Costume Headgear
EQI_COSTUME_HEAD_LOW (12) - Lower Costume Headgear
EQI_COSTUME_GARMENT (13)  - Costume Garment
EQI_AMMO (14)    		  - Arrow/Ammunition
EQI_SHADOW_ARMOR (15)     - Shadow Armor
EQI_SHADOW_WEAPON (16)    - Shadow Weapon
EQI_SHADOW_SHIELD (17)    - Shadow Shield
EQI_SHADOW_SHOES (18)     - Shadow Shoes
EQI_SHADOW_ACC_R (19)     - Shadow Accessory 2
EQI_SHADOW_ACC_L (20)     - Shadow Accessory 1

//////////////////////////////////////////////////////////////////////////////////
// Return the position name of the EQI_* equipment slot.
//////////////////////////////////////////////////////////////////////////////////
function	script	F_getpositionname	{
	switch( getarg(0,999) ) {
		case EQI_ACC_L:		return "Accessory 1";
		case EQI_ACC_R:		return "Accessory 2";
		case EQI_SHOES:		return "Shoes";
		case EQI_GARMENT:	return "Robe";
		case EQI_HEAD_LOW:	return "Head 3";
		case EQI_HEAD_MID:	return "Head 2";
		case EQI_HEAD_TOP:	return "Head";
		case EQI_ARMOR:		return "Body";
		case EQI_HAND_L:	return "Left hand";
		case EQI_HAND_R:	return "Right hand";
		case EQI_COSTUME_HEAD_TOP:	return "Upper Costume Headgear";
		case EQI_COSTUME_HEAD_MID:	return "Middle Costume Headgear";
		case EQI_COSTUME_HEAD_LOW:	return "Lower Costume Headgear";
		case EQI_COSTUME_GARMENT:	return "Costume Garment";
		case EQI_AMMO:			return "Arrow/Ammunition";
		case EQI_SHADOW_ARMOR:	return "Shadow Armor";
		case EQI_SHADOW_WEAPON:	return "Shadow Weapon";
		case EQI_SHADOW_SHIELD:	return "Shadow Shield";
		case EQI_SHADOW_SHOES:	return "Shadow Shoes";
		case EQI_SHADOW_ACC_R:	return "Shadow Accessory 2";
		case EQI_SHADOW_ACC_L:	return "Shadow Accessory 1";
		default:
			return "Unknown";
	}
}

 

Thanks for his.

Edited by hendra814
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...