Can anyone come up with a better way to do a passive repair ability?[Solved]

To put the problem as briefly as possible, I'd like to have a passive ability apply a buffOverTimeActionType restore hull, so the repair effect will show up on the info card. However, while this sucseeded in displaying the repair effect, it actually didn't do anything to heal the ships it was targetting, so I've had to rework the ability to do an instant action RestoreHullPoints (via a periodic action), which works but it doesn't display on the info card, so your enemies would have no idea the target was getting healed.

So does anyone have a better solution, or is it impossible for me to show off my cake and have it too? :P

6,150 views 11 replies
Reply #1 Top

Uhm... How in the world does that not work? o_O

Should be as simple as apply buff to self (Or to target) and a buff with the over time repair.

 

:fox:

Reply #2 Top

I think it's because of the pasive aspect and the fact that since it repairs hull it become inative when hull points reaches full and doesnt recycle. I think what you need is a trigger event for it. Would need to be able to set the trigger to activate when x dmg has be done to hull and deactivate when hull recheases y amount just before be full health with a condition reset at the end of the script. The problem is, is there even condition/even/trigger code in sins to allow to script this? I think the best bet for this would be safety overide protocle for the TEC SB that self destruc it's self. The ability can be placed on auto-cast, never actuly tested to see if it would work on it's own. But if it does and was scripted to activate it's self when the starbace recheases x health then you could use that code to script your event. You'll only be a reset script to retriger the into active status when the conditions are met again.

But don't take my word down for it. I only played witht he game code a little bit. Only enought to know what I needed to know. But hope this helps you search for the key you are missing for what you need.

Reply #3 Top

Make a self buff that inflicts one point of damage and then the damage can be the trigger for the repair?

Reply #4 Top

Quoting Kitkun, reply 1
Uhm... How in the world does that not work?

Should be as simple as apply buff to self (Or to target) and a buff with the over time repair.
 
End of Kitkun's quote

Perhaps I should of mentioned that this particular ability is on a strikecraft squadron, so "ApplyBuffToSelf" isn't an option sadly. And yes that's what I thought to0, but despite clearly getting the buff applied to them, no repair is actually done with buffOverTimeActionType restore hull. I tested it by setting natural repair to zero and it healing 100 hull per second, and while it said Repairng 100 hull/sec on the info card, any damage they took was permanent. That is until they were effected by repair cloud, which worked just fine. ;P

@Ead: I don't think that's the reason. Repair abilities should continue even after you reach 100%, and if you are damaged again while the buff is still being applied you'll still get healed.

Quoting SIN-Imperium, reply 3
Make a self buff that inflicts one point of damage and then the damage can be the trigger for the repair?
End of SIN-Imperium's quote

Well that might work, though it will make the info card even more confusing. "Damage Taken: 1" "Hull Repair 2/sec".

Reply #5 Top

Lol--who said it was elegant?

Reply #6 Top

Oh, explains a lot. Put it on the owning ship and have it apply to the strikecraft. Like Rapture's Concentration Aura.

 

:fox:

Reply #7 Top

Quoting Kitkun, reply 6
Oh, explains a lot. Put it on the owning ship and have it apply to the strikecraft. Like Rapture's Concentration Aura.

End of Kitkun's quote

I was going to do that if I couldn't get it to work at all, but the fact that it works as an instant action is what's really stumping me now. As you said, its pretty bizarre that it doesn't really work as overtime.

Reply #8 Top

instant repeat action.

Reply #9 Top

If anyone is curious, I ended up putting both the overtime action and periodic action on the same buff. The periodic action did the work while the overtime action still did nothing but it displayed correctly on the info card. Not sure why it didn't occur to me earlier, but it now works exactly how I want it to.

Reply #10 Top

Can you show us (me) the completed result?  I still got learning to do.

Reply #11 Top

Well I don't really know how my situation is going to help with anything unless you want to put repair abilities on strikecraft, but this was basically it.

TXT
entityType "Buff"
onReapplyDuplicateType "PrioritizeNewBuffs"
buffStackingLimitType "ForAllPlayers"
stackingLimit 1
allowFirstSpawnerToStack FALSE
buffExclusivityForAIType "ExclusiveForAllPlayers"
isInterruptable FALSE
isChannelling FALSE
numInstantActions 0
numPeriodicActions 1
periodicAction Does the actual repair
    actionCountType "Infinite"
    actionIntervalTime
        Level:0 1.000000
        Level:1 1.000000
        Level:2 1.000000
    buffInstantActionType "RestoreHullPoints"
    instantActionTriggerType "OnDelay"
    delayTime 0.000000
    hull
        Level:0 0.200000
        Level:1 0.200000
        Level:2 0.200000
numOverTimeActions 1

overTimeAction Shows up correctly on the info card but doesn't do anything for some reason
    buffOverTimeActionType "RestoreHull"
    hullRestoreRate
        Level:0 0.200000
        Level:1 0.000000
        Level:2 0.000000
numEntityModifiers 0
numEntityBoolModifiers 0