Note: LucasForums Archive Project
The content here was reconstructed by scraping the Wayback Machine in an effort to restore some of what was lost when LF went down. The LucasForums Archive Project claims no ownership over the content or assets that were archived on archive.org.

This project is meant for research purposes only.

Scripting Dilemmas

Page: 1 of 1
 darth_ballz
02-09-2008, 4:30 AM
#1
Hey, can anyone tell me why this script doesn't compile/work?! I have no idea about scripting I copied this straight from the tutorial. All i want it to do is increase an attribute by 2 :(

void AdjustCreatureAttributes(GetFirstPC(),ABILITY_CHAR ISMA,2);


Mod note: Moved to Holowan forum since it's a modding question. ~M
 stoffe
02-09-2008, 6:45 AM
#2
Hey, can anyone tell me why this script doesn't compile/work?! I have no idea about scripting I copied this straight from the tutorial. All i want it to do is increase an attribute by 2 :(


It doesn't compile since it's not a complete script. You don't have any starter function, and you have a mix of a function declaration and call instead of just a call like it should be. Try:


void main() {
AdjustCreatureAttributes(GetFirstPC(), ABILITY_CHARISMA, 2);
}


(This will only work for Kotor2:TSL and not the first game though.)
 darth_ballz
02-09-2008, 7:49 PM
#3
OK thanks, but what would work to increase an attribute in KotOR 1 then? There must be some command or how would Force Valour etc work
 RedHawke
02-10-2008, 2:10 AM
#4
There isn't... those functions were added in for TSL, you can't permanently adjust attributes vis scripts in KotOR I. Your example is a force power and is a temporary boost, not a permanent change.
Page: 1 of 1