Starbound

File information

Last updated

Original upload

Created by

lornlynx

Uploaded by

lornlynx

Virus scan

Safe to use

Tags for this mod

About this mod

craftable machine that heals player automatically

Permissions and credits
Changelogs
This mod is outdated and won't be updated any more due to several reasons (unless by popular demand). Thank you all for feedback!

Adds a craftable machine that heals players in the proximity.
The target is to give players a balanced and useful method to heal health without much interaction.
Now also heals NPCs!
Therefore the machine allows faster and "resourceless" healing with the limitation of being only
stationary and having an intern energy pool.
Uses can range from being fast health replenish in your secure base to uses in actual combat to withstand longer fights.


How it works:
You only have to stand nearby and will automatically be healed.
The machine uses a unique energy pool, which is shown on the front in form of a 4 part slice window.
Each pulse heals the player for roughly 10% of his max. health and depletes some energy, pulses have
a cooldown, which means that you have to wait some time before the next health patch will be distributed.
A full energy pool will heal you to your full health in a few seconds, if you use it continuously though then the energy pool will refill too slowly and the pulses will come slower.
It works similar to the Team Fortress 2 Dispenser if that tells you something.
http://gfycat.com/LimpFixedJackrabbit

Also the health you gain scales roughly with your health pool. This means in detail that for every full 100 health you have, one pulse will heal you for 10 health more. So, if you have 135 health, one pulse heals you for 10 health, if you have 376, one will heal you for 30 health. This allows the machine to be used across multiple armor tiers effectively. It isn't exactly 10% as you've probably noticed, but I am too limited by the current API, but it's better than nothing.

As you can see in the last 4 pictures, even after changing to a 300 health armor, one pulse still heals me for roughly 10%.

Where you get it:
You can craft it at the robotic crafting table for 200 pixels, 10 smooth metal, 15 nanowrap bandages, 40 wires, 15 goldbars and 20 steelbars.
It is a Tier 2 recipe, so be sure that you have unlocked these first!

Important details:
Sadly, it can occasionally heal monsters. This happens mostly when they run into you and knock you back. This is something I can not change right at the moment. This is because I can't target players health values directly through the API, something I hope they will be adding in the future.
BUT I built in a feature so that you can decide yourself how you want to have it. By default the machine also distributes healing to your character when monsters are around. But you can press E on it, to change it so it no longer allows monsters. This is confirmed by a sound, and when pressing E to change it back it is again confirmed by a different sound. When you switch it to the other mode, it won't distribute healing when monster are standing by the machine, so you don't accidentally heal them, but you also won't be healed until you knocked them away.
http://gfycat.com/FewBadIaerismetalmark
Also, it does not work on the ship! This is because you can't spawn projectiles on the ship, which seems to be a built in limitation. I also hope that we get a possibility to change this in the future, otherwise if you know a method to make projectiles spawn also on ships, please tell me!
It should work in multiplayer now, if it doesn't please tell me again!

How to change to default healing sound:
If you don't like the Half Life Charger sound you can easily change it back to the default healing sound of Starbound.
Just go into your Starbound/mods/HealthDispenser/ folder, find the "healthDispenserProj1.projectile" file and open it.
Now find the line ("kind" : "halflifehealth",) and change it to ("kind" : "health",) , without the () for sure. Leave the rest the same and save the file.
Then search the "healthDispenser129175.lua" file, open it as well, and search for the following codelines, which are starting at line 81 till line 83:
if self.energy > 90 then
entity.playSound("dispenserStartSound")
end
Either outcomment them, or if you don't know how to do that just delete them. Save the file again at the end.
Now you'll get the default healing sound again when using the health dispenser!


I hope you enjoy this little gimmick. If you have any suggestions or found any bugs, please tell me, I will gladly read them and consider their usefulness! Any criticism is also highly desired! HF!