Git Product home page Git Product logo

Comments (4)

StealthyExpertX avatar StealthyExpertX commented on May 17, 2024

I also have an idea for a method for the item class,
is_enchanted(item) will take an item object and check if the item is enchanted and return true if the
item is not enchanted will return false.

Something similar to this would work.
`

  1. def is_enchanted(item):
  2. if "tag" in item:
    
  3.     if "ench" in item["tag"]:
    
  4.        return True
    
  5.     return False
    
  6.  return False
    

`

Also, there should be a way for users to get a look-up table for item names and block names in ingame format or internal format meaning this,

ingame = "Stone",
with prefix = "minecraft:stone",
without prefix = "stone",
number tuple = (1, 0)

but a collection of all say ingame for example names so we can call input block or item pickers ingame instead of users having to define them manually we can simply call a method that has two variables one for data_type and one for output_type.

from amulet-core.

Podshot avatar Podshot commented on May 17, 2024

I think that's a good idea! I'll work on that once #36 is completed impl-entities branch is merged into master

from amulet-core.

gentlegiantJGC avatar gentlegiantJGC commented on May 17, 2024

I have been putting it off but I think it would make sense to do versioning for this in the translation library. As far as I am aware items are all blocks with some additions/modifications

from amulet-core.

gentlegiantJGC avatar gentlegiantJGC commented on May 17, 2024

After a bit more thought I think items should be left as NBT and the translation library should deal with them how it wants internally but should be given and return NBT.
I am going to close this issue because I don't think Amulet should have a specific class representation of an Item. This is partially due to it being stored within an NBT object and only NBT objects are allowed to be stored within other NBT objects

from amulet-core.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.