コード例 #1
0
 public override void SetData(EInteractiveObjectData p_key, String p_value)
 {
     if (p_key == EInteractiveObjectData.BARREL_DATA)
     {
         Int32            p_staticId = Convert.ToInt32(p_value);
         BarrelStaticData staticData = StaticDataHandler.GetStaticData <BarrelStaticData>(EDataType.BARRELS, p_staticId);
         Prefab            = staticData.Prefab;
         m_targetAttribute = staticData.TargetAttribute;
         m_value           = staticData.Value;
     }
 }
コード例 #2
0
 public override void SetData(EInteractiveObjectData p_key, String p_value)
 {
     if (p_key == EInteractiveObjectData.RECHARGING_OBJECT_DATA)
     {
         Int32 p_staticId;
         Int32.TryParse(p_value, out p_staticId);
         RechargingObjectStaticData staticData = StaticDataHandler.GetStaticData <RechargingObjectStaticData>(EDataType.RECHARGING_OBJECTS, p_staticId);
         if (staticData != null)
         {
             Prefab          = staticData.Prefab;
             m_partyBuff     = staticData.PartyBuff;
             m_special       = staticData.Special;
             m_rechargerType = staticData.RechargerType;
         }
     }
 }
コード例 #3
0
 public override void SetData(EInteractiveObjectData p_key, String p_value)
 {
     if (p_key == EInteractiveObjectData.AUTOSTART_NPC)
     {
         m_autoStartNPC = Convert.ToInt32(p_value);
     }
     else if (p_key == EInteractiveObjectData.START_DIALOG_ID)
     {
         m_startDialogID = Convert.ToInt32(p_value);
     }
     else if (p_key == EInteractiveObjectData.SHOW_NPCS)
     {
         m_showNpcs = Convert.ToBoolean(p_value);
     }
     else
     {
         base.SetData(p_key, p_value);
     }
 }
コード例 #4
0
 protected override void ParseExtra(String p_extra)
 {
     String[] array = p_extra.Split(new Char[]
     {
         ','
     });
     if (Enum.IsDefined(typeof(EInteractiveObjectData), array[0]))
     {
         m_key   = (EInteractiveObjectData)Enum.Parse(typeof(EInteractiveObjectData), array[0]);
         m_value = String.Empty;
         for (Int32 i = 1; i < array.Length; i++)
         {
             if (i > 1)
             {
                 m_value += ",";
             }
             m_value += array[i];
         }
         return;
     }
     throw new FormatException("First parameter was not an InteractiveObjectData key!");
 }
コード例 #5
0
 public override void SetData(EInteractiveObjectData p_key, String p_value)
 {
     if (p_key == EInteractiveObjectData.CONDITIONAL_DATA)
     {
         String[] array = p_value.Split(new Char[]
         {
             ','
         });
         Int32 id = Convert.ToInt32(array[0]);
         if (Enum.IsDefined(typeof(EInteractiveObjectState), array[1]))
         {
             EInteractiveObjectState wantedState = (EInteractiveObjectState)Enum.Parse(typeof(EInteractiveObjectState), array[1]);
             ObjectCondition         item;
             item.id          = id;
             item.wantedState = wantedState;
             m_conditions.Add(item);
         }
     }
     else
     {
         base.SetData(p_key, p_value);
     }
 }