Skip to content

Commit 416c297

Browse files
runcowsEpyonProjects
authored andcommitted
Lively Lily Pads 1.21.9 Feature Update (Gamemode4Dev#1181)
* Lively Lily Pads 1.21.9 * comments lie * Micro optimization
1 parent 0df0b72 commit 416c297

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

42 files changed

+568
-24
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
# stores mainhand item data
2+
# @s = player who right clicked on interaction holding a supported item
3+
# at @s
4+
# run from mechanics/interactions/placement/interact_rcd
5+
6+
scoreboard players set $mainhand gm4_llp.data 1
7+
8+
data modify storage gm4_llp:temp DisplayType set from entity @s SelectedItem.id
9+
10+
execute if items entity @s weapon.mainhand #gm4_lively_lily_pads:coral_fan run \
11+
scoreboard players set $item_type gm4_llp.data 1
12+
execute if items entity @s weapon.mainhand #gm4_lively_lily_pads:dead_coral_fan run \
13+
scoreboard players set $item_type gm4_llp.data 2
14+
execute if items entity @s weapon.mainhand minecraft:torch run \
15+
scoreboard players set $item_type gm4_llp.data 3
16+
execute if items entity @s weapon.mainhand minecraft:lantern run \
17+
scoreboard players set $item_type gm4_llp.data 4
18+
execute if items entity @s weapon.mainhand minecraft:soul_torch run \
19+
scoreboard players set $item_type gm4_llp.data 5
20+
execute if items entity @s weapon.mainhand minecraft:soul_lantern run \
21+
scoreboard players set $item_type gm4_llp.data 6
22+
execute if items entity @s weapon.mainhand #minecraft:candles run \
23+
scoreboard players set $item_type gm4_llp.data 7
24+
execute if items entity @s weapon.mainhand minecraft:cactus_flower run \
25+
scoreboard players set $item_type gm4_llp.data 8
26+
execute if items entity @s weapon.mainhand minecraft:redstone_torch run \
27+
scoreboard players set $item_type gm4_llp.data 9
28+
execute if items entity @s weapon.mainhand minecraft:spore_blossom run \
29+
scoreboard players set $item_type gm4_llp.data 10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
# stores offhand item data
2+
# @s = player who right clicked on interaction holding a supported item
3+
# at @s
4+
# run from mechanics/interactions/placement/interact_rcd
5+
6+
scoreboard players set $offhand gm4_llp.data 1
7+
8+
data modify storage gm4_llp:temp DisplayType set from entity @s equipment.offhand.id
9+
10+
execute if items entity @s weapon.offhand #gm4_lively_lily_pads:coral_fan run \
11+
scoreboard players set $item_type gm4_llp.data 1
12+
execute if items entity @s weapon.offhand #gm4_lively_lily_pads:dead_coral_fan run \
13+
scoreboard players set $item_type gm4_llp.data 2
14+
execute if items entity @s weapon.offhand minecraft:torch run \
15+
scoreboard players set $item_type gm4_llp.data 3
16+
execute if items entity @s weapon.offhand minecraft:lantern run \
17+
scoreboard players set $item_type gm4_llp.data 4
18+
execute if items entity @s weapon.offhand minecraft:soul_torch run \
19+
scoreboard players set $item_type gm4_llp.data 5
20+
execute if items entity @s weapon.offhand minecraft:soul_lantern run \
21+
scoreboard players set $item_type gm4_llp.data 6
22+
execute if items entity @s weapon.offhand #minecraft:candles run \
23+
scoreboard players set $item_type gm4_llp.data 7
24+
execute if items entity @s weapon.offhand minecraft:cactus_flower run \
25+
scoreboard players set $item_type gm4_llp.data 8
26+
execute if items entity @s weapon.offhand minecraft:redstone_torch run \
27+
scoreboard players set $item_type gm4_llp.data 9
28+
execute if items entity @s weapon.offhand minecraft:spore_blossom run \
29+
scoreboard players set $item_type gm4_llp.data 10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# returns 1 if max durability reached
2+
# @s = player holding axe
3+
# at @s
4+
# run from mechanics/interactions/waxed_copper_lantern/used_mainhand_axe
5+
6+
# EMPTY TO AVOID ERRORS
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# returns 1 if max durability reached
2+
# @s = player holding axe
3+
# at @s
4+
# run from mechanics/interactions/waxed_copper_lantern/used_offhand_axe
5+
6+
# EMPTY TO AVOID ERRORS

gm4_lively_lily_pads/beet.yaml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,16 @@
11
id: gm4_lively_lily_pads
22
name: Lively Lily Pads
3-
version: 3.0.X
3+
version: 3.1.X
44

55
data_pack:
66
load: .
7+
overlays:
8+
- formats:
9+
min_inclusive: 0
10+
max_inclusive: 81
11+
min_format: 0
12+
max_format: 81
13+
directory: backport_81
714

815
pipeline:
916
- gm4.plugins.extend.module

gm4_lively_lily_pads/data/gm4_lively_lily_pads/advancement/punch_candle_rcd.json renamed to gm4_lively_lily_pads/data/gm4_lively_lily_pads/advancement/punch_perma_rcd.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,14 +24,14 @@
2424
"entity": "this",
2525
"predicate": {
2626
"type": "minecraft:interaction",
27-
"nbt": "{Tags:[\"gm4_llp_candle_rcd\"]}"
27+
"nbt": "{Tags:[\"gm4_llp_perma_rcd\"]}"
2828
}
2929
}
3030
]
3131
}
3232
}
3333
},
3434
"rewards": {
35-
"function": "gm4_lively_lily_pads:mechanics/attacks/candle/hit_rcd"
35+
"function": "gm4_lively_lily_pads:mechanics/attacks/perma/hit_rcd"
3636
}
3737
}
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
{
2+
"criteria": {
3+
"requirement": {
4+
"trigger": "minecraft:player_interacted_with_entity",
5+
"conditions": {
6+
"player": [
7+
{
8+
"condition": "minecraft:entity_properties",
9+
"entity": "this",
10+
"predicate": {
11+
"type_specific": {
12+
"type": "minecraft:player",
13+
"gamemode": [
14+
"survival",
15+
"creative"
16+
]
17+
}
18+
}
19+
}
20+
],
21+
"entity": [
22+
{
23+
"condition": "minecraft:entity_properties",
24+
"entity": "this",
25+
"predicate": {
26+
"type": "minecraft:interaction",
27+
"nbt": "{Tags:[\"gm4_llp_unwaxed_copper_rcd\"]}"
28+
}
29+
}
30+
]
31+
}
32+
}
33+
},
34+
"rewards": {
35+
"function": "gm4_lively_lily_pads:mechanics/interactions/unwaxed_copper_lantern/interact_rcd"
36+
}
37+
}
Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
{
2+
"criteria": {
3+
"requirement": {
4+
"trigger": "minecraft:player_interacted_with_entity",
5+
"conditions": {
6+
"player": [
7+
{
8+
"condition": "minecraft:entity_properties",
9+
"entity": "this",
10+
"predicate": {
11+
"type_specific": {
12+
"type": "minecraft:player",
13+
"gamemode": [
14+
"survival",
15+
"creative"
16+
]
17+
}
18+
}
19+
}
20+
],
21+
"entity": [
22+
{
23+
"condition": "minecraft:entity_properties",
24+
"entity": "this",
25+
"predicate": {
26+
"type": "minecraft:interaction",
27+
"nbt": "{Tags:[\"gm4_llp_waxed_copper_rcd\"]}"
28+
}
29+
}
30+
]
31+
}
32+
}
33+
},
34+
"rewards": {
35+
"function": "gm4_lively_lily_pads:mechanics/interactions/waxed_copper_lantern/interact_rcd"
36+
}
37+
}

gm4_lively_lily_pads/data/gm4_lively_lily_pads/function/mechanics/attacks/candle/hit_rcd.mcfunction

Lines changed: 0 additions & 12 deletions
This file was deleted.
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# perma rcd hit, need to break
2+
# @s = player who left clicked on a perma rcd
3+
# at @s
4+
# run from advancement: punch_perma_rcd
5+
6+
advancement revoke @s only gm4_lively_lily_pads:punch_perma_rcd
7+
8+
# set creative flag
9+
execute if entity @s[gamemode=creative] run scoreboard players set $creative gm4_llp.data 1
10+
11+
# process attack
12+
execute as @e[type=interaction,tag=gm4_llp_perma_rcd,distance=..8] if data entity @s attack at @s run function gm4_lively_lily_pads:mechanics/attacks/perma/process_interaction

0 commit comments

Comments
 (0)