Beispiel #1
0
 /// <summary>
 /// Modifies the a NBT tag in the list.
 /// </summary>
 /// <param name="tag">The tag to be modified.</param>
 /// <param name="info">The new tag to be replaced.</param>
 public void ModifyTag(NBTTag tag, NBTTag info)
 {
     if (NamedNBT)
     {
         _dict[tag.Name] = info;
     }
     else
     {
         _list[_list.IndexOf(tag)] = info;
     }
 }
Beispiel #2
0
 /// <summary>
 /// Removes a existing NBT tag in the list.
 /// </summary>
 /// <param name="tag">The tag to be removed.</param>
 public void RemoveTag(NBTTag tag)
 {
     if (NamedNBT)
     {
         _dict.Remove(tag.Name);
     }
     else
     {
         _list.Remove(tag);
     }
 }
Beispiel #3
0
 /// <summary>
 /// Inserts a new NBT tag in the list.
 /// </summary>
 /// <param name="tag">The tag to be inserted.</param>
 public void InsertTag(NBTTag tag)
 {
     if (NamedNBT)
     {
         _dict.Add(tag.Name, tag);
     }
     else
     {
         _list.Add(tag);
     }
 }
Beispiel #4
0
 /// <summary>
 /// Modifies the a NBT tag in the list.
 /// </summary>
 /// <param name="tag">The tag to be modified.</param>
 /// <param name="info">The new tag to be replaced.</param>
 public void ModifyTag(NBTTag tag, NBTTag info)
 {
     if (NamedNBT)
         _dict[tag.Name] = info;
     else
         _list[_list.IndexOf(tag)] = info;
 }
Beispiel #5
0
 /// <summary>
 /// Removes a existing NBT tag in the list.
 /// </summary>
 /// <param name="tag">The tag to be removed.</param>
 public void RemoveTag(NBTTag tag)
 {
     if (NamedNBT)
         _dict.Remove(tag.Name);
     else
         _list.Remove(tag);
 }
Beispiel #6
0
 /// <summary>
 /// Inserts a new NBT tag in the list.
 /// </summary>
 /// <param name="tag">The tag to be inserted.</param>
 public void InsertTag(NBTTag tag)
 {
     if (NamedNBT)
         _dict.Add(tag.Name, tag);
     else
         _list.Add(tag);
 }