Function ExamineEquipments(Actor akTarget) String s Int iThisSlot = 0x01 Int iSlotsChecked = 0x00100000 + 0x00200000 ; チェックを省くスロット while iThisSlot < 0x80000000 if Math.LogicalAnd(iSlotsChecked, iThisSlot) != iThisSlot Armor kArmor = akTarget.GetWornForm(iThisSlot) as Armor if kArmor iSlotsChecked += kArmor.GetSlotMask() if kArmor.IsPlayable() && ( kArmor.IsHeavyArmor() || kArmor.IsLightArmor() ) if s s += "\n" endif s += ExamineThisArmor(kArmor, akTarget, iThisSlot) endif else iSlotsChecked += iThisSlot endif endif iThisSlot *= 2 endwhile if s Debug.MessageBox(s) endif EndFunction String Function ExamineThisArmor(Armor akArmor, ObjectReference akTargetRef, Int aiSlotMask = 0) String s = akArmor.GetName() Float fHealth if akTargetRef as Actor fHealth = WornObject.GetItemHealthPercent(akTargetRef as Actor, handSlot = 0, slotMask = aiSlotMask) else fHealth = akTargetRef.GetItemHealthPercent() endif s += " (" + Math.Floor( (fHealth - 1.0) * 1000.0 ) + ")" ; 切り下げないとEDSの表示と合わない if Game.GetModByName(KYE_File) != 255 if akArmor.HasKeywordString("kye_armor_warm") s += JsonUtil.GetStringValue(MessageFile, "armor_warm", "\nWarm : weak to arrows, resist ice") endif if akArmor.HasKeywordString("kye_armor_leathery") s += JsonUtil.GetStringValue(MessageFile, "armor_leathery", "\nLeathery : weak to arrows, resist fire") endif if akArmor.HasKeywordString("kye_armor_brittle") s += JsonUtil.GetStringValue(MessageFile, "armor_brittle", "\nBrittle : weak to maces") endif if akArmor.HasKeywordString("kye_armor_nonconductive") s += JsonUtil.GetStringValue(MessageFile, "armor_nonconductive", "\nNonconductive : resist shock, weak to fire and ice") endif if akArmor.HasKeywordString("kye_armor_thick") s += JsonUtil.GetStringValue(MessageFile, "armor_thick", "\nThick : resist arrows, daggers and swords") endif if akArmor.HasKeywordString("kye_armor_metal") s += JsonUtil.GetStringValue(MessageFile, "armor_metal", "\nMetal : resist arrows, daggers and swords, weak to fire, ice and shock") endif if akArmor.HasKeywordString("kye_armor_layered") s += JsonUtil.GetStringValue(MessageFile, "armor_layered", "\nLayered : resist arrows") endif if akArmor.HasKeywordString("kye_armor_deep") s += JsonUtil.GetStringValue(MessageFile, "armor_deep", "\nDeep : resist maces and axes") endif endif return s EndFunction