コード例 #1
0
    //public Card() { }
    //public Card(
    //    int _id,
    //    string _name,
    //    int _staminaValue,
    //    int _sanValue,
    //    int _buffId,
    //    Enum.SubjectToEnum _subjectTo,
    //    int _changeMonsterId,
    //    int _changeCardId,
    //    string _imageFileName
    //) {
    //    this.id = _id;
    //    this.cardName = _name;
    //    this.staminaValue = _staminaValue;
    //    this.sanValue = _sanValue;
    //    this.buffId = _buffId;
    //    this.subjectTo = _subjectTo;
    //    this.changeMonsterId = _changeMonsterId;
    //    this.changeCardId = _changeCardId;
    //    this.imageFileName = _imageFileName;

    //    this.listId = ControlManager.instance.cardList.Count();
    //    ControlManager.instance.cardList.Add(this);
    //}

    /// <summary>
    /// 写入值
    /// </summary>
    /// <param name="_id"></param>
    /// <param name="_name"></param>
    /// <param name="_staminaValue"></param>
    /// <param name="_sanValue"></param>
    /// <param name="_buffId"></param>
    /// <param name="_subjectTo"></param>
    /// <param name="_changeMonsterId"></param>
    /// <param name="_changeCardId"></param>
    /// <param name="_imageFileName"></param>
    public void SettingData(
        int _id,
        string _name,
        int _staminaValue,
        int _sanValue,
        int _buffId,
        Enum.SubjectToEnum _subjectTo,
        int _changeMonsterId,
        int _changeCardId,
        string _imageFileName
        )
    {
        this.id              = _id;
        this.cardName        = _name;
        this.staminaValue    = _staminaValue;
        this.sanValue        = _sanValue;
        this.buffId          = _buffId;
        this.subjectTo       = _subjectTo;
        this.changeMonsterId = _changeMonsterId;
        this.changeCardId    = _changeCardId;
        this.imageFileName   = _imageFileName;

        if (this.text != null)
        {
            this.text.text = this.cardName;
        }

        this.listId = ControlManager.instance.cardList.Count();
        ControlManager.instance.cardList.Add(this);
    }
コード例 #2
0
 public MonsterSkill(
     int _id,
     string _name,
     int _buffId,
     Enum.SubjectToEnum _subjectTo,
     int _staminaValue,
     int _sanValue,
     string _spineFileName
     )
 {
     this.id            = _id;
     this.name          = _name;
     this.buffId        = _buffId;
     this.subjectTo     = _subjectTo;
     this.staminaValue  = _staminaValue;
     this.sanValue      = _sanValue;
     this.spineFileName = _spineFileName;
 }