Garry's Mod

Garry's Mod

83 个评价
[TTT] Lucky Horseshoe (Passive Perk)
   
奖励
收藏
已收藏
取消收藏
素材类型: 插件
插件标签: 快乐, 角色扮演
文件大小
发表于
更新日期
34.780 KB
2016 年 3 月 22 日 上午 10:22
2020 年 7 月 11 日 上午 2:15
25 项改动说明 ( 查看 )

订阅以下载
[TTT] Lucky Horseshoe (Passive Perk)

在 Zaratusa 的 1 个合集中
Zaratusa's TTT Server Addons
12 件物品
描述
NOTICE: This Addon only works for the TTT (Trouble in Terrorist Town) - Gamemode.
For TTT2 (Trouble in Terrorist Town 2) use this version of the Lucky Horseshoe.


Features
The Lucky Horseshoe is a passive item for Traitors and Detectives (configurable via ConVars), which decreases the taken fall damage by 90% and the remaining damage is limited to a maximum of 35 damage. After you've bought the item in the shop, an icon shows up on the left hand side of your screen to indicate, that the perk is active.

Includes an individual .vmt and .vtf shop icon.



Damage Examples
Without horseshoe: You take 100 damage, so you are dead.
With horseshoe: You take 90% less, so it's 10 damage.

Without horseshoe: You take 400 damage, so you are definetly dead.
With horsehoe: You take 90% less, that's 40 damage, but because it's limited, you take 35 damage.

ConVars
# Should Detectives be able to buy the Lucky Horseshoe? ttt_luckyhorseshoe_detective [0/1] (default: 1) # Should Detectives have it in their Loadout? ttt_luckyhorseshoe_detective_loadout [0/1] (default: 0) # Should Traitors be able to buy the Lucky Horseshoe? ttt_luckyhorseshoe_traitor [0/1] (default: 1) # Should Traitors have it in their Loadout? ttt_luckyhorseshoe_traitor_loadout [0/1] (default: 0)

Note: After changing these values, you have to restart your map/server.

Server Infos
Add it to your server by following this guide: Workshop for Dedicated Servers[wiki.facepunch.com]
Use Automatic Workshop Download so all client automatically download the required content.

Note: You may encounter the following console message, which can be ignored: "Refusing to load ttt_lucky_horseshoe because it is missing Type and Base keys!"

Translation
The available translation keys are "lucky_horseshoe_name" and "lucky_horseshoe_desc".
See the official Translation Documentation[www.troubleinterroristtown.com].

Source
The whole source code can be found on GitHub[github.com], feel free to contribute.

Thanks for reading, enjoy and have fun!
3 条留言
|UGA|PatPeter 2020 年 10 月 21 日 下午 5:12 
Is there a fix for this?

[[TTT] Lucky Horseshoe (Passive Perk)] gamemodes/terrortown/entities/entities/ttt_lucky_horseshoe/shared.lua:21: attempt to index a
nil value
1. unknown - gamemodes/terrortown/entities/entities/ttt_lucky_horseshoe/shared.lua:21
2. include - [C]:-1
3. unknown - gamemodes/terrortown/entities/entities/ttt_lucky_horseshoe/init.lua:9
E I K O 2016 年 11 月 22 日 下午 1:12 
Thats good, gonna add it to my collection if the other owner agrees :)
Zaratusa  [作者] 2016 年 11 月 22 日 上午 10:14 
Changed the description and added damage examples!