Skip to content

Commit

Permalink
DP | Stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
Nik0-0 committed Aug 31, 2024
1 parent 0a20d85 commit 59fef45
Show file tree
Hide file tree
Showing 8 changed files with 46 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
$tellraw $(pl) "<gray> \u2139 | $(text)"
scoreboard players set __found_case__ __variable__ 1
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
$tellraw $(pl) "<yellow> \u26a0 | $(text)"
scoreboard players set __found_case__ __variable__ 1
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
$tellraw $(pl) "<red> \ud83d\uded1 | $(text)"
scoreboard players set __found_case__ __variable__ 1
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
$tellraw $(pl) "<dark_gray> \u2754 | $(text)"
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
$function nnb_main:__private__/switch_case/1/$(switch_key)
1 change: 1 addition & 0 deletions nnb_main/data/nnb_main/function/create_marker.mcfunction
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
function nnb_main:logger {"pl":"@s","ll":"1","text":"Generated sucessfully"}
$give @s minecraft:armor_stand[minecraft:entity_data={Invisible:true,Invulnerable:true,NoBasePlate:true,NoGravity:true,Small:true,CustomNameVisible:false,CustomName:'{"text":"$(Tag) Marker"}',DisabledSlots:4128768,Tags:["$(Tag)"],id:"minecraft:armor_stand"},minecraft:custom_name='{"text":"$(Tag) Marker"}'] 1
4 changes: 4 additions & 0 deletions nnb_main/data/nnb_main/function/logger.mcfunction
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
scoreboard players set __found_case__ __variable__ 0
execute store result storage nnb_main:__storage__ switch_key int 1 run scoreboard players get $ll __variable__
function nnb_main:__private__/switch_case/1/select with storage nnb_main:__storage__
execute unless score __found_case__ __variable__ matches 1 run function nnb_main:__private__/switch_case/1/default
35 changes: 33 additions & 2 deletions nnb_main/main.jmc
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,10 @@ function root() {



// -- Core Code



// lobby music manager
// 🎵 Music Manager
function lobby_music() {

if (nn_lobby:phase = 1) {
Expand Down Expand Up @@ -109,7 +109,38 @@ function lobby_music() {
}






// -- Executable tools







// Simple function to create marker
function create_marker() {
logger(pl="@s",ll="1",text="Generated sucessfully");
$give @s minecraft:armor_stand[minecraft:entity_data={Invisible:true,Invulnerable:true,NoBasePlate:true,NoGravity:true,Small:true,CustomNameVisible:false,CustomName:'{"text":"$(Tag) Marker"}',DisabledSlots:4128768,Tags:["$(Tag)"],id:"minecraft:armor_stand"},minecraft:custom_name='{"text":"$(Tag) Marker"}'] 1;
}



// Simple logger for logging & debug printed on chat
function logger() {

switch ($ll) {
case 1:
$Text.tellraw($(pl), "<gray> ℹ | $(text)");
case 2:
$Text.tellraw($(pl), "<yellow> ⚠ | $(text)");
case 3:
$Text.tellraw($(pl), "<red> 🛑 | $(text)");
default:
$Text.tellraw($(pl), "<dark_gray> ❔ | $(text)");
}

}

0 comments on commit 59fef45

Please sign in to comment.