Explorar o código

苦力怕基础修改:允许揍玩家,调整各种细节

龙腾猫跃 %!s(int64=3) %!d(string=hai) anos
pai
achega
445ef0e3a8

+ 2 - 1
data/mini/functions/ass/game/give_creeper.mcfunction

@@ -1,7 +1,8 @@
 clear @s creeper_spawn_egg{game_item:1b}
+scoreboard players set @s countdown_fast -1
 
 # 返还格子上的物品
 execute if data entity @s Inventory[{Slot:-106b}] run scoreboard players set @s item_slot -106
 execute if data entity @s Inventory[{Slot:-106b}] at @s run function item:pop_slot/return_item
 
-item replace entity @s weapon.offhand with creeper_spawn_egg{game_item:1b,display:{Name:'{"text":"苦力怕刷怪蛋","italic":false}'},EntityTag:{CustomName:'',ignited:1b,Fuse:34s,AbsorptionAmount:1000},CanPlaceOn:["#mini:creeper_block"],HideFlags:16} 1
+item replace entity @s weapon.offhand with creeper_spawn_egg{game_item:1b,display:{Name:'{"text":"苦力怕刷怪蛋","color":"aqua","italic":false}'},EntityTag:{CustomName:'',ignited:1b,Fuse:34s,AbsorptionAmount:1000},CanPlaceOn:["#mini:creeper_block"],HideFlags:16} 1

+ 1 - 1
data/mini/functions/ass/game/give_stick.mcfunction

@@ -4,4 +4,4 @@ clear @s stick{game_item:1b}
 execute if data entity @s Inventory[{Slot:8b}] run scoreboard players set @s item_slot 8
 execute if data entity @s Inventory[{Slot:8b}] at @s run function item:pop_slot/return_item
 
-item replace entity @s hotbar.8 with stick{game_item:1b,display:{Name:'{"text":"击退棒","italic":false}'},Enchantments:[{id:"knockback",lvl:2}]} 1
+item replace entity @s hotbar.8 with stick{game_item:1b,display:{Name:'{"text":"击退棒","color":"aqua","italic":false}'},Enchantments:[{id:"knockback",lvl:2}],AttributeModifiers:[{UUID:[I;2,0,2,1],Amount:39.01,AttributeName:"generic.attack_damage",Name:"attack",Slot:"mainhand",Operation:0}],HideFlags:63}

+ 1 - 1
data/mini/functions/ass/game/use_creeper.mcfunction

@@ -2,5 +2,5 @@
 scoreboard players set @s countdown_fast 20
 scoreboard players reset @s creeperUse
 
-# 清除三叉戟以防bug
+# 清除刷怪蛋以防bug
 clear @s creeper_spawn_egg{game_item:1b}

+ 1 - 1
data/mini/functions/ass/game_init.mcfunction

@@ -12,7 +12,7 @@ setblock 1000 4 7000 air
 
 # 伤害管理
 scoreboard players set $remove_resistance mem 1
-team modify playing friendlyFire false
+team modify playing friendlyFire true
 team modify playing collisionRule always
 team modify playing deathMessageVisibility always
 gamerule naturalRegeneration false

+ 2 - 2
data/mini/functions/ass/game_start.mcfunction

@@ -1,12 +1,12 @@
 # 游戏结束倒计时
-scoreboard players set $countdown mem 100
+scoreboard players set $countdown mem 90
 
 # HUD
 scoreboard objectives setdisplay list health_disp
 scoreboard objectives setdisplay belowName health_disp
 scoreboard objectives setdisplay sidebar health_disp
 scoreboard players set $bossbar_color mem 3
-scoreboard players set $countdown_max mem 100
+scoreboard players set $countdown_max mem 90
 scoreboard players set $bossbar_type mem 2
 function lib:bossbar/show
 bossbar set mini:green name "剩余时间"

+ 1 - 0
data/mini/functions/ass/give_effect.mcfunction

@@ -3,3 +3,4 @@ effect clear @s
 effect give @s saturation 1000000 0 true
 effect give @s resistance 1000000 2 true
 effect give @s night_vision 1000000 0 true
+effect give @s weakness 1000000 9 true

+ 1 - 0
data/mini/functions/ass/player_death.mcfunction

@@ -7,4 +7,5 @@ tp @s[team=!debugging] 1032.34 27.11 7032.84 461.44 28.30
 # tellraw @a ["",{"text": ">> ","color":"red","bold": true},{"selector": "@s","color":"red"}," 已死亡!"]
 execute as @a at @s run function lib:sounds/error
 function mini:main/player_failed
+execute if score $player_alive mem matches ..2 run effect clear @a resistance
 # execute unless entity @a[tag=mini_running] run function mini:main/game_end

+ 1 - 2
data/mini/functions/ass/player_enter.mcfunction

@@ -10,9 +10,8 @@ function mini:ass/give_effect
 attribute @s generic.max_health base set 20
 gamerule naturalRegeneration false
 
-
 # 计分板重置
-scoreboard players set @s countdown_fast 50
+scoreboard players set @s countdown_fast 10
 scoreboard players set @s creeperUse 0
 
 # 传送玩家

+ 1 - 1
data/mini/functions/ass/player_intro.mcfunction

@@ -1,5 +1,5 @@
 # 向单个玩家展示小游戏介绍
 tp @s[team=!debugging] 1022.29 21.49 7009.34 42.30 42.15
 effect give @s night_vision 1000000 0 true
-tellraw @s ["",{"text":"\n >> 核爆刺客 >>\n\n","color":"gold","bold":true}," 用刷怪蛋 ",{"text":"召唤苦力怕炸死对方!","color":"gold"},"\n 使用最后一格的击退棒来击飞苦力怕!\n\n",{"text": " <无法攻击玩家> ","color":"red"},"\n"]
+tellraw @s ["",{"text":"\n >> 核爆刺客 >>\n\n","color":"gold","bold":true}," 用刷怪蛋 ",{"text":"召唤苦力怕炸死对方!","color":"gold"},"\n 最后一格的击退棒能击飞苦力怕和玩家!\n\n",{"text": " <只能击退玩家> ","color":"yellow"},"\n"]
 tellraw @s ""

+ 2 - 3
data/mini/functions/ass/tick2.mcfunction

@@ -1,8 +1,7 @@
 # 使用苦力怕刷怪蛋调用函数
-execute as @a[tag=mini_running] if score @s creeperUse matches 1.. run function mini:ass/game/use_creeper
-
+execute as @a[tag=mini_running,scores={creeperUse=1..}] run function mini:ass/game/use_creeper
 # 给予苦力怕刷怪蛋
-execute as @a[tag=mini_running] unless data entity @s Inventory[{Slot:-106b,id:"minecraft:creeper_spawn_egg",tag:{game_item:1b}}] unless score @s countdown_fast matches 1.. run function mini:ass/game/give_creeper
+execute as @a[tag=mini_running,scores={countdown_fast=0}] unless data entity @s Inventory[{Slot:-106b,id:"minecraft:creeper_spawn_egg",tag:{game_item:1b}}] run function mini:ass/game/give_creeper
 
 # 给予击退棒
 execute as @a[tag=mini_running] unless data entity @s Inventory[{Slot:8b,id:"minecraft:stick",tag:{game_item:1b}}] run function mini:ass/game/give_stick

+ 2 - 2
data/mini/functions/ass/tick20.mcfunction

@@ -9,5 +9,5 @@ execute if score $countdown mem matches 1 as @a at @s run function lib:sounds/dr
 execute if score $countdown mem matches ..0 run effect give @a[team=playing] wither 60 1 true
 
 # 回复生命值
-execute if score $countdown mem matches 1.. if score $player_alive mem matches 3.. if score $foursec mem matches 1 if score $foursec mem matches 1 run effect give @a[team=playing] regeneration 1 10 true
-execute if score $countdown mem matches 1.. if score $player_alive mem matches 3.. if score $foursec mem matches 1 run schedule function mini:ass/game/clear_effect 1t replace
+execute if score $countdown mem matches 1.. if score $foursec mem matches 1 if score $foursec mem matches 1 run effect give @a[team=playing] regeneration 1 10 true
+execute if score $countdown mem matches 1.. if score $foursec mem matches 1 run schedule function mini:ass/game/clear_effect 1t replace

+ 1 - 1
data/mini/functions/colormatch/player_intro.mcfunction

@@ -1,4 +1,4 @@
 # 向单个玩家展示小游戏介绍
 tp @s[team=!debugging] 1062.78 22.00 4019.40 178.41 40.03
-tellraw @s ["",{"text":"\n >> 色彩迷阵 >>\n\n","color":"gold","bold":true}," 站在 ",{"text":"与墙壁相同的方块","color":"gold"}," 上!\n 倒计时结束时, 与墙壁不相同的地板都会消失!\n\n",{"text": " <可以击退玩家> ","color":"red"},"\n"]
+tellraw @s ["",{"text":"\n >> 色彩迷阵 >>\n\n","color":"gold","bold":true}," 站在 ",{"text":"与墙壁相同的方块","color":"gold"}," 上!\n 倒计时结束时, 与墙壁不相同的地板都会消失!\n\n",{"text": " <只能击退玩家> ","color":"yellow"},"\n"]
 effect give @s night_vision 1000000 0 true

+ 1 - 1
data/mini/functions/hotpm/player_intro.mcfunction

@@ -1,4 +1,4 @@
 # 向单个玩家展示小游戏介绍
 tp @s[team=!debugging] 1029 15 3007.77 -290.29 32.65
-tellraw @s ["",{"text":"\n >> 炸弹狂魔 >>\n\n","color":"gold","bold":true}," 炸弹会在一段时间后爆炸!\n 在持有炸弹时, 只要 ",{"text":"攻击其他人","color":"gold"}," 就能把炸弹甩给他!\n 努力存活下来吧!\n\n",{"text": " <可以击退玩家> ","color":"red"},"\n"]
+tellraw @s ["",{"text":"\n >> 炸弹狂魔 >>\n\n","color":"gold","bold":true}," 炸弹会在一段时间后爆炸!\n 在持有炸弹时, 只要 ",{"text":"攻击其他人","color":"gold"}," 就能把炸弹甩给他!\n 努力存活下来吧!\n\n",{"text": " <只能击退玩家> ","color":"yellow"},"\n"]
 effect give @s night_vision 1000000 0 true

+ 1 - 1
data/mini/functions/parkour/player_intro.mcfunction

@@ -1,3 +1,3 @@
 # 向单个玩家展示小游戏介绍
 tp @s[team=!debugging] 1010.96 26.83 1032.37 -385.24 16.67
-tellraw @s ["",{"text":"\n >> 遗迹寻宝 >>\n\n","color":"gold","bold":true}," 以最快速度 ",{"text":"冲向终点","color":"gold"}," 即可获胜!\n 但慢慢前进, 收集沿途隐藏的宝藏也不错……\n\n",{"text": " <无法攻击玩家> ","color":"red"},"\n"]
+tellraw @s ["",{"text":"\n >> 遗迹寻宝 >>\n\n","color":"gold","bold":true}," 以最快速度 ",{"text":"冲向终点","color":"gold"}," 即可获胜!\n 但慢慢前进, 收集沿途隐藏的宝藏也不错……\n\n",{"text": " <无法攻击玩家> ","color":"green"},"\n"]

+ 1 - 1
data/mini/functions/phantom/game_init.mcfunction

@@ -8,7 +8,7 @@ scoreboard players reset * kill_phantom
 scoreboard players reset * kill_phantom2
 
 # 调整时间
-time set 21000t
+time set 21200t
 
 # 生成地图
 setblock 1000 4 6000 minecraft:structure_block[mode=load]{metadata:"",mirror:"NONE",ignoreEntities:1b,powered:0b,seed:0L,author:"LTCat",rotation:"NONE",posX:0,mode:"LOAD",posY:1,sizeX:32,posZ:0,integrity:1.0f,showair:0b,name:"mini:hy00",sizeY:32,sizeZ:32,showboundingbox:0b}

+ 2 - 2
data/mini/functions/phantom/game_start.mcfunction

@@ -1,12 +1,12 @@
 gamerule doDaylightCycle true
-scoreboard players set $countdown mem 110
+scoreboard players set $countdown mem 100
 
 # HUD
 scoreboard objectives setdisplay list health_disp
 scoreboard objectives setdisplay belowName health_disp
 scoreboard objectives setdisplay sidebar kill_phantom
 scoreboard players set $bossbar_color mem 4
-scoreboard players set $countdown_max mem 110
+scoreboard players set $countdown_max mem 100
 scoreboard players set $bossbar_type mem 2
 function lib:bossbar/show
 bossbar set mini:blue name "剩余时间"

+ 1 - 1
data/mini/functions/phantom/player_intro.mcfunction

@@ -1,4 +1,4 @@
 # 向单个玩家展示小游戏介绍
 tp @s[team=!debugging] 1062.34 27.11 6040.84 461.44 28.30
-tellraw @s ["",{"text":"\n >> 月夜狩猎 >>\n\n","color":"gold","bold":true}," 投掷无限供应的三叉戟 ",{"text":"尽量击杀幻翼","color":"gold"}," 吧!\n 击杀发光的幻翼会掉落奖励物品哦!\n\n",{"text": " <无法攻击玩家> ","color":"red"},"\n"]
+tellraw @s ["",{"text":"\n >> 月夜狩猎 >>\n\n","color":"gold","bold":true}," 投掷无限供应的三叉戟 ",{"text":"尽量击杀幻翼","color":"gold"}," 吧!\n 击杀发光的幻翼会掉落奖励物品哦!\n\n",{"text": " <无法攻击玩家> ","color":"green"},"\n"]
 tellraw @s ""

+ 1 - 1
data/mini/functions/tntrun/player_intro.mcfunction

@@ -1,4 +1,4 @@
 # 向单个玩家展示小游戏介绍
 tp @s[team=!debugging] 1023.65 20.29 2006.59 -345.99 17.34
 effect give @s[team=!debugging] night_vision 1000000 0 true
-tellraw @s ["",{"text":"\n >> 地陷圣坛 >>\n\n","color":"gold","bold":true}," 你脚踩的方块会自然消失!\n 不要停下, 保持移动, 只要 ",{"text":"不掉下场地","color":"gold"}," 即可获胜!\n\n",{"text": " <可以击退玩家> ","color":"red"},"\n"]
+tellraw @s ["",{"text":"\n >> 地陷圣坛 >>\n\n","color":"gold","bold":true}," 你脚踩的方块会自然消失!\n 不要停下, 保持移动, 只要 ",{"text":"不掉下场地","color":"gold"}," 即可获胜!\n\n",{"text": " <只能击退玩家> ","color":"yellow"},"\n"]

+ 1 - 1
data/mini/functions/trade/player_intro.mcfunction

@@ -2,4 +2,4 @@
 tp @s[team=!debugging] 1013.47 247.63 5045.62 -178.86 17.18
 worldborder set 1000000
 effect give @s[team=!debugging] night_vision 1000000 0 true
-tellraw @s ["",{"text":"\n >> 贸易专家 >>\n\n","color":"gold","bold":true}," 手持最后一格的交易契约, 即可召唤村民。\n 与村民进行交易, 成为 ",{"text":"绿宝石最多","color":"gold"}," 的玩家吧!\n\n",{"text": " <生存模式> ","color":"aqua"},{"text": " <无法攻击玩家> ","color":"red"},"\n"]
+tellraw @s ["",{"text":"\n >> 贸易专家 >>\n\n","color":"gold","bold":true}," 手持最后一格的交易契约, 即可召唤村民。\n 与村民进行交易, 成为 ",{"text":"绿宝石最多","color":"gold"}," 的玩家吧!\n\n",{"text": " <生存模式> ","color":"aqua"},{"text": " <无法攻击玩家> ","color":"green"},"\n"]