- Saved searches
- Use saved searches to filter your results more quickly
- License
- DaveHJT/Damage-Minecraft-Squid-Workshop-Project
- Name already in use
- Sign In Required
- Launching GitHub Desktop
- Launching GitHub Desktop
- Launching Xcode
- Launching Visual Studio Code
- Latest commit
- Git stats
- Files
- README.md
- About
- Текстурпак Custom Damage Colors
- Установка Custom Damage Colors (.mcpack)
- Custom Damage Colors [128x]
- Custom Damage Colors
- Note from Creator
Saved searches
Use saved searches to filter your results more quickly
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session.
A minecraft library for custom instant damage.
License
DaveHJT/Damage-Minecraft-Squid-Workshop-Project
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Name already in use
A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Sign In Required
Please sign in to use Codespaces.
Launching GitHub Desktop
If nothing happens, download GitHub Desktop and try again.
Launching GitHub Desktop
If nothing happens, download GitHub Desktop and try again.
Launching Xcode
If nothing happens, download Xcode and try again.
Launching Visual Studio Code
Your codespace will open once ready.
There was a problem preparing your codespace, please try again.
Latest commit
Git stats
Files
Failed to load latest commit information.
README.md
Squid Workshop’s Damage Data Pack
A minecraft datapack library for a custom damage system, including custom death message and pvp kills count.
As we all know, custom damage has always been a pain for datapack developers, since minecraft only provided very high level API such as instant_damage, poison and wither effects,bu the damage amount cannot be customized, and these effects cannot be accumulated in a single tick. The only low level API that can be accessed by commands—-attribute, is useful for editing mobs’ health, but the health attribute of player is read-only.
The only working type of custom damage datapack I have seen on the internet is by replacing the equipment on player with another equipment that the attributes are modified, so that these attributes can overwrite the health related attributes of the player. I’m not sure it is exactly how it works, but this solution needs to set a container(chest) in the minecraft world to store the equipments of player temporarily, which is hacky.
I used to use a custom damage datapack like this but it no longer works in minecraft 1.16.5, so I decided to develop a more elegant solution here.
- Step 1 Download this repository as a zip and unpack.
- Step 2 Go to minecraft saves directory, usually «C:/Users/youUserName/AppData/Roaming/.minecraft/saves».
- Step 3 Choose the world folder in which you want to install the packs.
- Step 4 Go to . /world/datapacks folder.
- Step 5 Move your «Damage-Datapack-Squid-Workshop-1.16.5» folder(not the root folder) into . /world/datapacks folder.
- Step 6 Open Minecraft and open the world.
- Step 7 Type «/reload» command then press enter.
- Step 8 Enjoy
PS: If not working, check whether the datapack is enabled by:
/datapack enable "datapackname"
/scoreboard players add @s damage 10
Datapack developers might want to read this part.
PS: To make the custom death message and PVP kills count work in teams, you need to manually set the «team» scores of the players in the same team the same. Team score of 0 means no team.
eg. PLAYER1 and PLAYER2 are teammates, PLAYER3 is in another team, PLAYER4 and PLAYER5 didn’t join any team.
/scoreboard players set PLAYER1 team 1 /scoreboard players set PLAYER2 team 1 /scoreboard players set PLAYER3 team 2 /scoreboard players set PLAYER4 team 0 /scoreboard players set PLAYER5 team 0
When the damage score is added, you should do these to enable custom death message:
- Tag the damage taker the tags in list below to trigger special message.
- Assign the damage taker’s hit_by score by the damage applyer’s UID(unique player ID created by this datapack) to identify the killer if the player is killed by this damage.
eg. PLAYER1 is hit by PLAYER2 by grenade.
#sign name scoreboard players operation PLAYER1 hit_by = PLAYER2 UID #special tags tag PLAYER1 add grenaded
Condition | Death Message |
---|---|
default | @s was killed under @p[tag=killer]’s gunfire |
suicide | That was a suicide |
teamkill | @p[tag=killer] just killed their teammate |
guess killer | @p[tag=killer] claimed that kill |
tag=exploded | @s was blown up by @p[tag=killer] |
tag=turreted | @s was shot by @p[tag=killer]’s turret |
tag=molotoved | @s was burnt to death by @p[tag=killer]’s molotov |
tag=grenaded | @s was blown up by @p[tag=killer]’s grenade |
Welcome to contribute to this datapack by adding more tag/message pairs! See CONTRIBUTIING.md
The datapack counts all the pvp kills by both original damage system and this custom damage system. The scores are in scoreboard «Kills». Rules:
- If suicide, your Kills score will be reduced by 1.
- If killing another player that the «team» score is not 0 and it’s the same as you, you killed a teammate and your Kills score will be reduced by 1.
- If killed by custom damage but «hit_by» score is not assigned to the damage applyer’s UID, the system guess you are killed by the nearest player(no team > different team > teammate).
- In minecraft command system (mcfunction), we can use:
- /data to modify the health of mobs directly, we use this method in this datapack, but player’s Health nbt attribute is read-only.
- /atrribute to modify the max health of player, theoratically it can be used to clamp the player’s health to a specific lower amount. However, the max health attribute is only updated at the end of the tick, so we need two ticks for editing player’s health, and any health boost in the first tick will be dropped, this method is not practical.
- /effect instant_damage to deal damage within a tick, but this high level API also does the following things:
- disable the instant damage effect to player in about 9 ticks
- can only do one instant damage effect per rick, if multiple effects are applied, only the strongest is reserved. So I tried to use recursion in code and failed
- can only deal damge of the multiple of 6, eg. 6, 12 ,24, 48.
- Hence we used the combination of instant damage, absorption effects to deal damage over 2. The combinations are in «damage:classes/damage/enum» folder, there are 2, 4, 6, 8, 12, 16, 20, 24.
- The damage score is accumulated, and the damage is dealt every 9 ticks(for the effect cooldown), the max damage in enum folder that is less than the damage score is chosen. The damage left to be dealt is carried to 9 ticks later.
- If the damage score is 1, we uses poison effect, and tag the player a «poison_buffer» during the time that poison damage is not dealt yet. If another 1 damage arrives, we cancel the poison effect and buffer and add the 2×1 damage together, so it can be dealt instantly.
- Every tick we check the combination of damage score and the 1 damage pending in poison buffer, that wheter the damage left to be dealt can kill the player, if so, we kill the player instantly using /kill command, and starts the death message procedure and pvp kills count procedure mentioned above. So that all the kills by this damage system will always go through the kill procedure, the effects only hurts the player and never kills directly.
See here for our standard datapack structure and how this structure works.
Damage-Datapack-Squid-Workshop-1.16.5/ │ pack.mcmeta │ pack.png │ └─data ├─app │ └─functions │ ├─help │ │ damage.mcfunction │ │ │ ├─settings │ │ ├─boss_difficulty │ │ │ default.mcfunction │ │ │ hard.mcfunction │ │ │ medium.mcfunction │ │ │ │ │ └─guess_killer │ │ disable.mcfunction │ │ enable.mcfunction │ │ │ └─unload │ damage.mcfunction │ ├─damage │ ├─functions │ │ └─classes │ │ ├─damage │ │ │ │ apply_poison.mcfunction │ │ │ │ clear_damage_timer.mcfunction │ │ │ │ clear_poison_buffer.mcfunction │ │ │ │ combine_poison_buffer.mcfunction │ │ │ │ damage1_poison.mcfunction │ │ │ │ deal_damage.mcfunction │ │ │ │ deal_damage_mob.mcfunction │ │ │ │ hurt.mcfunction │ │ │ │ hurt_until_damage1.mcfunction │ │ │ │ kill.mcfunction │ │ │ │ remove_death_tag.mcfunction │ │ │ │ update_uid.mcfunction │ │ │ │ │ │ │ └─enum │ │ │ 12.mcfunction │ │ │ 16.mcfunction │ │ │ 2.mcfunction │ │ │ 20.mcfunction │ │ │ 24.mcfunction │ │ │ 32.mcfunction │ │ │ 4.mcfunction │ │ │ 48.mcfunction │ │ │ 6.mcfunction │ │ │ 8.mcfunction │ │ │ 96.mcfunction │ │ │ │ │ └─main │ │ clean.mcfunction │ │ load.mcfunction │ │ tick.mcfunction │ │ │ └─tags │ └─entity_types │ boss.json │ mob.json │ notmob.json │ undead.json │ └─minecraft └─tags └─functions load.json
- This datapack uses absorption effect as helper, so that adding the damage score to any entity(player or mobs) that has absorption or poison effect may cause:
- less damage than the damage score is dealt
- the absorption or poison effect might be cleared
- Instant damage effect is disabled in few seconds after player respawn, this invincibility is minecraft’s feature, so we keeps it as our feature.
- Using other datapacks not from Squid Workshop that contains the same scoreboard or tags name as this datapack in code may cause undefined behaviour.
Feel free to play around with this datapack.
As developer, deel free to use this datapack as a module to develop free datapacks.
But you must add the link to this github page!
NO COMMERCIAL USEMore About Squid Workshop
See more datapacks developed by us here
Watch our videos on bilibili here
Join our QQ group: 74681732
Subscribe on wechat: 鱿鱼MC工作室About
A minecraft library for custom instant damage.
Текстурпак Custom Damage Colors
Если Вам надоело видеть одни и те же цвета при нанесении или получении урона в Майнкрафте, воспользуйтесь пакетом текстур «Custom Damage Colors (Пользовательские цвета урона)»! С ним у Вас появится большой выбор цветов, в которые окрашивается сущность при получении урона.
- Красный;
- Оранжевый;
- Желтый;
- Зеленый;
- Синий;
- Фиолетовый;
- Черный;
- Белый;
- Радужный;
- Бесцветный.
Текстурпак работает как глобальное дополнение, т.е. цвета изменятся как в Вашем собственном мире Minecraft, так и в других, включая Realms и серверы. Розовые текстуры.
Желтые текстуры.
С радужным вариантом каждый новый удар будет окрашиваться в другой цвет.
Установка Custom Damage Colors (.mcpack)
- Скачайте текстурпак с пометкой — «.mcpack» ниже.
Custom Damage Colors [128x]
The old red damage overlay when you lose health that makes you feel bored? That’s a great resource pack for you. You will see the damage overlay color off all entities with a wide array of different colors
Cre: ambient, Youtube
Custom Damage Colors
You can choose between either default: Red – Orange – Yellow – Green – Blue – Purple – Black – White – Rainbow or No damage color
This resource pack works both in your own world and in others. It includes realm and servers
Pink Overlay
Yellow overlay
Green Overlay
Note from Creator
- To change the subpacks, you likely have to reload your game.
- The render controllers for the Ender Dragon, Squids, and Horses are hardcoded. it means the creator doesn’t have the ability to edit how they render in-game on the client.
- The damage overlay will always be the default red color for the entities
- Only works on Bedrock Edition 1.16.0+
- Contact:
- xbox: ambiennt
- discord: ambient#2309
If you want more texture packs, you can refer below:
- Tags
- 128x
- 128×128
- 32x
- custom damage color 128×128
- custom damage colors
- custom damage colors 128x
- texture
- texture 32×32
- texture mcpe
- texture minecraft
- texture pack
- texture pack 128×128