-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
increase weight reducer of "previous_trials" logic for random attacks (…
…#61)
- Loading branch information
1 parent
9769770
commit 377434d
Showing
2 changed files
with
12 additions
and
10 deletions.
There are no files selected for viewing
8 changes: 4 additions & 4 deletions
8
...flowey/data/entity/functions/hostile/omega-flowey/attack/random/attack_phase/0.mcfunction
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,10 @@ | ||
## Initializes a random attack for entities (`boss_fight`) with `boss-fight.attack.phase.i` == 0 | ||
|
||
# Set influences to defaults for attack_phase 0 | ||
scoreboard players set #attack-friendliness-pellets attack.weight 2 | ||
scoreboard players set #attack-homing-vines attack.weight 2 | ||
scoreboard players set #attack-x-bullets-lower attack.weight 2 | ||
scoreboard players set #attack-x-bullets-upper attack.weight 2 | ||
scoreboard players set #attack-friendliness-pellets attack.weight 3 | ||
scoreboard players set #attack-homing-vines attack.weight 3 | ||
scoreboard players set #attack-x-bullets-lower attack.weight 3 | ||
scoreboard players set #attack-x-bullets-upper attack.weight 3 | ||
|
||
# Run base `start` function | ||
function entity:hostile/omega-flowey/attack/random/start |
14 changes: 8 additions & 6 deletions
14
...flowey/data/entity/functions/hostile/omega-flowey/attack/random/reduce_weights.mcfunction
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,20 @@ | ||
## Reduce weight of attack if it was just ran | ||
execute if entity @s[tag=attack.random.previous_attack.dentata-snakes] run scoreboard players remove #attack-dentata-snakes attack.weight 1 | ||
scoreboard players set @s attack.weight 2 | ||
|
||
execute if entity @s[tag=attack.random.previous_attack.dentata-snakes] run scoreboard players operation #attack-dentata-snakes attack.weight -= @s attack.weight | ||
execute if entity @s[tag=attack.random.previous_attack.dentata-snakes] run tag @s remove attack.random.previous_attack.dentata-snakes | ||
|
||
execute if entity @s[tag=attack.random.previous_attack.finger-guns] run scoreboard players remove #attack-finger-guns attack.weight 1 | ||
execute if entity @s[tag=attack.random.previous_attack.finger-guns] run scoreboard players operation #attack-finger-guns attack.weight -= @s attack.weight | ||
execute if entity @s[tag=attack.random.previous_attack.finger-guns] run tag @s remove attack.random.previous_attack.finger-guns | ||
|
||
execute if entity @s[tag=attack.random.previous_attack.friendliness-pellets] run scoreboard players remove #attack-friendliness-pellets attack.weight 1 | ||
execute if entity @s[tag=attack.random.previous_attack.friendliness-pellets] run scoreboard players operation #attack-friendliness-pellets attack.weight -= @s attack.weight | ||
execute if entity @s[tag=attack.random.previous_attack.friendliness-pellets] run tag @s remove attack.random.previous_attack.friendliness-pellets | ||
|
||
execute if entity @s[tag=attack.random.previous_attack.homing-vines] run scoreboard players remove #attack-homing-vines attack.weight 1 | ||
execute if entity @s[tag=attack.random.previous_attack.homing-vines] run scoreboard players operation #attack-homing-vines attack.weight -= @s attack.weight | ||
execute if entity @s[tag=attack.random.previous_attack.homing-vines] run tag @s remove attack.random.previous_attack.homing-vines | ||
|
||
execute if entity @s[tag=attack.random.previous_attack.x-bullets-lower] run scoreboard players remove #attack-x-bullets-lower attack.weight 1 | ||
execute if entity @s[tag=attack.random.previous_attack.x-bullets-lower] run scoreboard players operation #attack-x-bullets-lower attack.weight -= @s attack.weight | ||
execute if entity @s[tag=attack.random.previous_attack.x-bullets-lower] run tag @s remove attack.random.previous_attack.x-bullets-lower | ||
|
||
execute if entity @s[tag=attack.random.previous_attack.x-bullets-upper] run scoreboard players remove #attack-x-bullets-upper attack.weight 1 | ||
execute if entity @s[tag=attack.random.previous_attack.x-bullets-upper] run scoreboard players operation #attack-x-bullets-upper attack.weight -= @s attack.weight | ||
execute if entity @s[tag=attack.random.previous_attack.x-bullets-upper] run tag @s remove attack.random.previous_attack.x-bullets-upper |