Skip to content

Commit

Permalink
DP | Testing Testing
Browse files Browse the repository at this point in the history
  • Loading branch information
Nik0-0 committed Aug 31, 2024
1 parent 309f484 commit 759adaf
Show file tree
Hide file tree
Showing 7 changed files with 22 additions and 17 deletions.
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
$tellraw $(pl) "<gray> \u2139 | $(text)"
$tellraw @s "<gray> \u2139 | $(text)"
scoreboard players set __found_case__ __variable__ 1
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
$tellraw $(pl) "<yellow> \u26a0 | $(text)"
$tellraw @s "<yellow> \u26a0 | $(text)"
scoreboard players set __found_case__ __variable__ 1
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
$tellraw $(pl) "<red> \ud83d\uded1 | $(text)"
$tellraw @s "<red> \ud83d\uded1 | $(text)"
scoreboard players set __found_case__ __variable__ 1
Original file line number Diff line number Diff line change
@@ -1 +1 @@
$tellraw $(pl) "<dark_gray> \u2754 | $(text)"
$tellraw @s "<dark_gray> \u2754 | $(text)"
2 changes: 1 addition & 1 deletion nnb_main/data/nnb_main/function/create_marker.mcfunction
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
function nnb_main:logger {"pl":"@s","ll":"1","text":"Generated sucessfully"}
function nnb_main:s_logger {"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,DisabledSlots:4128768,Tags:["$(Tag)"],id:"minecraft:armor_stand"},minecraft:custom_name='{"text":"$(Tag) Marker"}'] 1
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
execute store result score $v_ll __variable__ run $(ll)
scoreboard players set __found_case__ __variable__ 0
execute store result storage nnb_main:__storage__ switch_key int 1 run scoreboard players get $v_ll __variable__
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
26 changes: 16 additions & 10 deletions nnb_main/main.jmc
Original file line number Diff line number Diff line change
Expand Up @@ -123,24 +123,30 @@ function lobby_music() {

// Simple function to create marker
function create_marker() {
logger(pl="@s",ll="1",text="Generated sucessfully");
s_logger(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,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() {
$v_ll = $(ll);
switch ($v_ll) {





// -- Loggers


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

}

0 comments on commit 759adaf

Please sign in to comment.