Jump to content

can't cah


Recommended Posts

so I'm working on this mod that will have some global values to represent oblivion-style attributes but for some reason I just can't seem to get the values to change in game. I have the SetValue commands seemingly set up properly in the script but when i go in game the value remains unchanged (i.e 0.0000 or so for all the floats). I have all the globals set as floats but I'm not sure if that's the problem or not. I have a function that displays a message box for one of the globals so I know that the value just isn't changing at all despite the script having no clear errors.

does anyone have any idea how I can fix this so where the tyBaseAtt globals have their values changed and actually reflected in game? does this have something to do with the functions I put them in potentially? or is it some other issue I'm not even aware of.

here's a full rundown of my current script so you guys can take a look and tell me what's up

Scriptname tyLESAAttributeScript extends Quest  

race property HighElfRace auto
globalvariable property tyLevelUpIncM auto
globalvariable property FavorRewardSmall auto
globalvariable property SpeechVeryEasy auto
globalvariable property tyBaseAttSpe auto
globalvariable property tyExtraPerkChance auto
globalvariable property tyBaseAttInt auto
globalvariable property FavorRewardMedium auto
globalvariable property SpeechEasy auto
globalvariable property FavorRewardLarge auto
race property OrcRace auto
globalvariable property tyBaseAttAgi auto
globalvariable property QuestReward04Wow auto
globalvariable property FavorGoldRewardSmall auto
race property DarkElfRace auto
globalvariable property MGR11Reward03 auto
race property RedguardRace auto
globalvariable property tyBaseAttStr auto
globalvariable property tyBaseAttLuk auto
globalvariable property tyLevelUpIncCW auto
globalvariable property tyModAttSpe auto
race property KhajiitRace auto
globalvariable property QuestReward02Medium auto
globalvariable property tyModAttWil auto
globalvariable property MGR11Reward01 auto
globalvariable property tyBaseAttEnd auto
globalvariable property tyLevelUpIncS auto
globalvariable property SpeechAverage auto
globalvariable property QuestReward03Large auto
globalvariable property MGR11Reward04 auto
globalvariable property SpeechHard auto
globalvariable property tyBaseAttWil auto
globalvariable property tySavedAttributes auto
globalvariable property tyModAttEnd auto
race property BretonRace auto
globalvariable property MGR11Reward05 auto
globalvariable property tyModAttPer auto
race property WoodElfRace auto
globalvariable property tyModAttInt auto
race property ImperialRace auto
globalvariable property SpeechVeryHard auto
globalvariable property tyModAttAgi auto
globalvariable property tyBaseAttPer auto
globalvariable property tyLevelUpIncH auto
globalvariable property FavorRewardIntimidate auto
race property ArgonianRace auto
globalvariable property tyModAttLuk auto
race property NordRace auto
globalvariable property FavorRewardBribe auto
actor property player auto
globalvariable property tyModAttStr auto
globalvariable property MGR11Reward02 auto
globalvariable property QuestReward01Small auto
 

;-- Variables ---------------------------------------

float Str 
float End 
float Itn 
float Wil 
float Spe 
float Luk 
float Agi 
float Per 

float StrMod 
float EndMod 
float ItnMod 
float WilMod 
float SpeMod 
float LukMod 
float AgiMod
float PerMod 



:-- Not currently in use




;-- Functions ---------------------------------------


Function OnUpdate()
    player = game.GetPlayer()
    race playerRace = player.GetRace()

    tyBaseAttStr.SetValue(6 as float)
    tyBaseAttEnd.SetValue(8 as float)
    tyBaseAttInt.SetValue(12 as float)
    tyBaseAttWil.SetValue(10 as float)
    tyBaseAttSpe.SetValue(8 as float)
    tyBaseAttAgi.SetValue(6 as float)
    tyBaseAttPer.SetValue(6 as float)
    tyBaseAttLuk.SetValue(10 as float)

EndFunction

Function OnInit()
    self.CalculateStatsStart()

EndFunction

Function CalculateStatsStart()

    
   
 

        Debug.MessageBox("Strength is " + tyBaseAttStr.GetValue())

    
    


EndFunction



Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...