public override void Initialize(RoomModifierData roomModifierData, RoomManager roomManager)
 {
     base.Initialize(roomModifierData, roomManager);
     this.buffAmount    = roomModifierData.GetParamInt();
     this.combatManager = GameObject.FindObjectOfType <CombatManager>().GetComponent <CombatManager>() as CombatManager;
     this.roomManager   = roomManager;
 }
Beispiel #2
0
 public override void Initialize(RoomModifierData roomModifierData, RoomManager roomManager)
 {
     base.Initialize(roomModifierData, roomManager);
     this.numOfCards  = roomModifierData.GetParamInt();
     this.cardManager = GameObject.FindObjectOfType <CardManager>().GetComponent <CardManager>() as CardManager;
     this.cardManager.OnCardPlayedCallback += new CardManager.OnCardPlayedEvent(this.OnPlayedCard);
 }
Beispiel #3
0
 public override void Initialize(RoomModifierData roomModifierData, RoomManager roomManager)
 {
     base.Initialize(roomModifierData, roomManager);
     refundAmount     = roomModifierData.GetParamInt();
     this.roomManager = roomManager;
     ProviderManager.TryGetProvider <PlayerManager>(out playerManager);
     this.cardManager = GameObject.FindObjectOfType <CardManager>().GetComponent <CardManager>() as CardManager;
 }
        public override void Initialize(RoomModifierData roomModifierData, RoomManager roomManager)
        {
            base.Initialize(roomModifierData, roomManager);

            // To save time, we only implement an attack buff component here
            // Via hashing of the param int, we could expand this to health later
            _baseAttack = GetParamInt();
            _buffAttack = 0;
        }
        public override void Initialize(RoomModifierData roomModifierData, RoomManager roomManager)
        {
            base.Initialize(roomModifierData, roomManager);

            numOfCards = roomModifierData.GetParamInt();

            var cardManager = GameObject.FindObjectOfType <CardManager>().GetComponent <CardManager>() as CardManager;

            cardManager.OnCardPlayedCallback -= callback;
            cardManager.OnCardPlayedCallback += callback;
        }
Beispiel #6
0
        /// <summary>
        /// Builds the RoomModifierData represented by this builders's parameters recursively;
        /// </summary>
        /// <returns>The newly created RoomModifierData</returns>
        public RoomModifierData Build()
        {
            RoomModifierData roomModifierData = new RoomModifierData();

            BuilderUtils.ImportStandardLocalization(this.DescriptionKey, this.Description);
            AccessTools.Field(typeof(RoomModifierData), "descriptionKey").SetValue(roomModifierData, this.DescriptionKey);
            BuilderUtils.ImportStandardLocalization(this.ExtraTooltipBodyKey, this.ExtraTooltipBody);
            AccessTools.Field(typeof(RoomModifierData), "extraTooltipBodyKey").SetValue(roomModifierData, this.ExtraTooltipBodyKey);
            BuilderUtils.ImportStandardLocalization(this.ExtraTooltipTitleKey, this.ExtraTooltipTitle);
            AccessTools.Field(typeof(RoomModifierData), "extraTooltipTitleKey").SetValue(roomModifierData, this.ExtraTooltipTitleKey);
            AccessTools.Field(typeof(RoomModifierData), "icon").SetValue(roomModifierData, this.Icon);
            AccessTools.Field(typeof(RoomModifierData), "paramInt").SetValue(roomModifierData, this.ParamInt);
            AccessTools.Field(typeof(RoomModifierData), "paramStatusEffects").SetValue(roomModifierData, this.ParamStatusEffects);
            AccessTools.Field(typeof(RoomModifierData), "paramSubtype").SetValue(roomModifierData, this.ParamSubtype);
            AccessTools.Field(typeof(RoomModifierData), "roomStateModifierClassName").SetValue(roomModifierData, this.RoomStateModifierClassName);
            return(roomModifierData);
        }
 public override void Initialize(RoomModifierData roomModifierData, RoomManager roomManager)
 {
     base.Initialize(roomModifierData, roomManager);
     this.effects       = roomModifierData.GetParamStatusEffects();
     this.combatManager = GameObject.FindObjectOfType <CombatManager>().GetComponent <CombatManager>() as CombatManager;
 }
Beispiel #8
0
 public override void Initialize(RoomModifierData roomModifierData, RoomManager roomManager)
 {
     base.Initialize(roomModifierData, roomManager);
     ProviderManager.TryGetProvider <CardManager>(out cardManager);
 }