View Single Post
Old 05-02-2012, 12:13 AM   #180
Fair Strides
@Fair Strides 2
Witty Programmer
Fair Strides 2's Avatar
Status: Moderator
Join Date: Jan 2012
Location: Oregon, United States
Posts: 750
Current Game: Master of Orion 2
I tried scripting, using this, and got as far as needing to compile the script.

I'm trying to make/replicate a mod that was made for K1, but was either at PCGM or never hosted. I cannot compile it due to errors with the Syntax at "{" and "SWFP_HARMFUL"

Also, the script is for TSL!!!

Note:1st ever script, took me about an hour and a half in all, counting getting my head to understand it, so I think I did a pretty fair job so far. Only issue is it won't compile, with KT or HazardX's tool.

Here's the source code, and I want to add in the following:
Jedi Guardian, Weaponmaster, and Sith Marauder need to be level 20.
Jedi Sentinel, Watchmen, and Sith Assassin need to be level 16
Jedi Consular, Master, and Sith Lord need to be level 14.

Also, is the cost determined by the script or the .2DA? I put 175 in the force point cost for the .2DA...

Anyways, the source code:
#include "k_inc_force"


void main()

    object oTarget = GetSpellTargetObject();   
    effect eTargetVisual;                      
    effect eBuff;                              

          Sp_RemoveSpellEffectsGeneral(FORCE_POWER_FINAL_STAND, oTarget);

    SignalEvent(oTarget, EventSpellCastAt(OBJECT_SELF. GetSpellId(), SWFP_HARMFUL));

    eBuff = SetEffectIcon(eBuff, 69);
    eTargetVisual = EffectVisualEffect(VFX_IMP_BATTLE_MED_III);

          eBuff = EffectLinkEffects(eBuff, EffectAbilityIncrease(ABILITY_CONSTITUTION, 25));

    ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eTargetVisual, oTarget, 3.0);
    ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eBuff, oTarget, 30.0);

    fDelayInSeconds = 30.0;
    DelayCommand(fDelayInSeconds, eBuff = EffectLinkEffects(eBuff, EffectAbilityDecrease(ABILITY_CONSTITUTION, 15));

Thanks for any help you guys can offer, which means that you might as well have already finished the script!

P.S.: I have everything but the script:spells.2DA, Dialog.TLK, and icon.
Fair Strides 2 is offline   you may: quote & reply,