Outils pour utilisateurs

Outils du site


talents:desarmement

Ceci est une ancienne révision du document !


[FUNCTION f_desarmement] if (<i.tag0.desarmement»0)

IF !(<src.npc>)
	if !(<src.findid.i_desarmement_memory>)			
		IF (rand(100) <= (<i.tag0.desarmement>)/50)
			if !(<src.findlayer(2).type>==t_shield)
				if (<src.findlayer(2).type>==t_weapon_sword)
					src.tag.desarmementweapontype=5
				endif
				if 	(<src.findlayer(2).type>==t_weapon_fence)
					src.tag.desarmementweapontype=6
				endif
				
				if (<src.findlayer(2).type>==t_weapon_mace_smith) || (<src.findlayer(1).type>==t_weapon_mace_sharp) || (<src.findlayer(1).type>==t_weapon_mace_staff) || (<src.findlayer(1).type>==t_weapon_mace_crook) || (<src.findlayer(1).type>==t_weapon_mace_pick)
					src.tag.desarmementweapontype=7
				endif
				if (<src.findlayer(2).type>==t_weapon_axe)
					src.tag.desarmementweapontype=8
				endif
				TRY src.findlayer(2).unequip  //weapon			 
			endif
			if (<src.findlayer(1).type>==t_weapon_sword)
				src.tag.desarmementweapontype=1
			endif
			if (<src.findlayer(1).type>==t_weapon_fence)
				src.tag.desarmementweapontype=2
			endif
			
			if (<src.findlayer(1).type>==t_weapon_mace_smith) || (<src.findlayer(1).type>==t_weapon_mace_sharp) || (<src.findlayer(1).type>==t_weapon_mace_staff) || (<src.findlayer(1).type>==t_weapon_mace_crook) || (<src.findlayer(1).type>==t_weapon_mace_pick)
				src.tag.desarmementweapontype=3
			endif
			if (<src.findlayer(1).type>==t_weapon_axe)
				src.tag.desarmementweapontype=4
			endif
			TRY src.findlayer(1).unequip  //weapon
			src.sfx=0235
			src.effect=3,i_fx_sparkle_2,6,10,5,0771,0
			SRC.MESSAGEROUGE Vous vous faites désarmer votre arme.
			SERV.NEWITEM i_desarmement_memory
			SRC.EQUIP <NEW.UID>
			NEW.TIMER=(2+(<i.tag0.desarmement>)/200))
		ENDIF
	endif
ENDIF
IF (<src.npc>) && !(<src.tag.GlobalCooldownDesarmementNPC>==1)
	src.events +e_desarmement_npc
	src.emote Se fait désarmer
	src.timerf 2+(<i.tag0.desarmement>/200), src.events -e_desarmement_npc
	src.tag.GlobalCooldownDesarmementNPC=1
	src.timerf 100-(<i.tag0.desarmement>/20), src.tag.GlobalCooldownDesarmementNPC=
endif

Vaudou if (<src.defname>==c_Vaudou) IF !(<src.findid.i_mem_Vaudou.link.npc>) if !(<src.findid.i_mem_Vaudou.link.findid.i_desarmement_memory>) IF (rand(100) ⇐ (<i.tag0.desarmement>)/50) if !(<src.findid.i_mem_Vaudou.link.findlayer(2).type>==t_shield) if (<src.findid.i_mem_Vaudou.link.findlayer(2).type>==t_weapon_sword) src.findid.i_mem_Vaudou.link.tag.desarmementweapontype=5 endif if (<src.findid.i_mem_Vaudou.link.findlayer(2).type>==t_weapon_fence) src.findid.i_mem_Vaudou.link.tag.desarmementweapontype=6 endif if (<src.findid.i_mem_Vaudou.link.findlayer(2).type>==t_weapon_mace_smith) || (<src.findid.i_mem_Vaudou.link.findlayer(1).type>==t_weapon_mace_sharp) || (<src.findid.i_mem_Vaudou.link.findlayer(1).type>==t_weapon_mace_staff) || (<src.findid.i_mem_Vaudou.link.findlayer(1).type>==t_weapon_mace_crook) || (<src.findid.i_mem_Vaudou.link.findlayer(1).type>==t_weapon_mace_pick) src.findid.i_mem_Vaudou.link.tag.desarmementweapontype=7 endif if (<src.findid.i_mem_Vaudou.link.findlayer(2).type>==t_weapon_axe) src.findid.i_mem_Vaudou.link.tag.desarmementweapontype=8 endif TRY src.findid.i_mem_Vaudou.link.findlayer(2).unequip weapon

				endif
				if (<src.findid.i_mem_Vaudou.link.findlayer(1).type>==t_weapon_sword)
					src.findid.i_mem_Vaudou.link.tag.desarmementweapontype=1
				endif
				if (<src.findid.i_mem_Vaudou.link.findlayer(1).type>==t_weapon_fence)
					src.findid.i_mem_Vaudou.link.tag.desarmementweapontype=2
				endif
				
				if (<src.findid.i_mem_Vaudou.link.findlayer(1).type>==t_weapon_mace_smith) || (<src.findid.i_mem_Vaudou.link.findlayer(1).type>==t_weapon_mace_sharp) || (<src.findid.i_mem_Vaudou.link.findlayer(1).type>==t_weapon_mace_staff) || (<src.findid.i_mem_Vaudou.link.findlayer(1).type>==t_weapon_mace_crook) || (<src.findid.i_mem_Vaudou.link.findlayer(1).type>==t_weapon_mace_pick)
					src.findid.i_mem_Vaudou.link.tag.desarmementweapontype=3
				endif
				if (<src.findid.i_mem_Vaudou.link.findlayer(1).type>==t_weapon_axe)
					src.findid.i_mem_Vaudou.link.tag.desarmementweapontype=4
				endif
				TRY src.findid.i_mem_Vaudou.link.findlayer(1).unequip  //weapon
				SRC.findid.i_mem_Vaudou.link.MESSAGEROUGE Vous vous faites désarmer votre arme.
				SERV.NEWITEM i_desarmement_memory
				SRC.findid.i_mem_Vaudou.link.EQUIP <NEW.UID>
				NEW.TIMER=(2+(<i.tag0.desarmement>)/200))
			ENDIF
		endif
	ENDIF
	IF (<src.findid.i_mem_Vaudou.link.npc>) && !(<src.findid.i_mem_Vaudou.link.tag.GlobalCooldownDesarmementNPC>==1)
		src.findid.i_mem_Vaudou.link.events +e_desarmement_npc
		src.findid.i_mem_Vaudou.link.emote Se fait désarmer
		src.findid.i_mem_Vaudou.link.timerf 2+(<i.tag0.desarmement>/200), events -e_desarmement_npc
		src.findid.i_mem_Vaudou.link.tag.GlobalCooldownDesarmementNPC=1
		src.findid.i_mem_Vaudou.link.timerf 100-(<i.tag0.desarmement>/20), tag.GlobalCooldownDesarmementNPC=
	endif
endif

endif

talents/desarmement.1696371452.txt.gz · Dernière modification : de pintou10_live.fr