Cra-Zy's Avatar
Member
Level 20 Expert Architect
12

Forum Posts

1 - 20 of 48

    1
    10/11/2022 7:07 pm
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    as in, with commands? or base game vanilla without any help of commands?
    1
    02/07/2022 3:04 am
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    Solved, turns out the snow golem was able to detect the zombie, but wouldn't attack him because he was invulnerable, snow golem started attacking once I removed the invulnerable tag
    2
    08/09/2021 6:31 am
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    yeah, no you're absolutely right.
    I've been scratching my head about this for days. just now I realised the simple mistake.

    I fixed it by replacing the command to:

    execute unless block ~ ~ ~ #turret:rc_blockpass run function turret:collision

    thanks for helping me out tho, appreciate it!
    1
    08/09/2021 6:17 am
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    Yeah, I tried to implement that with the command:

    execute as @e[dx=0] at @s unless block ~ ~ ~ air run function turret:collision

    this executes unless the block it is in is air. since I also made a tag list including blocks it can pass through (like crops and flowers)

    except that command doesn't seem to be working whatsoever, it never executes while the ray does stop because of collision with a block...
    1
    08/09/2021 5:46 am
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    So basically what I have above would be the third function, the loop.

    But then without the command to run the collision function, that should then be in the second function?

    Sorry I'm trying to follow. Like I get that at the first you activate, position and detect the Ray. Which calls for a second, where you said to run commands once, don't fully get what I should put there, and then the second calls the third which is the actual ray that I can follow by for example a particle effect, and it should go on till it reaches a block/entity (or in my case also if it reached 100 blocks) do I call for the colission function in the second function? Or is the second function what will happen if the Ray hits a target?
    1
    08/09/2021 5:07 am
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    So you mean I should call for the collision function in the first function, after the command that calls for the cast?

    (so basically function one: cast from eyes, run function 2. Run function 3. Function 2, the loop, that goes on till the destination is hit.)

    Issue with that, is that it would always fire the third function, even if the Ray hasn't hit any blocks or entities.

    Or isn't that what you meant?
    1
    02/14/2021 8:21 am
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    Thank you for your response!
    I tried out your code, and I have to say: it works! my code was pretty sloppy I'm aware, but this just broke my brain a little xD

    Only thing that didn't work, was the singular selection, it still selects all the boxes in the 5 block distance, it seems like the limit and sort function don't really do anything... which is odd


    Click to reveal
    1
    02/13/2021 12:08 pmhistory
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    Oh that's smart! Very smart, I'm gonna test this tomorrow, think this might actually work!

    EDIT: it works! simply putting it in reverse order made it actually cycle instead of just plowing through all commands in a single tick, thanks for your advice!
    1
    02/12/2021 3:40 pm
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    Yeah! The hammer is supposed to rotate or change the block (basically the hammer right click makes the merge command execute)
    1
    02/12/2021 12:21 pm
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    See it as an armor stand holding a acacia trapdoor in its hand, the trapdoor has a custom model data,

    the scoreboard HammerUse keeps track of people using a carrot on a stick, cuz a carrot on a stick isn't specific I remodeled it into a hammer and I made the command check if the player close to the armor stand actually holds the hammer instead of a regular carrot on a stick (otherwise any carrot on a stick would work here and that's kinda against the point).

    Then I give the armor stand a tag (cycle) and if the player holding the "hammer" uses the hammer (HammerUse score) the nearest arnorstand detects that and runs a merge command that changes the acacia_trapdoor to another model (or rotates the armor stand for different sides)

    When the merge command activates it also changes the tags with the merge, so a armor stand with the tag cycle1, gets the tag cycle2 so next time it'll cycle to the next position/model

    But the code I use doesn't really work, it goes to the last cycle (cycle 11) and then just stops... I think it is because the function runs in order, which means after the first merge command (cycle1 to cycle2) it runs the second merge command (cycle2 to cycle3) and so on till it hits the bottom and resets the score.

    Putting the reset command at the beginning doesn't do anything since it's runned before the merge command gets executed

    Sooo I'm at a loss how to do this atm😢😅 only solution I would see is sperating every merge command as its own seperate function but that would take a lot of space
    1
    02/12/2021 9:19 am
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    thnx! this worked! however i did find another problem, when I tested this I realized it merges the model to the current score, so whenever i would walk past another box that box would also merge (new closest box).

    So I thought I'd make it cycle based on tags, and each merge would change the tag:

    code:
    # Acacia mb -> none
    execute as @a[scores={HammerUse=1}] run execute at @e[tag=Acacia,tag=cycle1,sort=nearest,limit=1] at @s if entity @p[distance=..5,scores={HammerUse=1},nbt={SelectedItem:{id:"minecraft:carrot_on_a_stick",tag:{CustomModelData:2018}}}] run data merge entity @e[tag=Acacia,tag=cycle1,sort=nearest,limit=1] {Tags:["Acacia",cycle2],ArmorItems:[{},{},{},{id:"minecraft:air",Count:1b}]}


    # Acacia none -> 1b
    execute as @a[scores={HammerUse=1}] run execute at @e[tag=Acacia,tag=cycle2,sort=nearest,limit=1] at @s if entity @p[distance=..5,scores={HammerUse=1},nbt={SelectedItem:{id:"minecraft:carrot_on_a_stick",tag:{CustomModelData:2018}}}] run data merge entity @e[tag=Acacia,tag=cycle2,sort=nearest,limit=1] {Tags:["Acacia","cycle3"],ArmorItems:[{},{},{},{id:"minecraft:acacia_trapdoor",Count:1b,tag:{CustomModelData:1003}}]}

    execute as @a[scores={HammerUse=1}] run execute at @e[tag=Acacia,tag=cycle3,sort=nearest,limit=1] at @s if entity @p[distance=..5,scores={HammerUse=1},nbt={SelectedItem:{id:"minecraft:carrot_on_a_stick",tag:{CustomModelData:2018}}}] run data merge entity @e[tag=Acacia,tag=cycle3,sort=nearest,limit=1] {Tags:["Acacia","cycle4"],ArmorItems:[{},{},{},{id:"minecraft:acacia_trapdoor",Count:1b,tag:{CustomModelData:1003}}],Rotation:[90f]}

    execute as @a[scores={HammerUse=1}] run execute at @e[tag=Acacia,tag=cycle4,sort=nearest,limit=1] at @s if entity @p[distance=..5,scores={HammerUse=1},nbt={SelectedItem:{id:"minecraft:carrot_on_a_stick",tag:{CustomModelData:2018}}}] run data merge entity @e[tag=Acacia,tag=cycle4,sort=nearest,limit=1] {Tags:["Acacia","cycle5"],ArmorItems:[{},{},{},{id:"minecraft:acacia_trapdoor",Count:1b,tag:{CustomModelData:1003}}],Rotation:[180f]}

    execute as @a[scores={HammerUse=1}] run execute at @e[tag=Acacia,tag=cycle5,sort=nearest,limit=1] at @s if entity @p[distance=..5,scores={HammerUse=1},nbt={SelectedItem:{id:"minecraft:carrot_on_a_stick",tag:{CustomModelData:2018}}}] run data merge entity @e[tag=Acacia,tag=cycle5,sort=nearest,limit=1] {Tags:["Acacia","cycle6"],ArmorItems:[{},{},{},{id:"minecraft:acacia_trapdoor",Count:1b,tag:{CustomModelData:1003}}],Rotation:[270f]}


    # Acacia 1b -> 2b
    execute at @a[scores={HammerUse=1}] run execute as @e[tag=Acacia,tag=cycle6,sort=nearest,limit=1] at @s if entity @p[distance=..5,scores={HammerUse=1},nbt={SelectedItem:{id:"minecraft:carrot_on_a_stick",tag:{CustomModelData:2018}}}] run data merge entity @e[tag=Acacia,tag=cycle6,sort=nearest,limit=1] {Tags:["Acacia","cycle7"],ArmorItems:[{},{},{},{id:"minecraft:acacia_trapdoor",Count:1b,tag:{CustomModelData:1004}}],Rotation:[0f]}

    execute at @a[scores={HammerUse=1}] run execute as @e[tag=Acacia,tag=cycle7,sort=nearest,limit=1] at @s if entity @p[distance=..5,scores={HammerUse=1},nbt={SelectedItem:{id:"minecraft:carrot_on_a_stick",tag:{CustomModelData:2018}}}] run data merge entity @e[tag=Acacia,tag=cycle7,sort=nearest,limit=1] {Tags:["Acacia","cycle8"],ArmorItems:[{},{},{},{id:"minecraft:acacia_trapdoor",Count:1b,tag:{CustomModelData:1004}}],Rotation:[90f]}

    execute at @a[scores={HammerUse=1}] run execute as @e[tag=Acacia,tag=cycle8,sort=nearest,limit=1] at @s if entity @p[distance=..5,scores={HammerUse=1},nbt={SelectedItem:{id:"minecraft:carrot_on_a_stick",tag:{CustomModelData:2018}}}] run data merge entity @e[tag=Acacia,tag=cycle8,sort=nearest,limit=1] {Tags:["Acacia","cycle9"],ArmorItems:[{},{},{},{id:"minecraft:acacia_trapdoor",Count:1b,tag:{CustomModelData:1004}}],Rotation:[180f]}

    execute at @a[scores={HammerUse=1}] run execute as @e[tag=Acacia,tag=cycle9,sort=nearest,limit=1] at @s if entity @p[distance=..5,scores={HammerUse=1},nbt={SelectedItem:{id:"minecraft:carrot_on_a_stick",tag:{CustomModelData:2018}}}] run data merge entity @e[tag=Acacia,tag=cycle9,sort=nearest,limit=1] {Tags:["Acacia","cycle10"],ArmorItems:[{},{},{},{id:"minecraft:acacia_trapdoor",Count:1b,tag:{CustomModelData:1004}}],Rotation:[270f]}


    # Acacia 2b -> 4b
    execute at @a[scores={HammerUse=1}] run execute as @e[tag=Acacia,tag=cycle10,sort=nearest,limit=1] at @s if entity @p[distance=..5,scores={HammerUse=1},nbt={SelectedItem:{id:"minecraft:carrot_on_a_stick",tag:{CustomModelData:2018}}}] run data merge entity @e[tag=Acacia,tag=cycle10,sort=nearest,limit=1] {Tags:["Acacia","cycle11"],ArmorItems:[{},{},{},{id:"minecraft:acacia_trapdoor",Count:1b,tag:{CustomModelData:1005}}],Rotation:[0f]}


    # Acacia 4b -> mb
    execute at @a[scores={HammerUse=1}] run execute as @e[tag=Acacia,tag=cycle11,sort=nearest,limit=1] at @s if entity @p[distance=..5,scores={HammerUse=1},nbt={SelectedItem:{id:"minecraft:carrot_on_a_stick",tag:{CustomModelData:2018}}}] run data merge entity @e[tag=Acacia,tag=cycle11,sort=nearest,limit=1] {Tags:["Acacia","cycle1"],ArmorItems:[{},{},{},{id:"minecraft:acacia_trapdoor",Count:1b,tag:{CustomModelData:1002}}]}

    scoreboard players reset @a HammerUse

    i fear this has to do due that scoreboard resets the score at the end so it scrolls through all of the merges.... but adding the reset command to the top or in-between each line also doesn't do anything... how do I fix this?

    (also also, am i allowed to add this as comment here or do I need to make a new topic about this problem? :p)
    1
    12/18/2020 5:16 pm
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    of course! if you can share your model with me then ill glady make it into a resource pack
    1
    12/18/2020 5:15 pm
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    hahaha then im sorry mate, i probably wont be any better then you are, good luck anyways :D
    1
    12/14/2020 2:45 pm
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    made, so i suppose you don't have the textures you wish added?
    i'm not a legend in the art department, i shine more in the coding of datapacks or creations of 3d models.
    1
    11/06/2020 12:02 pm
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    sorry hadnt seen your post, eehm honestly i could do some research about it, i do think its possible since there are datapacks that do add world generation. so ill get back at ya as soon as i have an answer :p
    1
    09/21/2020 4:45 pm
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    this seems pretty easy and doable to me.
    There might be an easier way, but what im thinking is making a datapack, add a Loottable for all the mobs, which will basically be copy pasting the same one over and over again by every mob. which is a bit of a braindead and boring task. but the outcome would work.
    You'd have 2 loottables, 1 with brown mushrooms, you can make it multiple drops if you like (https://www.youtube.com/watch?v=SFOGmKZ-jXs&t=177s) and 1 just empty, because you dont want hostile mobs to follow their default loot table

    Next step would then be making brown mushrooms edible, which is easy since you can detect it when someone right clicks with a specific item. that would trigger a heal effect and you'd be done.

    Honestly this idea is very doable and not at all difficult, and i'd like to challenge you :p You said you were gonna try and do it yourself.
    Iam not saying you'd have to succeed, but at least try, let me know how far you came and ill finish it. ( that way you get to learn datapacks a bit too :p)

    Is that okay?
    1
    09/21/2020 4:25 pm
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    this is such an awesome idea, there might be a way for me to do this, however, for the idea to work optifine would be required.

    Dyou have discord so we can discuss this there?
    2
    09/21/2020 1:47 pm
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    http://www.mediafire.com/file/vwx2hi0020me5lp/file there ya go, its on iron armor, if you want the icons to be different as well, just ask and you'll receive :p
    2
    09/18/2020 8:17 am
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    i mean... i could detach the armor and make a resource pack out of literally that :p sure
    2
    09/21/2020 1:47 pm
    Level 20 : Expert Architect
    Cra-Zy
    Cra-Zy's Avatar
    http://www.mediafire.com/file/vwx2hi0020me5lp/file there ya go, its on iron armor, if you want the icons to be different as well, just ask and you'll receive :p

1 - 20 of 48

Planet Minecraft

Website

© 2010 - 2024
www.planetminecraft.com

Welcome