JAshton83 Posted March 15, 2005 Share Posted March 15, 2005 Hey folks, I'm wondering if it's at all possible to cobble together a force power for KOTOR I or II that fires off the droid flamethrower, or applies similar effects. I have the horrible notion that if this is at all possible, it'll involve scripting, and I'm afraid I'm not terribly good at that. I apologise if this has been covered elsewhere, but the search funtion seems to be down. Link to comment Share on other sites More sharing options...
Xcom Posted March 15, 2005 Share Posted March 15, 2005 I think it's very possible. yes, it will involve some scripting, I believe. Nothing too drastic, but it can be challenging if you just started or not good at scripting. Check this tutorial on how to script a power. There is also a link there on how to create custom power. http://lucasforums.com/showthread.php?s=&threadid=137498 I think the easiest way for you is to examin k_inc_force.nss (the script that controls all force powers) and check the code it has for Lightning and basically copy it in your custom script. Lightning includes a beam effect that goes from your hand to the target, plus the duration effect (and obviously damage and stuff). You'll simply need to replace the visual electric effects for flames. Link to comment Share on other sites More sharing options...
JAshton83 Posted March 15, 2005 Author Share Posted March 15, 2005 Thanks for the help, I'll post it if I make any headway! Link to comment Share on other sites More sharing options...
tk102 Posted March 15, 2005 Share Posted March 15, 2005 I made an armband flamethrower once. The script source is included in the mod. Might help you get started script-wise. http://www.pcgamemods.com/9390/ Link to comment Share on other sites More sharing options...
JAshton83 Posted March 15, 2005 Author Share Posted March 15, 2005 Okay, got it working in-game (I really hate trial and error). The script is below, I haven't tested it hugely, if anyone can see any problems please let me know. My new problem is how to give it a custom description, currently I'm just using another power' reference in spells.2da but that's a bit confusing, expecially since it claims to be Force Enlightenment... Can anyone tell me what I need to mod to creat a custom power description? Thanks again in advance... case FORCE_POWER_IMMOLATE: { SWFP_HARMFUL = TRUE; SWFP_PRIVATE_SAVE_TYPE = SAVING_THROW_WILL; SWFP_PRIVATE_SAVE_VERSUS_TYPE = SAVING_THROW_TYPE_FIRE; int nDice = GetHitDice(OBJECT_SELF); SWFP_DAMAGE = Sp_CalcDamage( oTarget, nDice, 6 ); //SWFP_DAMAGE = d6(nDamage); SP_MyPostString(IntToString(SWFP_DAMAGE),5,5,4.0); SWFP_DAMAGE_TYPE = DAMAGE_TYPE_FIRE; SWFP_DAMAGE_VFX = VFX_PRO_LIGHTNING_S; effect eDamage = EffectDamage(SWFP_DAMAGE, DAMAGE_TYPE_FIRE); effect eDamage2 = EffectDamage(SWFP_DAMAGE/3, DAMAGE_TYPE_FIRE); int nSaves = Sp_MySavingThrows(oTarget); int nResist = Sp_BlockingChecks(oTarget, eDamage, eInvalid, eInvalid); eLink1 = EffectBeam(2053, OBJECT_SELF, BODY_NODE_HAND); effect eVFX = EffectVisualEffect(1039); effect eBump = EffectVisualEffect(2062); effect eHorror = EffectHorrified(); eHorror = SetEffectIcon(eHorror, 99); SignalEvent(oTarget, EventSpellCastAt(OBJECT_SELF, GetSpellId(), SWFP_HARMFUL)); if(nResist == 0) { ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eLink1, oTarget, fLightningDuration); ApplyEffectToObject(DURATION_TYPE_INSTANT, eVFX, oTarget); if(nSaves == 0) { ApplyEffectToObject(DURATION_TYPE_INSTANT, eDamage, oTarget); ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eHorror, oTarget, 3.0); DelayCommand( 0.33, ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eBump, oTarget, 4.5)); } else { ApplyEffectToObject(DURATION_TYPE_INSTANT, eDamage2, oTarget); DelayCommand( 0.33, ApplyEffectToObject(DURATION_TYPE_TEMPORARY, eBump, oTarget, 4.5)); } } //Sp_ApplyEffects(FALSE, oTarget, 0.0, 1, eLink1, fLightningDuration, eInvalid, 0.0); } break; Link to comment Share on other sites More sharing options...
SuperSquall Posted March 15, 2005 Share Posted March 15, 2005 Tiny thing: You've got it listed as a power that needs a Will Saving Throw to be resisted - I think a Fortitude Saving Throw might be more appropriate. Think you could make a Fire Storm force power that operates more like Force Wave? Link to comment Share on other sites More sharing options...
monkey joe Posted March 15, 2005 Share Posted March 15, 2005 Originally posted by tk102 I made an armband flamethrower once. The script source is included in the mod. Might help you get started script-wise. http://www.pcgamemods.com/9390/ I made a flame thrower rocket the easy way, just replaced "activate item-explosive rocket" with "activate item-droid flamethrower" And it worked! Link to comment Share on other sites More sharing options...
JAshton83 Posted March 15, 2005 Author Share Posted March 15, 2005 I could try to create a fire-storm, but the flamethrower effect is a directed stream, short of just having the force wave effect and causing all the targets it impacts to spontaneously combust, I'm not sure how I'd do it. More immediately, if anyone could tell me what I need to ammend dialogue.tlk then I'd be very happy! Link to comment Share on other sites More sharing options...
JAshton83 Posted March 15, 2005 Author Share Posted March 15, 2005 If I could get the description sorted, I'd be happy to post the thing up here. I already had Darth333's floating lightsaber mod installed, so it works with that. I just need to figure out i) how to ammend dialogue.tlk to include a custom description, ii) how to make it a slelectable force power during level up (I followed beancounter and tk102's tutorials, but for some reason it aint there... works if I use KSE to give it to my character though....) iii) what files I'd need to include in a downloadable mod type thing. Sorry for being utterly clueless about this, but I've never really tried to mod a game before. And thanks for all the help already - I'll take the suggestion and change the save to a Fortitude one. I have to thanks tk102 seperately, I actually got the idea from the flamethrower armband, but so many armbands, only two arms! Link to comment Share on other sites More sharing options...
tk102 Posted March 15, 2005 Share Posted March 15, 2005 The only way to get descriptions to work is to modify the dialog.tlk file. You'll see string references in spells.2da for description and name columns. These are pointers into the dialog.tlk file. You can use KotORTLK to modify the dialog.tlk file, but you would have to distribute the dialog.tlk that way. I suggest using the following: For the name field 5859 -- Flame Thrower For the description field 130393 Damage: Fire, 60pts On Hit: Horror, 100% for 3sec Special: Targets 7th level and up ignore horror effect Save: DC20 for half damage Range: Short Charges: Using this item consumes one charge. This item is automatically discarded after all available charges are consumed. Items that have charges do not stack in inventory. An upgrade of the standard flame thrower, this device actually shoots wide streams of liquid fire. There are few practical applications requiring such devices but they are sought after by military powers for their devastating effect on morale. These are both in dialog.tlk so no redistribution would be necessary. I know this is a force power, but not having to redistribute the dialog.tlk is a great advantage. Link to comment Share on other sites More sharing options...
JAshton83 Posted March 15, 2005 Author Share Posted March 15, 2005 Thanks a ton! It won't describe the effects accurately but it's a huge improvement! Link to comment Share on other sites More sharing options...
tk102 Posted March 15, 2005 Share Posted March 15, 2005 You can download KotORTLK from here: http://www.pcgamemods.com/8872/ Just point it to your TSL dialog.tlk and you can search for whatever. I did a search for "[F|f]lame" and found these two. Link to comment Share on other sites More sharing options...
Xcom Posted March 15, 2005 Share Posted March 15, 2005 Originally posted by johnmedgla iii) what files I'd need to include in a downloadable mod type thing. Your script(s) (ncs files) Spells.2da Graphic (tga image) for the icon of the power if you made it. Possibly, other files depending on how you want the player to obtain the power. In TSL, you can also use script command GrantSpell(spellID) to give player the power. It's basically the same as using KSE without KSE. Oh, yeah, I strongly suggest you don't edit/ use and redistribute custom TLK file. That thing is 9mb and secondly, it will totally screw other people's games if they have different game versions (as not in the same language as you). Link to comment Share on other sites More sharing options...
JAshton83 Posted March 15, 2005 Author Share Posted March 15, 2005 Okay, signed up for pcgamemods, but it's taking them a while to send me a confirmation e-mail. Took a screen shot, think it works okay. Link to comment Share on other sites More sharing options...
tk102 Posted March 15, 2005 Share Posted March 15, 2005 Nice! Good icon too. Link to comment Share on other sites More sharing options...
Xcom Posted March 15, 2005 Share Posted March 15, 2005 Looks pretty cool. A question though. You seem to be getting Dark Side points at the point of casting? Did you code that or something? If so, why? (just curious) Link to comment Share on other sites More sharing options...
monkey joe Posted March 15, 2005 Share Posted March 15, 2005 Originally posted by Xcom Looks pretty cool. A question though. You seem to be getting Dark Side points at the point of casting? Did you code that or something? If so, why? (just curious) It looks like the dark side points were from attacking the people, not casting the power. Link to comment Share on other sites More sharing options...
JAshton83 Posted March 15, 2005 Author Share Posted March 15, 2005 No, no points for casting. That was just outside the Enclave when I chose to pick a fight with the salvagers, hence the dark points! Link to comment Share on other sites More sharing options...
Xcom Posted March 15, 2005 Share Posted March 15, 2005 Ah! okay then. I guess I must have forgotten you get DS pts for attacking people. Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.