Aller au contenu

Photo

Puzzler ... or MAJOR glitch


  • Veuillez vous connecter pour répondre
5 réponses à ce sujet

#1
I_Raps

I_Raps
  • Members
  • 1 262 messages
I've been running a cleric around the Sword Coast lately, and as usual upon gaining lvl 6 spells, I memorized Stone Body (particularly important because this particular cleric is a svirfneblin and his opponents are already thowing around blinding spells).  Also as usual, I have been disappointed with the pittance of duration;  this time, though I was annoyed enough to look into it.  The spell itself is supposed to last 1 minute per caster level, the same as Bull's Strength and many others, but to my mind it's not even close.  So I looked at the scripts and sure enough, though their durations are supposed to be the same, they are coded differently. 

To the toolset I flew and changed the Stone Body script duration to match the Bull Strength script duration.  Mirabile dictu, it worked wonderfully.  The difference is night and day.

Which leads me to the puzzler...

Here are the operative lines:  the commented out line is the original Stone Body duration, and the other is from Bull's Strength.  Why are they different?


// float fDuration = 60.0*nCasterLevel; // seconds (1 min per level) - REPLACED WITH BULL'S STRENGTH TEMPLATE

float fDuration = TurnsToSeconds(nCasterLevel);

------------------------------------------------------------------------------------------------

As for the possible "MAJOR glitch" ...

... possibly I am imagining this huge difference in duration, but I don't think so.  We're talking about orders of magnitude, not just a few seconds.

Which brings me to my guess ...  TurnsToSeconds uses real seconds (as in 24 hour days) whereas the game supposedly uses scale seconds (as in 2.4 hour days).  If this is so,  all you freakin' casters have been living a lie for years.

Modifié par I_Raps, 30 avril 2012 - 03:55 .


#2
painofdungeoneternal

painofdungeoneternal
  • Members
  • 1 799 messages
Have you tried echo-ing out the fDuration after each is calculated, that would give you exactly what is going on.

#3
Dann-J

Dann-J
  • Members
  • 3 161 messages
I've applied effects to creatures in scripts using DURATION_TYPE_TEMPORARY and a specific number of seconds, and they've always lasted that number of *actual* seconds (rather than game seconds). If they were game seconds, then durations of 6 or 12 seconds (one or two rounds) would be over almost instantaneously - which they never are.

I wonder if this would also work:
float fDuration = 60.0*IntToFloat(nCasterLevel);

TurnsToSeconds takes an integer value, and I'm guessing the caster level function also returns an integer. Multiplying a float with an integer might be causing problems.

#4
I_Raps

I_Raps
  • Members
  • 1 262 messages
Iron Body still uses the old/Stone Body version; I had the toolset open to upgrade it, but instead I've added a floating text to both of them. I'll pull Sand away from the ballet and have him try out both.

#5
I_Raps

I_Raps
  • Members
  • 1 262 messages
After a couple demonstrations both with and without the new code, I think the major glitch is with my time sense. I can't really see any difference, at least not when standing around in the Keep. Maybe I'm just inordinately prone to getting it dispelled.

#6
Dann-J

Dann-J
  • Members
  • 3 161 messages
Stone body is supposed to slow you down to half speed - so perhaps from the individual's point of view, time appears to be moving twice as fast? Einstein's relativity at work... Image IPB