Author Topic: On the CS_Assert (n < count)  (Read 5378 times)

Offline Rosencrantz

  • Gray Haired
  • Lieutenant Commander
  • ****
  • Posts: 99
  • Karma: +0/-0
    • View Profile
On the CS_Assert (n < count)
« on: November 30, 2006, 09:06:46 am »
Well, after some tracing in gdb I discovered that the reason the assert is popping up is because both n and count are zero. Which fits with the assert, but leaves me feeling uneasy.

1) Count isn't being set right for whatever reason and should be > 0.
2) Count is fine because there's nothing to count, but the CS_ASSERT isn't taking that into account.

3) Something else entirely.


Offline Morgul

  • GNE Founder
  • Godlike Fuzzy Dice
  • Grand Admiral
  • **********
  • Posts: 2086
  • Karma: +21/-4
  • Godlike Fuzzy Dice
    • View Profile
    • G33X Nexus Entertainment
Re: On the CS_Assert (n < count)
« Reply #1 on: November 30, 2006, 03:16:27 pm »
It's actually #3.

Lynx looked through it, and easily saw that we're getting a CS_Assert because the PcSimpleCamera isn't in a region. Why not? I personally don't remember any of the details (if I knew them) but the CS_Assert is completely valid; our entities are currently the ones in an invalid state. In order to repair this, Lynx needs to make some CEL fixes, and the fix our code accordingly. So unfortunately you and I were barking up the wrong tree with this bug.

It should be fixed in a week... that's assuming everything goes to hell, and Lynx has absolutely no time... which is par for the course currently.
"Just because my math may tell lies doesn't mean that I don't understand the quantum mechanics of it all." --Caenus

The popular videogame "Doom" is based loosely around the time Satan borrowed two bucks from Vin Diesel and forgot to pay him back.

"In the beginning there was nothing. And it exploded." --Terry Pratchett

Offline Rosencrantz

  • Gray Haired
  • Lieutenant Commander
  • ****
  • Posts: 99
  • Karma: +0/-0
    • View Profile
Re: On the CS_Assert (n < count)
« Reply #2 on: November 30, 2006, 05:42:43 pm »
Excellent! I'm glad we figured out what it was. Lynx, how did you figure that one out? Your comment earlier today about iRegion* makes much more sense now, but I'd love to know how you tracked that one down.

--Rosencrantz

Offline whitelynx

  • GNE Founder
  • Head Code Monkey
  • Commodore
  • *****
  • Posts: 304
  • Karma: +4/-0
  • Internet Idiocy Pundit
    • View Profile
Re: On the CS_Assert (n < count)
« Reply #3 on: December 04, 2006, 09:32:53 pm »
I figured it out using my Amazing Powers of ObservationTM.

Actually, it was #1 and #3 at the same time. ;) The array in question was the array of sectors that the camera was currently "in", and it was empty because the way they name regions in CEL changed, and we hadn't fixed our code to take that into account yet. So now it's fixed. :)
"Without music, life is a mistake, a trial, an exile."
 - Nietzsche