IPEX-731BA5DD06
Deity
Ruff, had a look into your most excellent coding *ruffles Ruff_hi ears*
Is this the code set I'd need to change
So if I understand it correctly, I just need to edit the last bit of coding to
This will eliminate the random number generator, but still retain your
coding.
Hey Bad Ruff_Hi, Very naughty
C:/...Path to Beyond the sword Mod.../Assets/Python/Contrib/UnitNameEventManager.py
This is the files address in the Mod I need to amend??
Is this the code set I'd need to change
Code:
def getTotal1(self, conv):
## - ^tt1[f][x:y]^ - total where the total is a random number between x and y (number)
# return 'not found' indicator
ziStart = conv.find("^tt1[")
if (ziStart == -1):
return -1
# locate and extract the 'low' value
ziStart = conv.find("[",ziStart)
ziStart = conv.find("[",ziStart + 1)
ziEnd = conv.find(":",ziStart)
ziLow = int(conv[ziStart + 1:ziEnd])
if (ziLow < 1): ziLow = 1
# locate and extract the 'high' value
ziStart = ziEnd
ziEnd = conv.find("]",ziStart)
ziHigh = int(conv[ziStart + 1:ziEnd])
if (ziHigh < 1): ziHigh = 1
# check that the user isn't an idiot
if (ziLow > ziHigh): return ziLow
# return the value
return random.randint(ziLow, ziHigh)
So if I understand it correctly, I just need to edit the last bit of coding to
Code:
return(ziLow, ziHigh)
This will eliminate the random number generator, but still retain your


Code:
check that the user isn't an idiot
Hey Bad Ruff_Hi, Very naughty
C:/...Path to Beyond the sword Mod.../Assets/Python/Contrib/UnitNameEventManager.py
This is the files address in the Mod I need to amend??