public SoulChannel soulBehaviour; //Handles all customized behaviour of what the channel effect should do public StateChanneling(Chr _chrOwner, int _nChannelTime, SoulChannel _soulBehaviour) : base(_chrOwner) { nChannelTime = _nChannelTime; //Double check that the soul isn't visible - should just be a hidden implementation Debug.Assert(_soulBehaviour.bVisible == false); soulBehaviour = _soulBehaviour; //Set the channel time to be equal to whatever the soul's duration is //Debug.Log("soulBehaviour's skill is initially " + soulBehaviour.skillSource.sName + " with duration " + nChannelTime); }
public int nSelectionsInputIndex; //Which index we should use from the NetworkReceiver buffer for our input public TypeUsageChannel(Skill skill, int _nStartChannelTime, SoulChannel _soulBehaviour) : base(skill) { nStartChannelTime = _nStartChannelTime; //If we've been given special soul effect, then use it if (_soulBehaviour != null) { soulBehaviour = _soulBehaviour; } else { //Otherwise just make a blank one soulBehaviour = new SoulChannel(skill); //Since this is a specially created soulBehaviour, we don't need to // do anything other than call the skill's Execute function when we complete channeling soulBehaviour.bDelayedSkill = true; } //Note that the soulbehaviour will be invisible and have infinite duration - it will just be removed // by some non-time related trigger (typically the character transitioning away from a Channeling State) }
public SoulChannel(SoulChannel soulToCopy, Skill _skill) : base(soulToCopy, soulToCopy.chrSource) { bDelayedSkill = soulToCopy.bDelayedSkill; bChannelCompleted = soulToCopy.bChannelCompleted; }