# warning: content has blocks/items, but src/ never calls `yog_api::content!();` — they get models but aren't registered
# content.g.rs
// <auto-generated>
// Generated by `yog build` from content/** — don't edit, it's rewritten
// on every build. Included by `yog_api::content!()`.
// </auto-generated>
include!(concat!(env!("CARGO_MANIFEST_DIR"), "/generated/content/blocks.g.rs"));
include!(concat!(env!("CARGO_MANIFEST_DIR"), "/generated/content/items.g.rs"));
include!(concat!(env!("CARGO_MANIFEST_DIR"), "/generated/content/register.g.rs"));
# content/blocks.g.rs
// <auto-generated>
// Generated by `yog build` from content/** — don't edit, it's rewritten
// on every build. Included by `yog_api::content!()`.
// </auto-generated>
/// The blocks of `content/`: the id and a [`::yog_api::BlockDef`] of each.
#[allow(dead_code)]
pub struct Blocks;
#[allow(dead_code, clippy::all)]
impl Blocks {
/// `gm:glass` — `content/glass.yblock`.
pub const GLASS: &'static str = "gm:glass";
/// The definition from `content/glass.yblock` (name and tooltip come from the lang files).
pub fn glass() -> ::yog_api::BlockDef {
::yog_api::BlockDef::new(Self::GLASS)
.strength(0.3, 6.0)
.sound("minecraft:glass")
}
/// `gm:ore` — `content/ore.yblock`.
pub const ORE: &'static str = "gm:ore";
/// The definition from `content/ore.yblock` (name and tooltip come from the lang files).
pub fn ore() -> ::yog_api::BlockDef {
::yog_api::BlockDef::new(Self::ORE)
.strength(3.0, 3.0)
.sound("minecraft:stone")
.light_level(4)
.requires_tool()
}
/// `gm:pipe` — `content/pipe.yblock`.
pub const PIPE: &'static str = "gm:pipe";
/// The definition from `content/pipe.yblock` (name and tooltip come from the lang files).
pub fn pipe() -> ::yog_api::BlockDef {
::yog_api::BlockDef::new(Self::PIPE)
.shape(6.0, 6.0, 6.0, 10.0, 10.0, 10.0)
.connects_to_neighbors()
.connect_groups(&["gm:pipe"])
}
}
# content/items.g.rs
// <auto-generated>
// Generated by `yog build` from content/** — don't edit, it's rewritten
// on every build. Included by `yog_api::content!()`.
// </auto-generated>
/// The items of `content/`: the id and a [`::yog_api::ItemDef`] of each.
#[allow(dead_code)]
pub struct Items;
#[allow(dead_code, clippy::all)]
impl Items {
/// `gm:ruby` — `content/ruby.yitem`.
pub const RUBY: &'static str = "gm:ruby";
/// The definition from `content/ruby.yitem` (name and tooltip come from the lang files).
pub fn ruby() -> ::yog_api::ItemDef {
::yog_api::ItemDef::new(Self::RUBY)
}
}
# content/register.g.rs
// <auto-generated>
// Generated by `yog build` from content/** — don't edit, it's rewritten
// on every build. Included by `yog_api::content!()`.
// </auto-generated>
/// Registers every block and item of `content/` whose file doesn't say
/// `"register": "manual"` — `yog_api::content!()` calls it after
/// `Mod::register`.
#[allow(unused_variables)]
pub fn register(registry: &mut ::yog_api::Registry) {
registry.register_block(Blocks::glass());
registry.register_block(Blocks::ore());
registry.register_block(Blocks::pipe());
registry.register_item(Items::ruby());
}
// Runs when the mod's library loads: `export_mod!` calls `register` after
// `Mod::register`.
#[::yog_api::ctor::ctor(unsafe, crate_path = ::yog_api::ctor)]
fn __yog_content_auto_register() {
::yog_api::__yog_content_registrars()
.lock()
.unwrap_or_else(|e| e.into_inner())
.push(register);
}
# assets/gm/blockstates/glass.json
{
"variants": {
"": {
"model": "gm:block/glass"
}
}
}
# assets/gm/blockstates/ore.json
{
"variants": {
"": {
"model": "gm:block/ore"
}
}
}
# assets/gm/blockstates/pipe.json
{
"multipart": [
{
"apply": {
"model": "gm:block/pipe"
}
},
{
"apply": {
"model": "gm:block/pipe_arm"
},
"when": {
"north": "true"
}
},
{
"apply": {
"model": "gm:block/pipe_arm",
"y": 90
},
"when": {
"east": "true"
}
},
{
"apply": {
"model": "gm:block/pipe_arm",
"y": 180
},
"when": {
"south": "true"
}
},
{
"apply": {
"model": "gm:block/pipe_arm",
"y": 270
},
"when": {
"west": "true"
}
},
{
"apply": {
"model": "gm:block/pipe_arm",
"x": 270
},
"when": {
"up": "true"
}
},
{
"apply": {
"model": "gm:block/pipe_arm",
"x": 90
},
"when": {
"down": "true"
}
}
]
}
# assets/gm/items/glass.json
{
"model": {
"model": "gm:item/glass",
"type": "minecraft:model"
}
}
# assets/gm/items/ore.json
{
"model": {
"model": "gm:item/ore",
"type": "minecraft:model"
}
}
# assets/gm/items/pipe.json
{
"model": {
"model": "gm:item/pipe",
"type": "minecraft:model"
}
}
# assets/gm/items/ruby.json
{
"model": {
"model": "gm:item/ruby",
"type": "minecraft:model"
}
}
# assets/gm/lang/en_us.json
{
"block.gm.glass": "Clear Glass",
"block.gm.ore": "Ruby Ore",
"item.gm.ruby": "Ruby"
}
# assets/gm/models/block/glass.json
{
"parent": "minecraft:block/cube_all",
"render_type": "minecraft:cutout",
"textures": {
"all": "minecraft:block/glass"
}
}
# assets/gm/models/block/ore.json
{
"parent": "minecraft:block/cube_all",
"textures": {
"all": "minecraft:block/redstone_ore"
}
}
# assets/gm/models/block/pipe.json
{
"elements": [
{
"faces": {
"north": {
"texture": "#0"
}
},
"from": [
6,
6,
6
],
"to": [
10,
10,
10
]
}
],
"parent": "minecraft:block/block",
"render_type": "minecraft:cutout",
"textures": {
"0": "minecraft:block/stone",
"particle": "minecraft:block/stone"
}
}
# assets/gm/models/block/pipe_arm.json
{
"elements": [
{
"faces": {
"up": {
"texture": "#0"
}
},
"from": [
6,
6,
0
],
"to": [
10,
10,
6
]
}
],
"parent": "minecraft:block/block",
"render_type": "minecraft:cutout",
"textures": {
"0": "minecraft:block/stone",
"particle": "minecraft:block/stone"
}
}
# assets/gm/models/item/glass.json
{
"parent": "gm:block/glass"
}
# assets/gm/models/item/ore.json
{
"parent": "gm:block/ore"
}
# assets/gm/models/item/pipe.json
{
"parent": "gm:block/pipe"
}
# assets/gm/models/item/ruby.json
{
"parent": "minecraft:item/generated",
"textures": {
"layer0": "minecraft:item/emerald"
}
}
# data/gm/loot_table/blocks/ore.json
{
"pools": [
{
"conditions": [
{
"condition": "minecraft:survives_explosion"
}
],
"entries": [
{
"functions": [
{
"count": {
"max": 3,
"min": 1,
"type": "minecraft:uniform"
},
"function": "minecraft:set_count"
}
],
"name": "gm:ruby",
"type": "minecraft:item"
}
],
"rolls": 1
}
],
"type": "minecraft:block"
}
# data/gm/loot_table/blocks/pipe.json
{
"pools": [
{
"conditions": [
{
"condition": "minecraft:survives_explosion"
}
],
"entries": [
{
"name": "gm:pipe",
"type": "minecraft:item"
}
],
"rolls": 1
}
],
"type": "minecraft:block"
}
# data/minecraft/tags/block/mineable/pickaxe.json
{
"replace": false,
"values": [
"gm:ore"
]
}
# data/minecraft/tags/block/needs_iron_tool.json
{
"replace": false,
"values": [
"gm:ore"
]
}