Marcin55 Posted October 20, 2010 Author Share Posted October 20, 2010 Hello I found bug in ES. When I lvl up I give ponit to str and I gain 1 more point wtf!?I found that file but dont know what change it in.> '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''> ' Module: PlayerLevelUp.ess '> ' Author: Stephan J.R. van Schaik '> ' Date: August 30th, 2009. '> ' Version: 1.0.0 '> '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''> > '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''> ' Function: PlayerLevelUp '> ' Brief: executes when a player levels up. '> ' Parameters: '> ' Index: the index number of the player. '> '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''> Sub PlayerLevelUp(Index)> Dim PlayerExp> > If GetPlayerExp(Index) < GetPlayerNextLevel(Index) Then> Exit Sub> End If> > Do While GetPlayerExp(Index) >= GetPlayerNextLevel(Index)> PlayerExp = GetPlayerNextLevel(Index)> > Call SetPlayerLevel(Index, GetPlayerLevel(Index) + 1)> Call SetPlayerPOINTS(Index, GetPlayerPOINTS(Index) + 1)> Call SetPlayerExp(Index, GetPlayerExp(Index) - PlayerExp)> Call SetPlayerHP(Index, GetPlayerMaxHP(Index))> Call SetPlayerMP(Index, GetPlayerMaxMP(Index))> Call SetPlayerSP(Index, GetPlayerMaxSP(Index))> Call SendPlayerData(Index)> Call SendStats(Index)> Call SendHP(Index)> Call SendMP(Index)> Call SendSP(Index)> Call SendPTS(Index)> Loop> > Call BattleMsg(Index, "You have " & GetPlayerPOINTS(Index) & " stat points.", BRIGHTBLUE, LEFT)> End SubOr here :> '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''> ' Module: UsingStatPoints.ess '> ' Author: Stephan J.R. van Schaik '> ' Date: August 30th, 2009. '> ' Version: 1.0.0 '> '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''> > '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''> ' Function: UsingStatPoints '> ' Brief: executes when a player uses a stat point. '> ' Parameters: '> ' Index: the index number of the player. '> ' Type: the stat type to increment. '> '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''> Sub UsingStatPoints(Index, StatType)> Select Case StatType> Case STAT_STRENGTH> If GetPlayerSTR(Index) + 1 >= MAX_STAT Then> Call BattleMsg(Index, "You have maxed your strenght!", BRIGHTRED, LEFT)> > Exit Sub> End If> > Call SetPlayerSTR(Index, GetPlayerSTR(Index) + 1)> Call BattleMsg(Index, "You have gained more strenght!", WHITE, LEFT)> > Case STAT_DEFENCE> If GetPlayerDEF(Index) + 1 >= MAX_STAT Then> Call BattleMsg(Index, "You have maxed your defence!", BRIGHTRED, LEFT)> > Exit Sub> End If> > Call SetPlayerDEF(Index, GetPlayerDEF(Index) + 1)> Call BattleMsg(Index, "You have gained more defence!", WHITE, LEFT)> > Case STAT_SPEED> If GetPlayerSPEED(Index) + 1 >= MAX_STAT Then> Call BattleMsg(Index, "You have maxed your speed!", BRIGHTRED, LEFT)> > Exit Sub> End If> > Call SetPlayerSPEED(Index, GetPlayerSPEED(Index) + 1)> Call BattleMsg(Index, "You have gained more speed!", WHITE, LEFT)> > Case STAT_MAGIC> If GetPlayerMAGI(Index) + 1 >= MAX_STAT Then> Call BattleMsg(Index, "You have maxed your magic!", BRIGHTRED, LEFT)> > Exit Sub> End If> > Call SetPlayerMAGI(Index, GetPlayerMAGI(Index) + 1)> Call BattleMsg(Index, "You have gained more magic!", WHITE, LEFT)> > Case Else> Call PlayerMsg(Index, "Unknown stat type.", BRIGHTRED)> > Exit Sub> End Select> > Call SetPlayerPOINTS(Index, GetPlayerPOINTS(Index) + 1)> End SubPlease help. I'm sorry for my english I dont know good it. Link to comment Share on other sites More sharing options...
Marcin55 Posted October 21, 2010 Author Share Posted October 21, 2010 Please somebody help. I have all done in game but i need to repair bug. Sorry for double post,because nobody read it. Link to comment Share on other sites More sharing options...
GammaÃâžÂ Posted October 21, 2010 Share Posted October 21, 2010 > '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''> ' Module: UsingStatPoints.ess '> ' Author: Stephan J.R. van Schaik '> ' Date: August 30th, 2009. '> ' Version: 1.0.0 '> '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''> > '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''> ' Function: UsingStatPoints '> ' Brief: executes when a player uses a stat point. '> ' Parameters: '> ' Index: the index number of the player. '> ' Type: the stat type to increment. '> '''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''> Sub UsingStatPoints(Index, StatType)> Select Case StatType> Case STAT_STRENGTH> If GetPlayerSTR(Index) + 1 >= MAX_STAT Then> Call BattleMsg(Index, "You have maxed your strenght!", BRIGHTRED, LEFT)> > Exit Sub> End If> > Call SetPlayerSTR(Index, GetPlayerSTR(Index) + 1)> Call BattleMsg(Index, "You have gained more strenght!", WHITE, LEFT)> > Case STAT_DEFENCE> If GetPlayerDEF(Index) + 1 >= MAX_STAT Then> Call BattleMsg(Index, "You have maxed your defence!", BRIGHTRED, LEFT)> > Exit Sub> End If> > Call SetPlayerDEF(Index, GetPlayerDEF(Index) + 1)> Call BattleMsg(Index, "You have gained more defence!", WHITE, LEFT)> > Case STAT_SPEED> If GetPlayerSPEED(Index) + 1 >= MAX_STAT Then> Call BattleMsg(Index, "You have maxed your speed!", BRIGHTRED, LEFT)> > Exit Sub> End If> > Call SetPlayerSPEED(Index, GetPlayerSPEED(Index) + 1)> Call BattleMsg(Index, "You have gained more speed!", WHITE, LEFT)> > Case STAT_MAGIC> If GetPlayerMAGI(Index) + 1 >= MAX_STAT Then> Call BattleMsg(Index, "You have maxed your magic!", BRIGHTRED, LEFT)> > Exit Sub> End If> > Call SetPlayerMAGI(Index, GetPlayerMAGI(Index) + 1)> Call BattleMsg(Index, "You have gained more magic!", WHITE, LEFT)> > > Case Else> Call PlayerMsg(Index, "Unknown stat type.", BRIGHTRED)> > Exit Sub> End Select> > Call SetPlayerPOINTS(Index, GetPlayerPOINTS(Index) - 1)> End Subtry hat Link to comment Share on other sites More sharing options...
Marcin55 Posted October 21, 2010 Author Share Posted October 21, 2010 Thanks it's working Link to comment Share on other sites More sharing options...
GammaÃâžÂ Posted October 21, 2010 Share Posted October 21, 2010 no problem ^^ Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now