Mods in den Spieleordner reingeschoben. So richtig tief.
This commit is contained in:
parent
b4b6c08f4f
commit
f7bc25a670
1674 changed files with 56056 additions and 530 deletions
12
mods/tt_armor/LICENSE.txt
Normal file
12
mods/tt_armor/LICENSE.txt
Normal file
|
@ -0,0 +1,12 @@
|
|||
MIT License
|
||||
|
||||
Copyright (c) 2024 adikalon
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
||||
|
||||
|
||||
Code by adikalon
|
9
mods/tt_armor/README.md
Normal file
9
mods/tt_armor/README.md
Normal file
|
@ -0,0 +1,9 @@
|
|||
# Extended Tooltips: Armor [`tt_armor`]
|
||||
|
||||
This is an addition to the [tt](https://codeberg.org/Wuzzy/minetest_tt)
|
||||
|
||||

|
||||
|
||||
## Description
|
||||
|
||||
Displays armor properties from 3d_armor mod
|
70
mods/tt_armor/init.lua
Normal file
70
mods/tt_armor/init.lua
Normal file
|
@ -0,0 +1,70 @@
|
|||
local S = minetest.get_translator(minetest.get_current_modname())
|
||||
|
||||
local function physics_recalculation(value)
|
||||
local new_value = math.floor(value * 100)
|
||||
|
||||
if new_value > 0 then
|
||||
new_value = "+" .. new_value
|
||||
end
|
||||
|
||||
return new_value
|
||||
end
|
||||
|
||||
tt.register_snippet(function(itemstring)
|
||||
local def = minetest.registered_items[itemstring]
|
||||
local desc
|
||||
local armor_heal = def.groups.armor_heal
|
||||
local armor_use = def.groups.armor_use
|
||||
local armor_fire = def.groups.armor_fire
|
||||
local armor_water = def.groups.armor_water
|
||||
local armor_feather = def.groups.armor_feather
|
||||
local physics_speed = def.groups.physics_speed
|
||||
local physics_gravity = def.groups.physics_gravity
|
||||
local physics_jump = def.groups.physics_jump
|
||||
|
||||
if def.armor_groups then
|
||||
desc = S("Armor")
|
||||
|
||||
if armor_heal then
|
||||
desc = desc .. "\n" .. S("Protection: @1%", math.floor(armor_heal))
|
||||
end
|
||||
|
||||
if armor_use then
|
||||
desc = desc .. "\n" .. S("Strength: @1", math.floor(65535 / armor_use))
|
||||
end
|
||||
|
||||
if armor_fire then
|
||||
desc = desc .. "\n" .. S("Fire: @1", armor_fire)
|
||||
end
|
||||
|
||||
if armor_water then
|
||||
desc = desc .. "\n" .. S("Water protection")
|
||||
end
|
||||
|
||||
if armor_feather then
|
||||
desc = desc .. "\n" .. S("Fall protection")
|
||||
end
|
||||
|
||||
if physics_speed then
|
||||
desc = desc .. "\n" .. S("Speed: @1%", physics_recalculation(physics_speed))
|
||||
end
|
||||
|
||||
if physics_gravity then
|
||||
desc = desc .. "\n" .. S("Gravity: @1%", physics_recalculation(physics_gravity))
|
||||
end
|
||||
|
||||
if physics_jump then
|
||||
desc = desc .. "\n" .. S("Jump: @1%", physics_recalculation(physics_jump))
|
||||
end
|
||||
|
||||
if def.damage_groups then
|
||||
desc = desc .. "\n" .. S("Protected groups:")
|
||||
|
||||
for key, value in pairs(def.damage_groups) do
|
||||
desc = desc .. "\n- " .. key ..": " .. value
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
return desc
|
||||
end)
|
12
mods/tt_armor/locale/tt_armor.ru.tr
Normal file
12
mods/tt_armor/locale/tt_armor.ru.tr
Normal file
|
@ -0,0 +1,12 @@
|
|||
# textdomain: tt_armor
|
||||
|
||||
Armor=Броня
|
||||
Protection: @1%=Защита: @1%
|
||||
Strength: @1=Прочность: @1
|
||||
Fire: @1=Огонь: @1
|
||||
Water protection=Защита от воды
|
||||
Fall protection=Защита при падении
|
||||
Speed: @1%=Скорость: @1%
|
||||
Gravity: @1%=Гравитация: @1%
|
||||
Jump: @1%=Прыжок: @1%
|
||||
Protected groups:=Защищаемые группы:
|
6
mods/tt_armor/mod.conf
Normal file
6
mods/tt_armor/mod.conf
Normal file
|
@ -0,0 +1,6 @@
|
|||
name = tt_armor
|
||||
title = Extended Tooltips: Armor
|
||||
description = Adds armor information
|
||||
depends = tt
|
||||
author = adikalon
|
||||
release = 27234
|
BIN
mods/tt_armor/screenshot.png
Normal file
BIN
mods/tt_armor/screenshot.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 41 KiB |
Loading…
Add table
Add a link
Reference in a new issue