.:: Bots United ::.

.:: Bots United ::. (http://forums.bots-united.com/index.php)
-   Bug Reports (http://forums.bots-united.com/forumdisplay.php?f=49)
-   -   Permanent crash on cs_bigbrother_beta1 (http://forums.bots-united.com/showthread.php?t=1769)

KWo 25-05-2004 19:53

Permanent crash on cs_bigbrother_beta1
 
3 Attachment(s)
OK - because a day without bug report is a day losed, I can report something today.;)

Everytime when the game is started at cs_bigbrother_beta1 map server is crashed after few minutes. For sure I played this map with PB2.5. :(
This moment I can say now nothing more - when, why etc. But I made some screenshots with windows messages "HLDS made an illegal operation..." and stacks. I hope this can help for coders.
Tested with latest sPlOrYgOn's beta release, Metamod1.17, CS1.5 Windows98SE (dedicated and listenserver).

When I'll find time I'll try this map with some older version of podbot_mm.dll.

Pierre-Marie Baty 25-05-2004 22:59

Re: Permanent crash on cs_bigbrother_beta1
 
To sPlOrYgOn: like the fix you made for the NUM_FOR_EDICT crash, do a search for

FIND_ENTITY_*

and

FindEntity*

and be sure the start of search entity in these functions is initialized to NULL first. I will feel better once it's done.

KWo 27-05-2004 11:40

Re: Permanent crash on cs_bigbrother_beta1
 
2 Attachment(s)
Like I promised - I tested this map with some older version - created 2004.04.06 22:28 253952 bytes. With this dll the game crash during creating the first bot.:(

[EDIT]
This evening I went in this way: I commented out all addbot commands in podbot.cfg and I started the listenserver with latest sPlOrYgOn beta dll. I made waypoint check - there were many errors. I fixed all of their, I re-waypointed some camp waypoints and I put one path across one door (one-direction - possible open only outside by "use" button - but there is'nt any button). OK - game was started - but bot doesn't go across this door (I didn't put "use" flag - like in some description for doors). I turned on WP editor and I added "use" flag. After restarting the game bots still can't open this door (they ignore "use" flag if they don't see some buttons). OK - I was frustrated - I deleted this connection by this door (if can't work - maybe in the future I go back to this problem). I played about 5 minut and after the crash was once again. Regardless if pwf is OK or not OK - the game crash at this map. This time the stacks are different - so probably this is some waypoint problem on this map (only this was changed and stacks are different).

On this map trere are some "blinking" waypoints and connection. What exactly are meaning these "blinking" waypoints and connections? I waypointed this map about 2 years ago, so probably there are many "arts" mistakes, but under WP editor checking for this today changed pwf is OK.
This second attachement is today's crash result.
[/EDIT]

KWo 28-05-2004 00:02

Re: Permanent crash on cs_bigbrother_beta1
 
I really don't like this "EDIT" - it doesn't change the timpe stamp of post and nobody can see something was changed when look at the general page of BUG REPORT subforum. Where can I report this bug in this posting system?:D

sPlOrYgOn 28-05-2004 02:43

Re: Permanent crash on cs_bigbrother_beta1
 
Quote:

Originally Posted by KWo
I really don't like this "EDIT" - it doesn't change the timpe stamp of post and nobody can see something was changed when look at the general page of BUG REPORT subforum. Where can I report this bug in this posting system?:D

it's not a bug..
it's made like this..
Quote:

Originally Posted by Pierre-Marie Baty
To sPlOrYgOn: like the fix you made for the NUM_FOR_EDICT crash, do a search for

FIND_ENTITY_*

and

FindEntity*

and be sure the start of search entity in these functions is initialized to NULL first. I will feel better once it's done.

It seems that the NUM_FOR_EDICT error was the only one without the NULL first...
I've searched through all the files...
All of them have been initialized to NULL...

KWo 28-05-2004 11:19

Re: Permanent crash on cs_bigbrother_beta1
 
So - what can I do more - to give You better information about this crash? :(

Pierre-Marie Baty 28-05-2004 14:36

Re: Permanent crash on cs_bigbrother_beta1
 
it's up to sPlOrYgOn or another coder to run podbot on cs_bigbrother_beta1 inside a debugger and let the debugger pinpoint the exact spot in the code which causes the crash...

KWo 28-05-2004 23:57

Re: Permanent crash on cs_bigbrother_beta1
 
1 Attachment(s)
Here You have my pwf file. It's not recomended for commercial use - because is very bad (the "art's roules" are broken...). I made it about 2 years ago - so it's better if no one from waypointers will look (it's really wrong waypointed).:) Last time I made only little "tunning" for this file. Here is the latest version - still crashing.
If somebody need this map (bsp and wad) - ask me by PM - I can send it via e'mail - probably the zip file with this map is too big to upload here.

sPlOrYgOn 29-05-2004 03:01

Re: Permanent crash on cs_bigbrother_beta1
 
hmm...
no crash??
I'm playing it and I don't crash..
and the map is horribly designed...

KWo 29-05-2004 10:23

Re: Permanent crash on cs_bigbrother_beta1
 
1 Attachment(s)
Quote:

Originally Posted by sPlOrYgOn
hmm...
no crash??
I'm playing it and I don't crash..
and the map is horribly designed...

Are You using Your Win98 like me or You are playing under linux? I tested this map under CS1.5. Turn on detailnames in podbot.cfg and put there 8 addbot commands with all parameters (and skill 100). Don't use min/max bots, don't use fillserver. About 5-10 min after start game crash. And try this Your beta release, not this with bug buying grenade fix. Try latest PMB version - the same.

BTW - Do You like this map?:)

EDIT
I 've attached mu podbot.cfg. Try to test with it.
[/EDIT]

sPlOrYgOn 29-05-2004 15:15

Re: Permanent crash on cs_bigbrother_beta1
 
i played on a listen for 1 hour on both 1.5 and 1.6 and got nothing...
the map only supports 4 players per team...
theres 2 ways into the house and 1 way out...
it encourages Ts to camp a lot..
CTs can get to T spawn in under 10seconds...
Cts can get to hostages in under 10seconds..
1 CT can keep that 1 way door open while the other CTs get the hostages and run back through the door...
CTs can just take over the roof and the Ts will be screwed..
Ts needs either lots of skill to kill the CTs or camp near the 1 way door or camp where the hostages are..
CTs get cameras and they're all over the map so theres no hiding for the Ts..
the map is really bad...

KWo 29-05-2004 20:39

Re: Permanent crash on cs_bigbrother_beta1
 
Quote:

Originally Posted by sPlOrYgOn
i played on a listen for 1 hour on both 1.5 and 1.6 and got nothing...

You played on Windows98 or linux? I tryied on W98.

Quote:

Originally Posted by sPlOrYgOn
1 CT can keep that 1 way door open while the other CTs get the hostages and run back through the door...

Yes - it's true, but only theoreticaly...I 've tryied this new WP system - I made one connection across the door (from outside to inside) and bot should press "use" to open the door (but I didn't put the flag "use button" at this WP in front of this door - like PMB suggested) - bot get stuck. They never try "use" if they can't see a button. This door hasn't a button , but to open - You have press "use". I also tryied with this flag "use button" - the same effect - bot is not able to open this door. Probably here is something to do in the code, too.... This is probably thing for separate thread...=)

But back to the topic - what can I do more to give You the possiblity to reproduce this bug at You computer? Maybe it's possible somebody also will try this map - if at his computer under Windows system the game will crash or not. I've tryied at two windows computers - allways crash. Anobody can help? I can send this map via e'mail if you don't have.:(

[EDIT]
I just tryied this map and this pwf with CS1.6 - crash the same for sure under Win98.
[/EDIT]

sPlOrYgOn 29-05-2004 23:05

Re: Permanent crash on cs_bigbrother_beta1
 
strange I just try this morning and it crashes as soon as a bot joins...
I turn on my debugger and it says it's crashing in the function IsAlive...
Code:

bool IsAlive (edict_t *pEdict)
{
  return ((pEdict->v.deadflag == DEAD_NO)
          && (pEdict->v.health > 0)
          && (pEdict->v.movetype != MOVETYPE_NOCLIP));
}

so small...
right now I'm testing this piece of code and I've changed it to
Code:

bool IsAlive (edict_t *pEdict)
{
  return ((pEdict->v.deadflag & DEAD_NO)
          && (pEdict->v.health > 0)
          && (pEdict->v.movetype != MOVETYPE_NOCLIP));
}

and It hasn't crashed yet..

[edit]
I think I can call it fixed now :D
maybe I might upload another BETA dll for you to try later on today...
[/edit]

[edit2]
aww no wonder..
now they all think they're dead...
time to get at it again..
[/edit2]

[edit3]
strange...
it crashes there when I change it to
Code:

bool IsAlive (edict_t *pEdict)
{
  return (!(pEdict->v.deadflag & DEAD_NO)
          && (pEdict->v.health > 0)
          && (pEdict->v.movetype != MOVETYPE_NOCLIP));
}

I've even tried
Code:

bool IsAlive (edict_t *pEdict)
{
  if (FNullEnt (pEdict))
      return (FALSE);
  return ((pEdict->v.deadflag == DEAD_NO)
          && (pEdict->v.health > 0)
          && (pEdict->v.movetype != MOVETYPE_NOCLIP));
}

still no luck..
[/edit3]

[edit4]
I don't really think it crashes here but it's the place the debugger tells me..
[/edit4]

Pierre-Marie Baty 30-05-2004 01:33

Re: Permanent crash on cs_bigbrother_beta1
 
What's on the call stack before IsAlive() ? My guess is that the problem lies in the function before.

Whistler 30-05-2004 02:01

Re: Permanent crash on cs_bigbrother_beta1
 
try changing it to:
Code:

bool IsAlive (edict_t *pEdict)
{
  if (FNullEnt(pEdict)) // added this
      return FALSE;      // added this
  return ((pEdict->v.deadflag == DEAD_NO)
          && (pEdict->v.health > 0)
          && (pEdict->v.movetype != MOVETYPE_NOCLIP));
}

*edit*: added some comments to show difference ;)

*edit2*: oops.... you have already tried this code...
Perhaps there's some invalid memory access in your code. Invalid memory access usually can cause weird crashes *elsewhere*.

sPlOrYgOn 30-05-2004 02:15

Re: Permanent crash on cs_bigbrother_beta1
 
@PMB: k I'll try that when i get the chance..

@Whistler: I fail to see the difference...

[edit]
@kWO: sorry but I found the problem to my crash and it didn't have anything to do with yours because I cannot crash on your map specificly..
This crash I was talking about was a mistake I made.. and it was happening on all maps except when I was testing your map I thought I was finally able to reproduce it...
I'll need more information from you so I can reproduce the crash you're getting..
[/edit]

[edit2]
and what i did was a memory problem :D
just that I forgot I did it..
[/edit2]

sPlOrYgOn 30-05-2004 07:20

Re: Permanent crash on cs_bigbrother_beta1
 
Okay now I'm confused...
I think I can finally get kWO's crash..
even tho I've changed nothing..

well the info I have about crash right now is that it has something to do with one of Vector's constructors...
because thats where the debugger is stoping now...
or maybe it's another memory error...

Pierre-Marie Baty 30-05-2004 15:13

Re: Permanent crash on cs_bigbrother_beta1
 
What's the call stack ?
You can usually narrow down bugs easily if you get one or two levels up the stack. Post the call stack here and we'll look into it.

sPlOrYgOn 30-05-2004 17:40

Re: Permanent crash on cs_bigbrother_beta1
 
alright I got the call stack :)
Quote:

PODBOT_MM! Vector::Vector(class Vector const &) + 13 bytes
PODBOT_MM! BotSetConditions(struct bot_t *) + 4729 bytes
PODBOT_MM! BotThink(struct bot_t *) + 2042 bytes
PODBOT_MM! StartFrame(void) + 1329 bytes
METAMOD! 098cac8b()
SWDS! 06416d39()
SWDS! 06412613()
SWDS! 063c8601()
HLDS! 00401924()
so each time a function is called it gets added to the top?
if so then the screwed up call to Vector is in BotSetConditions :)
time to look through it...

[edit]
I have now narrowed it down to the check if it is a good idea to throw a nade...
[/edit]

[edit2]
even more specific.. the HE nade checking part...
[/edit2]

[edit3]
I found it!!! 8)
Code:

// Returns all Waypoints within Radius from Position
void WaypointFindInRadius (Vector vecPos, float fRadius, int *pTab, int *iCount)
{
  int i, iMaxCount;
  float distance;

  iMaxCount = *iCount;
  *iCount = 0;

  for (i = 0; i < g_iNumWaypoints; i++)
  {
      distance = (paths[i]->origin - vecPos).Length ();

      if (distance < fRadius)
      {
        *pTab++ = i;
        *iCount++;

        if (*iCount == iMaxCount)
            break;
      }
  }

  *iCount--;
  return;
}

should be
Code:

// Returns all Waypoints within Radius from Position
void WaypointFindInRadius (Vector vecPos, float fRadius, int *pTab, int *iCount)
{
  int i, iMaxCount;
  float distance;

  iMaxCount = *iCount;
  *iCount = 0;

  for (i = 0; i < g_iNumWaypoints; i++)
  {
      distance = (paths[i]->origin - vecPos).Length ();

      if (distance < fRadius)
      {
        *pTab++ = i;
        (*iCount)++;

        if (*iCount == iMaxCount)
            break;
      }
  }

  (*iCount)--;
  return;
}

:D simple problem of operator precedences :D
I think it was incrementing the actual address of iCount... which wouldn't be nice since iCount isn't an array...
[/edit3]

KWo 31-05-2004 10:05

Re: Permanent crash on cs_bigbrother_beta1
 
Congratulations, sPlOrYgOn!!! :D
What exactly is meaning this bug You found? Is this - if one WP with big radius is in area of another WP with big radius - here was some problem?
Can You upload new beta dll for trying at this map? Or You can send me it via e'mail - if it's possible? ;)

Whistler 01-06-2004 12:12

Re: Permanent crash on cs_bigbrother_beta1
 
looks like this is PMB's fault.
the original PB code is:
Code:

// Returns all Waypoints within Radius from Position
void WaypointFindInRadius(Vector vecPos,float fRadius,int *pTab,int *iCount)
{
        int i,iMaxCount;
        float distance;
       
        iMaxCount = *iCount;
        *iCount = 0;
       
        for (i=0; i < g_iNumWaypoints; i++)
        {
               
                distance = (paths[i]->origin - vecPos).Length();
               
                if (distance < fRadius)
                {
                        *pTab++ = i;
                        *iCount += 1;
                        if(*iCount == iMaxCount)
                                break;
                }
        }
        *iCount -= 1;
}


Pierre-Marie Baty 01-06-2004 14:13

Re: Permanent crash on cs_bigbrother_beta1
 
I concede, I concede :)
That'll teach me to change stuff here and there randomly :D


All times are GMT +2. The time now is 13:11.

Powered by vBulletin® Version 3.8.2
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.