Simplify update method
Signed-off-by: jolheiser <john.olheiser@gmail.com>
This commit is contained in:
@ -1,7 +1,7 @@
|
||||
## Updating `data`
|
||||
|
||||
1. Go to [https://github.com/PrismarineJS/minecraft-data/tree/master/data/pc/{version}](https://github.com/PrismarineJS/minecraft-data/tree/master/data/pc)
|
||||
2. Update the URL in the following files if there is a new corresponding JSON file available:
|
||||
2. Update `version` in the following files if there is a new corresponding JSON file available:
|
||||
- [gen_block.go](block/gen_block.go) - `blocks.json`
|
||||
- [gen_entity.go](entity/gen_entity.go) - `entities.json`
|
||||
- [gen_item.go](item/gen_item.go) - `items.json`
|
||||
|
@ -14,7 +14,8 @@ import (
|
||||
)
|
||||
|
||||
const (
|
||||
infoURL = "https://raw.githubusercontent.com/PrismarineJS/minecraft-data/master/data/pc/1.17/blocks.json"
|
||||
version = "1.17"
|
||||
infoURL = "https://raw.githubusercontent.com/PrismarineJS/minecraft-data/master/data/pc/" + version + "/blocks.json"
|
||||
//language=gohtml
|
||||
blockTmpl = `// Code generated by gen_block.go; DO NOT EDIT.
|
||||
|
||||
|
@ -14,7 +14,8 @@ import (
|
||||
)
|
||||
|
||||
const (
|
||||
infoURL = "https://raw.githubusercontent.com/PrismarineJS/minecraft-data/master/data/pc/1.17/entities.json"
|
||||
version = "1.17"
|
||||
infoURL = "https://raw.githubusercontent.com/PrismarineJS/minecraft-data/master/data/pc/" + version + "/entities.json"
|
||||
//language=gohtml
|
||||
entityTmpl = `// Code generated by gen_entity.go DO NOT EDIT.
|
||||
// Package entity stores information about entities in Minecraft.
|
||||
|
@ -14,7 +14,8 @@ import (
|
||||
)
|
||||
|
||||
const (
|
||||
infoURL = "https://raw.githubusercontent.com/PrismarineJS/minecraft-data/master/data/pc/1.17/items.json"
|
||||
version = "1.17"
|
||||
infoURL = "https://raw.githubusercontent.com/PrismarineJS/minecraft-data/master/data/pc/" + version + "/items.json"
|
||||
//language=gohtml
|
||||
itemTmpl = `// Code generated by gen_item.go DO NOT EDIT.
|
||||
// Package item stores information about items in Minecraft.
|
||||
|
@ -15,7 +15,8 @@ import (
|
||||
)
|
||||
|
||||
const (
|
||||
protocolURL = "https://raw.githubusercontent.com/PrismarineJS/minecraft-data/master/data/pc/1.17.1/protocol.json"
|
||||
version = "1.17.1"
|
||||
protocolURL = "https://raw.githubusercontent.com/PrismarineJS/minecraft-data/master/data/pc/" + version + "/protocol.json"
|
||||
//language=gohtml
|
||||
packetidTmpl = `// This file is automatically generated by gen_packetIDs.go. DO NOT EDIT.
|
||||
|
||||
|
@ -13,7 +13,8 @@ import (
|
||||
)
|
||||
|
||||
const (
|
||||
protocolURL = "https://pokechu22.github.io/Burger/1.17.1.json"
|
||||
version = "1.17.1"
|
||||
protocolURL = "https://pokechu22.github.io/Burger/" + version + ".json"
|
||||
//language=gohtml
|
||||
soundTmpl = `// Code generated by gen_soundid.go. DO NOT EDIT.
|
||||
|
||||
|
Reference in New Issue
Block a user