FANDOM


Created by Taz.

Using "RC_Core.rcm"
; Define entry function 'Main'

Function Main()
Player = Actor()
Target = ContextActor()

TargetIsHuman% = ActorIsHuman(Target)
MaxBlood% = MaxAttribute(Player, "Blood")

;--------------------------------Vampire Check--------------------------------------------------------
 ;If vamp dont tell player they cant use a pet in this form            
                IsVamp% = ActorId("Vampire", "Form")
                PRace$ = Race(Player)     
                PClass$ = Class(Player)
                PlayerID% =ActorID(PRace, PClass)
                
                If Not (IsVamp = PlayerID) ;if player is a vampire
                    OutPut(Player, "You can not use a vampire ability in human form.", 255, 34, 12)
                    Return
                EndIf
;----------------------------End Vampire Check--------------------------------------------------------

If(TargetIsHuman = 1)
	Output(Player, "Cant cast onto a player. Must be a NPC.")
	Return
EndIf

CreateEmitter(Target, "Blood", 10, 300)
DoEvents(1000)
SetAttribute(Target, "Health", 0)
SetAttribute(Player, "Blood", MaxBlood)

OutPut(Player, "Blood Replinished.")
Return
End Function