Code Monkey home page Code Monkey logo

display-villagers's Introduction

Display-Villagers

Summon all villagers and zombie villagers for testing during resource pack creation

Usage

Installation

  1. Download the latest release (or latest for your version/pack format)
  2. Add to the save's datapack folder. You don't need to apply it in-game, unlike resource packs. • %appdata%\.minecraft\saves
  3. If in world, run /reload.

Usage

  1. Run /function display_villagers:run_this
  2. Fly around villagers
  3. Run /kill @e[tag=statue] to remove the villagers

Design

Generating mcfunction

• A program is written to generate the mcfunction that has all villagers bar one • The code is probably really sloppy. It's one of my first projects (jacko-png). • For example, it must be run with Rust/ as the current working directory otherwise the file won't created • There is no error checking • Also, snake_case in the datapack (not Java semantics).

Datapack implementation

• A villager is summoned by display_villager:run_this as the origin • This villager runs display_villagers:backend/display • display_villagers:backend/display summons the rest of the villagers as an offest from the origin • The origin has its origin tag replaced with a statue tag, so that it can be handled with all the other villagers. • For example, execute as @e[tag=statue] at @s run tp @s ~ 324 ~ (over execute as @e[tag=statue] at @s run tp @s ~ 324 ~ and execute as @e[tag=o] at @s run tp @s ~ 324 ~)

display-villagers's People

Contributors

jackharro avatar

Watchers

 avatar

display-villagers's Issues

Add text_display besides rows/columns of villagers

Idea

text_display entities show type and profession of villagers. This is useful for packs that change the professions significantly from Vanilla, and in circumstances where the pack maker is not familiar with this change.

Implementation draft

execute at @s run summon text_display ~{x_off} ~ ~-3 <nbt> <-profession
execute at @s run summon text_display ~-3 ~ ~{z_off} <nbt> <-type

I don't know when it should be appended to the mcfunction so that it has the correct label and the correct position, and isn't overlapped 200 times.

Also spawn baby variants

Idea

In display-villagers/display, also summon the baby variants of the mobs.

Implementation draft

Some possible layouts are:

O o
O o

fig. 1
or

O
o
O
o

fig. 2
or

O
O
o
o

fig. 3

Where O is a group of adult mobs and o is a group of baby mobs.
Personally, I like the square one (fig. 1).

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.