feat: owlaunch
This commit is contained in:
7
README.md
Normal file
7
README.md
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
# mc-commands
|
||||||
|
|
||||||
|
Various minecraft commands that compiles into one command via [Haskell One-Command Generator](https://git.walruslab.org/mincomk/onecommand-hs)
|
||||||
|
|
||||||
|
## List
|
||||||
|
|
||||||
|
- [OW Launch](/owlaunch): Fly straight with right-click
|
||||||
15
owlaunch/README.md
Normal file
15
owlaunch/README.md
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
# OW Launch
|
||||||
|
|
||||||
|
Fly straight with right-click
|
||||||
|
|
||||||
|
## Getting an Item
|
||||||
|
|
||||||
|
Run the command to get an item.
|
||||||
|
|
||||||
|
```
|
||||||
|
tag @s add o.w.l.getitem
|
||||||
|
```
|
||||||
|
|
||||||
|
## Usage
|
||||||
|
|
||||||
|
Right click the item to fly.
|
||||||
12
owlaunch/fly.mcf
Normal file
12
owlaunch/fly.mcf
Normal file
@@ -0,0 +1,12 @@
|
|||||||
|
!REPEATING
|
||||||
|
|
||||||
|
tag @a[tag=!o.w.l.done] add o.w.l.iter
|
||||||
|
|
||||||
|
|
||||||
|
execute as @e[tag=o.w.l.cloud] if score @s o.w.l.cloud = @e[limit=1,tag=o.w.l.iter] o.w.l.puid run tag @e[tag=o.w.l.iter] add o.w.launch
|
||||||
|
|
||||||
|
|
||||||
|
tag @e[tag=o.w.l.iter,limit=1] add o.w.l.done
|
||||||
|
tag @e remove o.w.l.iter
|
||||||
|
|
||||||
|
execute unless entity @a[tag=!o.w.l.done] run tag @e remove o.w.l.done
|
||||||
4
owlaunch/get.mcf
Normal file
4
owlaunch/get.mcf
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
!REPEATING
|
||||||
|
|
||||||
|
give @a[tag=o.w.l.getitem] minecraft:feather[consumable={consume_seconds:0.01, has_consume_particles:false, animation:"none", sound: "minecraft:ui.toast.in"}, enchantment_glint_override=true, custom_data={role:"o.w.l.fly"}, custom_name={text:"Shoot",italic:false,color:"aqua"}, max_stack_size=1]
|
||||||
|
tag @e remove o.w.l.getitem
|
||||||
7
owlaunch/init.mcf
Normal file
7
owlaunch/init.mcf
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
!REPEATING
|
||||||
|
|
||||||
|
scoreboard objectives add o.w.l.internal dummy
|
||||||
|
scoreboard objectives add o.w.l.puid dummy
|
||||||
|
scoreboard objectives add o.w.l.cloud dummy
|
||||||
|
scoreboard objectives add o.w.l.timer dummy
|
||||||
|
scoreboard objectives add o.w.l.used minecraft.used:minecraft.feather
|
||||||
18
owlaunch/launch.mcf
Normal file
18
owlaunch/launch.mcf
Normal file
@@ -0,0 +1,18 @@
|
|||||||
|
!REPEATING
|
||||||
|
|
||||||
|
execute as @e[tag=o.w.launch] if entity @s[gamemode=survival] run scoreboard players set $gm o.w.l.internal 0
|
||||||
|
execute as @e[tag=o.w.launch] if entity @s[gamemode=creative] run scoreboard players set $gm o.w.l.internal 1
|
||||||
|
execute as @e[tag=o.w.launch] if entity @s[gamemode=adventure] run scoreboard players set $gm o.w.l.internal 2
|
||||||
|
execute as @e[tag=o.w.launch] if entity @s[gamemode=spectator] run scoreboard players set $gm o.w.l.internal 3
|
||||||
|
|
||||||
|
execute as @e[tag=o.w.launch] run gamemode creative @s
|
||||||
|
execute as @e[tag=o.w.launch] at @s run tp ~ ~10000 ~
|
||||||
|
execute as @e[tag=o.w.launch] at @s anchored eyes positioned ^ ^ ^-4 summon minecraft:end_crystal run damage @s 0
|
||||||
|
execute as @e[tag=o.w.launch] at @s run tp ~ ~-10000 ~
|
||||||
|
|
||||||
|
execute as @e[tag=o.w.launch] if score $gm o.w.l.internal matches 0 run gamemode survival @s
|
||||||
|
execute as @e[tag=o.w.launch] if score $gm o.w.l.internal matches 1 run gamemode creative @s
|
||||||
|
execute as @e[tag=o.w.launch] if score $gm o.w.l.internal matches 2 run gamemode adventure @s
|
||||||
|
execute as @e[tag=o.w.launch] if score $gm o.w.l.internal matches 3 run gamemode spectator @s
|
||||||
|
|
||||||
|
tag @e remove o.w.launch
|
||||||
6
owlaunch/puid.mcf
Normal file
6
owlaunch/puid.mcf
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
!REPEATING
|
||||||
|
|
||||||
|
execute as @a[tag=!o.w.l.puid] run scoreboard players add #counter o.w.l.puid 1
|
||||||
|
execute as @a[tag=!o.w.l.puid] run scoreboard players operation @s o.w.l.puid = #counter o.w.l.puid
|
||||||
|
execute as @a[tag=!o.w.l.puid] run tellraw @s [{text:"[",color:"white",bold:false}, {"text":"INFO",color:"green",bold:true}, {text:"]",color:"white",bold:false}, {"text":" New PUID assigned for you: ",color:"white",bold:false}, {score:{name:"@s",objective:"o.w.l.puid"},color:"blue"}]
|
||||||
|
execute as @a[tag=!o.w.l.puid] run tag @s add o.w.l.puid
|
||||||
4
owlaunch/timer.mcf
Normal file
4
owlaunch/timer.mcf
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
!REPEATING
|
||||||
|
|
||||||
|
execute as @e[tag=o.w.l.cloud] run scoreboard players add @s o.w.l.timer 1
|
||||||
|
execute as @e[tag=o.w.l.cloud] if score @s o.w.l.timer matches 15.. run kill @s
|
||||||
7
owlaunch/trigger.mcf
Normal file
7
owlaunch/trigger.mcf
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
!REPEATING
|
||||||
|
|
||||||
|
execute as @e[tag=o.w.l.trigger] run summon minecraft:marker 0 0 0 {Tags:["o.w.l.cloud-init"]}
|
||||||
|
execute as @e[tag=o.w.l.cloud-init] store result score @s o.w.l.cloud run scoreboard players get @e[limit=1,tag=o.w.l.trigger] o.w.l.puid
|
||||||
|
tag @e[tag=o.w.l.cloud-init,limit=1] add o.w.l.cloud
|
||||||
|
tag @e remove o.w.l.trigger
|
||||||
|
tag @e remove o.w.l.cloud-init
|
||||||
5
owlaunch/use.mcf
Normal file
5
owlaunch/use.mcf
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
!REPEATING
|
||||||
|
|
||||||
|
execute as @a if score @s o.w.l.used matches 1.. if items entity @s weapon.* minecraft:feather[minecraft:custom_data={role:"o.w.l.fly"}] run tag @s add o.w.l.trigger
|
||||||
|
execute as @e[tag=o.w.l.trigger] at @s run playsound minecraft:entity.wind_charge.wind_burst player @a ~ ~ ~ 1 1.1
|
||||||
|
scoreboard players set @e o.w.l.used 0
|
||||||
Reference in New Issue
Block a user