Not really. They did it that way so when the mask goes off, the PC's face is revealed. Seeing the amount of faces a PC can choose, well, doing biks for all of them is a bit too much, no?

What? I don't follow you at all. Why would they make a Bink video for every face? Obviously they'd need to do that in the game... but that wasn't stricly necessary for the scene; it could have been done another way. What I meant is that someone who has disabled the Bink videos will only see this part. Anyway, this is all irrelevant.

Quote:

Originally Posted by Fallen Guardian

Cool, but how would I take note of the module the PC was in before the cutscene so I could warp back to it?

Either a global as mentioned above, or if it's all in a single script you might not have to do even that.

I don't know, maybe my perspective is foggy since I already knew. But my thought was the combination of Bink and cutscene was necessary, because if you disable the Bink videos you would only see the cutscene.

Well, if you disable movies, you're still going to be a bit lost. However, Kreia's fall and Visas' introduction were both originally in the game. I believe the scripts are set up to save your location and such already - at least it seemed that way when I glanced at them many moons ago - but obviously they decided to do a Bink video instead, likely to cut down on the loading time. There's still some of that nonsense with the Atris interludes.

Just out of intrest how would you go about creating a script for endgame? You know, after the last k1 movie has played and you return to the main menu. This is my idea of how it would look (note that im the worst scripter holowan has known),

Just out of intrest how would you go about creating a script for endgame? You know, after the last k1 movie has played and you return to the main menu. This is my idea of how it would look (note that im the worst scripter holowan has known),

Code:

void main()
{
StartNewModule("ENDGAME");
}
}

Here's the code to return to the main menu:

Code:

// NOTE: If you put EndGame(TRUE); or EndGame(1); or if you don't put a
// variable, it will default to displaying the death GUI. To not display
// the death GUI, you have to put EndGame(FALSE); or EndGame(0);
void main()
{
EndGame(0);
}

Glad to see that you folks have kept the lights on; between work and some personal/familial issues, I have had very limited and precious personal time, and have been unable to keep up with my friends (and responsibilities) here. For those of you with an unanswered PM, I will get to my inbox this weekend - my apologies for my absence!

Okay, so today I was writing a dialogue file and was wondering if it was possible to check if the PC has a certain item class in his/her right hand. See, if I were to make an option that has the PC talking about using his/her lightsaber even though the PC doesn't have on equipped, it'd look kind of strange.

So would it be possible to have a script that checks if the PC has any sort of blaster pistol equipped in the right hand, or any sort of blaster rifle equipped etc. and return true if the PC has a blaster or a rifle equipped, but false if the PC does not?

The truly fallen cannot return to the light. If someone "falls" and "returns," they never really, truly fell.

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...

Do you know if I were to change the "Lightsaber" to say Blaster Pistol, if it would work or not?

I don't thinks o. I believe it's checking the actual name of the item - i.e. what it is called in the inventory, determined in the UTI somewhere - and it only works in this instance because every lightsaber has "Lightsaber" somewhere in its name. This isn't true of all blasters - the plasma thrower and mining lasers, for example. Since you want to check for any sort of blaster, you'll need to use something else.

These parts are problematic. You've defined one variable multiple times, and even used the variable in the definition. I'm not entirely sure what you're trying to do here, but for one thing you'll need to use multiple variables - eBuff1, eBuff 2, and so on (or something more appropriate - the names are entirely up to you). Anyway, it looks like you're trying to increase Constitution, and then decrease it after 30 seconds, along with some visual effects and stuff. This is a rough guess of what it should look like, then:

I'm not sure what the rest is supposed to be, but I don't see anything obviously wrong - except in one case I think you used a period instead of a comma. You also have it increase by 25, then decrease by only 15, though that might be intentional. I also don't think increasing Constitution actually increases a character's current HP, so you might want to look into that. Not bad for a first attempt, in any case; Force powers are especially tricky, after all.

Quote:

Originally Posted by Fair Strides 2

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.

I believe the cost is in the 2DA, and the class level stuff is in another 2DA, not in the script - I don't think you want someone to be able to select the power and then for it to do nothing when they activate it.

I'd help you both further, but unfortunately I don't have access to my files... I can't even check NWScript. I'll get back to you... eventually.

These parts are problematic. You've defined one variable multiple times, and even used the variable in the definition. I'm not entirely sure what you're trying to do here, but for one thing you'll need to use multiple variables - eBuff1, eBuff 2, and so on (or something more appropriate - the names are entirely up to you). Anyway, it looks like you're trying to increase Constitution, and then decrease it after 30 seconds, along with some visual effects and stuff. This is a rough guess of what it should look like, then:

I'm not sure what the rest is supposed to be, but I don't see anything obviously wrong - except in one case I think you used a period instead of a comma. You also have it increase by 25, then decrease by only 15, though that might be intentional. I also don't think increasing Constitution actually increases a character's current HP, so you might want to look into that. Not bad for a first attempt, in any case; Force powers are especially tricky, after all.

I believe the cost is in the 2DA, and the class level stuff is in another 2DA, not in the script - I don't think you want someone to be able to select the power and then for it to do nothing when they activate it.

I'd help you both further, but unfortunately I don't have access to my files... I can't even check NWScript. I'll get back to you... eventually.

Well, thanks for the help. I messaged Mandalore at DeadlyStream as well. He mentioned the issue of

Quote:

First problem that jumped out at me: after the

void main()

, you used ( instead of {. That's why the compier said there was a syntax error at line 6.

I'll think on the line 11 error, as that seems to be the same as the turorial one.

I also realized you were trying to link the effects. You did part of it right, but some of it was out of order, or not applicable, hence my confusion.

The primary purpose is to set up a "save and ignore" system; if a creature is immune to one of the effects, none of the effects will be applied. For example, movement speed decrease is a debilitating effect of poison; if you are immune to poison, your movement speed should not be decreased because you weren't poisoned. Its other purpose is to enable lazy coders. When you link effects, you just need to fire the link effect and then all the others will be fired at the same time - meaning you only need to apply one effect. So if you have a bunch of effects of the same type that will all be applied to the same object at the same time and will have the same duration type and length, then you can link all the effects into one and apply them all at once. It's a lot of work in the setup, but the reward is a more streamlined script. Of course, there are a lot of limitations; the effects must meet all the above criteria, and in general it's very sensitive - some effects just won't work.

Now, you have three effects (well, four, but visuals can't be linked) - two are fired at different times and last for different durations, and one is simply an icon. So you really don't need to link them. But if you insist on it, then it would look something like this:

That should simply link the icon and the CON increase. I don't believe it's necessary because SetEffectIcon should already function like that, but I could be wrong.

Let's say you want to add something like poison at the end of the spell, in addition to the Constitution penalty... and just for good measure, decreased movement speed. And if the character is immune to poison, their CON will simply return to normal, with no debilitating effects. Here's an example of what it should look like:

I also realized you were trying to link the effects. You did part of it right, but some of it was out of order, or not applicable, hence my confusion.

Now, you have three effects (well, four, but visuals can't be linked) - two are fired at different times and last for different durations, and one is simply an icon. So you really don't need to link them. But if you insist on it, then it would look something like this:

That should simply link the icon and the CON increase. I don't believe it's necessary because SetEffectIcon should already function like that, but I could be wrong.

Thanks. As was stated in my original post, I used this Which clearly stated that if I wanted to make my own buff Power, to simply substitute my stuff in. I copied and pasted the code into Notepad and saved it as a make-shift tutorial. I did so for each code box and labeled them "Buff_Power-Extended" and "Buff_Power" accordingly. Then when I did mine, I skipped the level checks, and now that I think about it, the linked effects were probably used to relate to each level check.

Hence my confusion as well. I'll re-do the script as soon as I fix my TSL game. I'm using the factory discs, no torrents, and when I insert the play disc(after Disc 4 of course),...AND MY COMPUTER EMERGENCY RESTARTS!!!

I might have to re-install Windows...

Also, how would I script that if I was to not link it, and what would be the difference between the linked and not-linked versions? Thank you, JC!

Thanks. As was stated in my original post, I used this Which clearly stated that if I wanted to make my own buff Power, to simply substitute my stuff in. I copied and pasted the code into Notepad and saved it as a make-shift tutorial. I did so for each code box and labeled them "Buff_Power-Extended" and "Buff_Power" accordingly. Then when I did mine, I skipped the level checks, and now that I think about it, the linked effects were probably used to relate to each level check.

Ah I see. You had most of it right; mainly it was the last effect, which couldn't be linked to the others because of the reasons I specified.

Quote:

Also, how would I script that if I was to not link it, and what would be the difference between the linked and not-linked versions? Thank you, JC!

That's the unlinked version. There should be no functional difference in this case unless I'm completely wrong about the icon thing and you really do have to link them. For the record, when scripting I always assume I'm wrong and double check... the engine is a fickle and unpredictable mistress. And I do believe you're right, the linked effects in the tutorial were related to the level checks; it applies different stat bonuses depending on the character's level, with the stat bonuses nested in if/else statements, all linked to some stuff defined earlier on. Frankly I wouldn't do it that way; I'd rather use a subroutine, with the stat bonus as a variable... but that's an entirely different tutorial. And I wasn't sure if you want that or not. This is for having one spell with multiple effects that depend on your level - a 20 point bonus at level 6 and above, a 25 point bonus for level 12 and above, 30 for level 18, and so on; if you simply want to give classes access to the spell at different times, you need a 2DA for that. But if you do want the first thing, come back and I can give you that other tutorial, or you could look at Qui-Gon's.

With errors at line 13 for undeclared identifier for "Sp_RemoveSpellEffectsGeneral" and line 18 at undeclared identifier for "VFX_IMP_BATTLE_MED_III" and required argument missing in call to "EffectVisualEffect".

I hit compile, and I get an error at line 32 because of the "ApplyEffectToObject" in the beginning.

You're missing a semicolon on the previous line.

But the second one looks fine apart for two things:

Quote:

With errors at line 13 for undeclared identifier for "Sp_RemoveSpellEffectsGeneral" and line 18 at undeclared identifier for "VFX_IMP_BATTLE_MED_III" and required argument missing in call to "EffectVisualEffect".

The K in "k_inc_force" shouldn't be capitalized. Everything is case sensitive. EVERYTHING. Because you didn't include it properly, it can't find stuff that's defined in it.

Quote:

effect eTargetVisual;

Delete that, you aren't using it anywhere.

Nothing else jumps out at me... but often nothing jumps out at me when other stuff is jumping out at me... I usually have to fix one error at a time until it goes through.

Because I had tried to compile it with the semicolon, but it gave a syntax error with it.

Well, you need the semicolon. Every command has to end with a semicolon. However, you're also missing a close parenthesis.

Quote:

Lower-cased the K, but still no dice. Even rearranged it so that the SignalEvent line was above everything after the effect stuff, and nothing.

Hmm. I'm afraid I can't be of much help, because I've never messed around with k_inc_force. Frankly I don't like including scripts, generally; too easy to mess things up. The amount of work including saves is countered by the amount of work it takes to get it to work. So the only thing I can suggest is you look at k_inc_force and make sure you've done everything right; if I had to guess, I'd say the first P in "Sp_RemoveSpellEffectsGeneral" has to be capitalized.

As for VFX_IMP_BATTLE_MED_III, I'm not entirely sure what's going wrong there, but you can easily resolve it by looking at visualeffects.2da and finding the actual line number of VFX_IMP_BATTLE_MED_III and input that in its place.

Quote:

Originally Posted by Fallen Guardian

Hey, just tested the conditional scripts for the weapons. They all work, thanks JC and HH.

Nice! Such a conditional sounds very useful indeed. I might make a universal one for K2 when I have my stuff sorted out. Thanks to K2's script parameters, it would be able to check if you have any of several different types, just by inputting the number of each type into the dialogue file.

Hey, I've come to ask for help in the making of a script. Basically, I have an idea on what I'd like to do and I'm pretty sure it's possible, I just wouldn't know how to write it up. So I'll write what I'd like to happen as if I were writing a script, just with words, no functions.

Code:

void main()
{
Check to see if the on perception event has been fired and to see if the distance between the PC and OBJECT_SELf is 7 meters or less and checks to see if a local boolean of OBJECT_SELF is false.
ActionWait(5.0);
ExecuteOtherScript
Or if the above conditional is not met, it goes to this next one.
Check to see if the on perception event has been fired and to see if the distance between the PC and OBJECT_SELf is 10 meters or less and checks to see if a local boolean of OBJECT_SELF is false and checks to see if a global boolean has been set true.
ActionWait(5.0);
ExecuteOtherScript2
Or if the above conditional is not met, it goes to this next one.
Check to see if the on perception event has been fired and to see if the distance between the PC and OBJECT_SELF is 5 meters or less and checks to see if a local boolean of OBJECT_SELF is false and checks to see if a global boolean has been set true.
ActionWait(5.0);
ExecuteOtherScript3
End Script

So I just really need help in setting up those conditionals all into one script. If anyone could help, it'd be much appreciated.

The truly fallen cannot return to the light. If someone "falls" and "returns," they never really, truly fell.

Not sure what you want for the perception event... I think if you want to make something happen when an object perceives something, you have to modify its OnPerception script. Also, what you described will never trigger #3. Here it is anyway though, minus the perception stuff:

Not sure what you want for the perception event... I think if you want to make something happen when an object perceives something, you have to modify its OnPerception script. Also, what you described will never trigger #3. Here it is anyway though, minus the perception stuff:

Thanks JC. The reason I want the perception event is because this is a userdefined script for an NPC.

I still don't get what you want. I don't think there's a generic "check if NPC has seen something" function. I'm not sure if you can even check if a specific NPC has seen a specific object, unless it's a trap. Perhaps someone else can clarify; I tend to stay away from this area, I prefer predictable scripting, like cutscenes.

EDIT: I looked into it more out of curiosity and it appears to have confirmed my suspicions. Here's a bit from Atton's user defined events:

That checks if the PC was the last object Atton saw, but it doesn't trigger anything on its own. You'd need to trigger the user defined event via the perception script (apparently it's called "OnNotice" in KOTOR Tool).

Quote:

Just out of curiosity, why wouldn't the 3rd condition ever be met?

Because if it's less than 5 meters away then it's also less than 7 or 10 meters away, and those are checked first. I could recommend some changes, but I'd need more specifics; as I said I'm not quite sure what you're doing here.