Jump to content

ManiacRobert

Banned
  • Posts

    269
  • Joined

  • Last visited

  • Days Won

    6
  • Feedback

    0%

Posts posted by ManiacRobert

  1. JewelAccessoryPermaInfo = [
    		# PermaJewel		wrist	neck	ear
    		[ 50640,	14020,	16020,	17020 ],
    		[ 50641,	14040,	16040,	17040 ],
    		[ 50642,	14060,	16060,	17060 ],
    		[ 50643,	14080,	16080,	17080 ],
    		[ 50644,	14100,	16100,	17100 ],
    		[ 50645,	14120,	16120,	17120 ],
    		[ 50646,	14140,	16140,	17140 ],
    		[ 50647,	14160,	16160,	17160 ],
    		[ 50648,	14180,	16180,	17180 ],
    		[ 50649,	14200,	16200,	17200 ],
    		[ 50650,	14220,	16220,	17220 ],
    		[ 50651,	14500,	16500,	17500 ],
    		[ 50652,	14520,	16520,	17520 ],
    		[ 50653,	14540,	16540,	17540 ],
    		[ 50654,	14560,	16560,	17560 ],
    		[ 50655,	14570,	16570,	17230 ],
    
    	]
    
    def GET_ACCESSORY_MATERIAL_PERMANENT(vnum, subType):
    	ret = vnum
    	item_base = (vnum / 10) * 10
    	for info in JewelAccessoryPermaInfo:
    		if item.ARMOR_WRIST == subType:
    			if info[1] == item_base:
    				return info[0]
    		elif item.ARMOR_NECK == subType:
    			if info[2] == item_base:
    				return info[0]
    		elif item.ARMOR_EAR == subType:
    			if info[3] == item_base:
    				return info[0]

     

  2. A "2020 style" if someone need

     

    	auto ignore = std::array<DWORD, 6>{SKILL_HOSIN, SKILL_REFLECT, SKILL_GICHEON, SKILL_JEONGEOP, SKILL_KWAESOK, SKILL_JEUNGRYEOK};
    	if (std::find(std::begin(ignore), std::end(ignore), dwType) != std::end(ignore))
    	{
    		auto pkAffect = FindAffect(dwType);
    		if (pkAffect)
    		{
    			if (lApplyValue < pkAffect->lApplyValue)
    			{
    				ChatPacket(CHAT_TYPE_INFO, "<AddAffect> has blocked receiving skill (%s) because power is (%ld%%) more small than current one (%ld%%).", CSkillManager::instance().Get(dwType)->szName, lApplyValue, pkAffect->lApplyValue);
    				return false;
    			}
    		}	
    	}

     

  3. Is possible to reload interface with a single button.

     

      

    import sys
    def ReloadModule(moduleName):
    	if moduleName in sys.modules:
    		del sys.modules[moduleName]
    		del globals()[moduleName]
    		retModule = __import__(moduleName)
    		globals()[moduleName] = retModule
    	def ReloadInterface(self):
    		if self.wndGemWindow:
    			self.wndGemWindow.Hide()
    		del self.wndGemWindow	
    		ReloadModule("uiGemShop")
    
    		self.wndGemWindow = uiGemShop.GemShopSystem()
    		self.wndGemWindow.Open()

     

×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.