Project X Forums
http://px.worms2d.info/forum/

CWorm::^Message pointer to pointer avalanche effect
http://px.worms2d.info/forum/viewtopic.php?f=16&t=678
Page 1 of 1

Author:  Djjeshk [ Sun Sep 08, 2013 8:34 pm ]
Post subject:  CWorm::^Message pointer to pointer avalanche effect

Very strange error that affect all *.pxl libaries, some code fragments that cause error and px errors log.
p_utils.pxl:
Code:
  */utility_conditionsĀ§
override void CWorm::FireFinal(CWeapon* Weap,CShootDesc* Desc) {
  if (Weap->CheckName("Invisibility")) {
     if (Invisible) Invisible = false;
     else Invisible = true;
  } else if (Weap->CheckName("Ninja Rope") || Weap->CheckName("Jet Pack") || Weap->CheckName("Prod") || Weap->CheckName("Bungee") || Weap->CheckName("Skip Go") || Weap->CheckName("Low Gravity") || Weap->CheckName("Fast Walk") || Weap->CheckName("Laser Sign") || Weap->CheckName("Swim Suit") || Weap->CheckName("Helicopter") || Weap->CheckName("Anti FallDamage") || Weap->CheckName("God Mode") || Weap->CheckName("Jump")  || Weap->CheckName("Parkour Mode") || Weap->CheckName("Climb") || Weap->CheckName("Small Worm") || Weap->CheckName("Fat Worm")) {
     if (Invisible) {}
  } else {
     Invisible = false;
  }
  if (Weap->CheckName("Fast Walk")) {
     if (FastWalking) FastWalking = false;
     else FastWalking = true;
  }     
  if(Weap->CheckName("Damage*2"))
  {
     damageX2 = true;
  }                                 
  super;
 
}

override void CWorm::Message(CObject* sender,EMType Type,int MSize,CMessageData* MData) {
super;
local w = GetCurrentWorm();
if (w == NullObj) return;
  if (Type == M_FRAME) {
//     if (Invisible) {
//        hideWorm = true;
//        GS->Disp->RenderSprite( PosX, PosY, currentSpriteIndex, 1.0);// currentSpriteFrame);
//     } else hideWorm = false;
//  if (gframe % 20) {}
//  else
  if (Invisible) {
//   GS->DQueue->AddSprite( 10, PosX, PosY - 20, 0, currentSpriteIndex, currentSpriteFrame);
//    GS->Disp->RenderSprite (PosX - 20, PosY - 20, currentSpriteIndex, currentSpriteFrame);
//    GS->Disp->RenderBitmap( PosX, PosY, MyFile, 250, 250, 400, 400);
//      local a = ItoA(DispSpriteI);
//      local b = ItoA(DispSpriteF);
//      GG->WriteToChat(1 , a, false);
//      GG->WriteToChat(2, b, false);
  }
  }
  if (Type == M_TURNEND)
  {
     if (damageX2) damageX2 = false;
  }
}



More files will be attached...

Author:  Djjeshk [ Sun Sep 08, 2013 8:42 pm ]
Post subject:  Re: CWorm::^Message pointer to pointer avalanche effect

link to all libaries...
http://failiem.lv/u/rlwydur

Author:  PyroMan [ Fri Sep 13, 2013 11:37 am ]
Post subject:  Re: CWorm::^Message pointer to pointer avalanche effect

I see a lot of new libs in list of libs. i mean those with " d_ " prefix.
Probably variable "Invisibility" is redeclared in those libs. So that error may be coused becouse of that.

When error happens?

Author:  Djjeshk [ Tue Sep 17, 2013 9:07 pm ]
Post subject:  Re: CWorm::^Message pointer to pointer avalanche effect

Computer hangs for an moment and tons of errors apears on chat screen. You could look at error log file http://failiem.lv/down.php?i=hhwketx&n= ... errors.txt . I uploaded all libs I have because so many are affected.

Page 1 of 1 All times are UTC
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/