I did think about the spiritlink ability, but that only mitigates damage, it doens't heal. And this is more of a trigger than a spell.
The idea behind the trigger is this. You can go into houses by using the "move" command on the house, you are then moved to a seperate location on the map which is enclosed and has a "door". People can attack the house unit on the main map, when they kill the house on the main map, everything inside the house is pushed outside onto the map. All these triggers work fine, but what I want the person inside the house to be able to repair his house from the inside, thereby making it much harder for the person to break in. So what i was thinking, is to make a "door" unit inside the house, that the person could repair, thus effecting the house on the map. Does that make any sense?
What i have tried to do, which works, is use the "set life to value" trigger and use arithmatic to set both the door and the house's life to an average of both the house and the door. It works, but its messy. It looks something like this
Event -
unit is attacked
Condition -
Unit type of triggering unit equal to house
Unit type of triggering unit is in region house00 equal to true
Action -
-If-
Triggering unit life not equal to at least 99% health
-Then-
-set life of triggering unit = to (life of triggering unit + life of door) / 2
-set life of door = to (life of triggering unit + life of door) / 2
-run this trigger checking conditions
-Else-
-do nothing
This is as close to a solution as I could get, and its pretty dicey.
I am having some other issues with this map I am working on, with multiplayer drops and such. I have done alot of testing of the trigger with the test map function, but when i try to get multiple people in there, they all drop consistantly. If anyone is willing or interested in taking a look at what i have done, i would be appreciative.
The map itself is unlike anything I have played on battle.net. Its almost like a sim, 4 teams, trying to take control of a town. 4 teams are divided into 4 religions that are trying to convert the town, what ever team does the best job of spread their religion wins (exact winning conditions have not been banged out, but that is the gist). You convert the people of the town, and you can send them to perform different tasks for your religion, you can send them to your temple to worship you (there by gaining your teams hero EXP) or you can send them to a house to work for you and earn you money as well as have kids, and finaly you can send them to the barracks to get armed in order to fight off or attack other religions. You can even go into other player's temples and slaughter their worshipers, thereby cutting off their exp, or you can go around destroying their houses, cutting off their population and growth. And all onto of this, there are different ranking citizens you can convert. It is very in depth and there is room for numerous amount of strat to be involved, especialy since you are working with 2 other team-mates.
Anyways, if that sounds at all interesting to anyone, or if anyone is interested in helping me with triggers i would be very greatful!