kn4tseb 
Master
 
Posts: 392
Likes Given: 45
Likes Received: 10 in 10 posts
Joined: May 2014
Reputation: 0
![]()
|
checking set armor
Hey mates, i need some help with this, i havent been abled to find a match variable for what im trying to do....
when equipping an armor i'd like to check if it matches with a set of that armor.... tags might be used... its a bit late and cant figure a good way to do that... this is what came to my head in last few moments, hope you can help me to improve it...
Code:
ON=@Equip
local.leatherarmor = i_leather_leggings, i_leather_cap, i_leather_gloves, i_leather_gorget, i_leather_tunic, i_leather_sleeves
args=4,6,7,10,13,19 // layers used by leather armor
for 0 5
if strmatch(*i_leather_*,<src.findlayer.<argv[<dlocal._for>]>.baseid>
local.args .=, <src.findlayer.<argv[<dlocal._for>]>.baseid>
endif
endfor
args=<streat <local.args>>
local.armormatch1=<eval <argv0>+<argv1>+<argv2>+<argv3>+<argv4>+<argv5>>
args=<local.leatherarmor>
local.armormatch2=<eval <argv0>+<argv1>+<argv2>+<argv3>+<argv4>+<argv5>>
if <local.armormatch1> == <local.armormatch2>
serv.log <local.armormatch1> <local.armormatch2>
endif
ENDIF
Thx in advance
(This post was last modified: 08-07-2014 03:09 PM by kn4tseb.)
|
|
08-07-2014 03:03 PM |
|
|