Discord: https://discord.gg/z4rndWJzwq
 
HomeUseful information for Helbreath beginnersStatistics overviewSearchMemberlistGalleryRulesRegisterLog in

 

 [CODE] Page Bank WH

Go down 
2 posters
AuthorMessage
Zmoky


Zmoky

Civilian
Granted to members for high engagement.
10th Anniversary
Earned after being a member for 10 years.
Silver 2
Earned by having 36 posts & comments.

Likes : 22

[CODE] Page Bank WH Empty
#1PostSubject: [CODE] Page Bank WH   [CODE] Page Bank WH 999103/4/2024, 3:48 am

Code antiguo, basicamente te muestra el warehose en paginas para que este un poco mas ordenado. 

SRC Client 

Game.cpp

Reemplazar todo el :
Code:
void CGame::DrawDialogBox_Bank(short msX, short msY, short msZ, char cLB)

Por:

Code:
void CGame::DrawDialogBox_Bank(short msX, short msY, short msZ, char cLB)//New Edit Bank Page
{
short sX, sY, szX;
  int  iMaxPage, j, i, iLoc;
  char cTotalItems, cItemColor, cStr1[64], cStr2[64], cStr3[64];
  BOOL bFlag;
  DWORD dwTime = timeGetTime();
  sX = m_stDialogBoxInfo[14].sX;
  sY = m_stDialogBoxInfo[14].sY;
  szX = m_stDialogBoxInfo[14].sSizeX - 5;
  DrawNewDialogBox(DEF_SPRID_INTERFACE_ND_GAME2, sX, sY, 2);
  PutString_SprFont(sX+75,sY+13,"Items in Storage",7,0,0);
  cTotalItems = 0;
  iMaxPage = 0;
  for (i = 0; i < 120; i++)
  if (m_pBankList[i] != NULL)
  cTotalItems++;
  iMaxPage = (int)(cTotalItems/12);
  if( iGetTopDialogBoxIndex() == 14 && msZ != 0 )
  { if( msZ > 0 ) m_stDialogBoxInfo[14].sV14--;
 if( msZ < 0 ) m_stDialogBoxInfo[14].sV14++;
 m_DInput.m_sZ = 0;
  }
  if(m_stDialogBoxInfo[14].sV14 < 0)
  m_stDialogBoxInfo[14].sV14 = iMaxPage;
  if(m_stDialogBoxInfo[14].sV14 > 9)
  m_stDialogBoxInfo[14].sV14 = iMaxPage;
  if (m_stDialogBoxInfo[14].sV14 > iMaxPage)
  m_stDialogBoxInfo[14].sV14 = 0;


  m_pSprite[DEF_SPRID_INTERFACE_SPRFONTS]->PutSpriteFast(sX + 30, sY + 305, 19, dwTime);
  switch (m_stDialogBoxInfo[14].sV14)
  { case 0: m_pSprite[DEF_SPRID_INTERFACE_SPRFONTS]->PutSpriteFast(sX + 30, sY + 305, 20, dwTime); break;
 case 1: m_pSprite[DEF_SPRID_INTERFACE_SPRFONTS]->PutSpriteFast(sX + 43, sY + 305, 21, dwTime); break;
 case 2: m_pSprite[DEF_SPRID_INTERFACE_SPRFONTS]->PutSpriteFast(sX + 61, sY + 305, 22, dwTime); break;
 case 3: m_pSprite[DEF_SPRID_INTERFACE_SPRFONTS]->PutSpriteFast(sX + 86, sY + 305, 23, dwTime); break;
 case 4: m_pSprite[DEF_SPRID_INTERFACE_SPRFONTS]->PutSpriteFast(sX + 106, sY + 305, 24, dwTime); break;
 case 5: m_pSprite[DEF_SPRID_INTERFACE_SPRFONTS]->PutSpriteFast(sX + 121, sY + 305, 25, dwTime); break;
 case 6: m_pSprite[DEF_SPRID_INTERFACE_SPRFONTS]->PutSpriteFast(sX + 142, sY + 305, 26, dwTime); break;
 case 7: m_pSprite[DEF_SPRID_INTERFACE_SPRFONTS]->PutSpriteFast(sX + 169, sY + 305, 27, dwTime); break;
 case 8: m_pSprite[DEF_SPRID_INTERFACE_SPRFONTS]->PutSpriteFast(sX + 202, sY + 305, 28, dwTime); break;
 case 9: m_pSprite[DEF_SPRID_INTERFACE_SPRFONTS]->PutSpriteFast(sX + 222, sY + 305, 29, dwTime); break;
  }
  ZeroMemory(cStr1, sizeof(cStr1));
  ZeroMemory(cStr2, sizeof(cStr2));
  ZeroMemory(cStr3, sizeof(cStr3));
  iLoc = 35;
  j = 0;
  switch (m_stDialogBoxInfo[14].cMode)
  { case -1:
 PutString(sX + 30 + 15, sY + 70, DRAW_DIALOGBOX_BANK1, RGB(0,0,0));//"
 PutString(sX + 30 + 15, sY + 85, DRAW_DIALOGBOX_BANK2, RGB(0,0,0));//"
 break;
 case 0:
 bFlag = FALSE;
 for (i = (m_stDialogBoxInfo[14].sV14*12); i < (12+(12*m_stDialogBoxInfo[14].sV14)); i++)
 { if ((m_pBankList[i] != NULL) && (i < DEF_MAXBANKITEMS))
 { GetItemName(m_pBankList[i], cStr1, cStr2, cStr3);
 if ((msX > sX + 30) && (msX < sX + 210) && (msY >= sY + 110 + j*15) && (msY <= sY + 124 + j*15))
 { bFlag = TRUE;
 PutAlignedString(sX, sX+szX, sY + 110 + j*15, cStr1, 255, 255, 255 );
 if (m_bIsSpecial)
 PutAlignedString(sX + 70, sX + szX, sY + iLoc, cStr1, 0, 255, 0 );
 else PutAlignedString(sX + 70, sX + szX, sY + iLoc, cStr1, 4, 0, 50);
 if (strlen(cStr2) > 0)
 { iLoc += 15;
 PutAlignedString(sX + 70, sX + szX, sY + iLoc, cStr2, 0, 200, 200 );
 }
 if (strlen(cStr3) > 0)
 { iLoc += 15;
 PutAlignedString(sX + 70, sX + szX, sY + iLoc, cStr3, 200, 200, 0 );
 }
 if (m_pBankList[i]->m_sLevelLimit != 0 && m_pBankList[i]->m_dwAttribute & 0x00000001)
 { iLoc += 15;
 wsprintf( G_cTxt, "%s: %d", DRAW_DIALOGBOX_SHOP24, m_pBankList[i]->m_sLevelLimit );
 PutAlignedString(sX + 70, sX + szX, sY + iLoc, G_cTxt, 200, 0, 200 );
 }
 if ((m_pBankList[i]->m_cEquipPos != DEF_EQUIPPOS_NONE) && (m_pBankList[i]->m_wWeight >= 10))//New edit by Flavio
 { iLoc += 15;
 int _wWeight = 0;
 if (m_pBankList[i]->m_wWeight%100)
 _wWeight = 1;
 wsprintf( G_cTxt, DRAW_DIALOGBOX_SHOP15, (m_pBankList[i]->m_wWeight) + _wWeight); //New edit by Flavio
 PutAlignedString(sX + 70, sX + szX, sY + iLoc, G_cTxt, 255, 255, 255 );
 }
 if ((m_pBankList[i]->m_cEquipPos != DEF_EQUIPPOS_NONE))
 { wsprintf(G_cTxt, UPDATE_SCREEN_ONGAME10,(m_pBankList[i]->m_wCurLifeSpan));
 PutAlignedString(sX + 70, sX + szX, sY + iLoc+14, G_cTxt, 255, 255, 255 );
 iLoc += 15;
 }
 cItemColor = m_pBankList[i]->m_cItemColor;
 if (cItemColor == 0)
 { m_pSprite[DEF_SPRID_ITEMPACK_PIVOTPOINT + m_pBankList[i]->m_sSprite]->PutSpriteFast(sX+60, sY+68, m_pBankList[i]->m_sSpriteFrame, m_dwCurTime);
 }else
 { if ((m_pBankList[i]->m_cEquipPos == DEF_EQUIPPOS_LHAND) || (m_pBankList[i]->m_cEquipPos == DEF_EQUIPPOS_RHAND) || (m_pBankList[i]->m_cEquipPos == DEF_EQUIPPOS_TWOHAND))
 { m_pSprite[DEF_SPRID_ITEMPACK_PIVOTPOINT + m_pBankList[i]->m_sSprite]->PutSpriteRGB(sX+60, sY+68, m_pBankList[i]->m_sSpriteFrame, m_wWR[cItemColor] -m_wR[0], m_wWG[cItemColor] -m_wG[0], m_wWB[cItemColor] -m_wB[0], m_dwCurTime);
 }else m_pSprite[DEF_SPRID_ITEMPACK_PIVOTPOINT + m_pBankList[i]->m_sSprite]->PutSpriteRGB(sX+60, sY+68, m_pBankList[i]->m_sSpriteFrame, m_wR[cItemColor] -m_wR[0], m_wG[cItemColor] -m_wG[0], m_wB[cItemColor] -m_wB[0], m_dwCurTime);
 }
 }else
 { if (m_bIsSpecial)
 PutAlignedString(sX, sX+szX, sY + 110 + j*15, cStr1, 0, 255, 50 );
 else PutAlignedString(sX, sX+szX, sY + 110 + j*15, cStr1, 0, 0, 0 );
 }
 j++;
 }
 }
 if (bFlag == FALSE)
 { PutAlignedString(sX, sX+szX, sY + 45, DRAW_DIALOGBOX_BANK3);
 PutAlignedString(sX, sX+szX, sY + 60, DRAW_DIALOGBOX_BANK4);
 PutAlignedString(sX, sX+szX, sY + 75, DRAW_DIALOGBOX_BANK5);
 }
 break;
  }
}


Last edited by Zmoky on 3/9/2024, 5:01 am; edited 1 time in total
Back to top Go down
Assax1


Assax1

Silver 4
Earned by having 12 posts & comments.

Likes : 12

[CODE] Page Bank WH Empty
#2PostSubject: Re: [CODE] Page Bank WH   [CODE] Page Bank WH 999103/4/2024, 12:16 pm

gracia por seguir los aporte Santana
Back to top Go down
 
[CODE] Page Bank WH
Back to top 
Page 1 of 1
 Similar topics
-
» Get IP code
» [CODE] FPS Improvement
» [CODE] New Status
» [CODE] Fix Windows 8 - 10
» [CODE] MP,HP,SP, EN COLORES

Permissions in this forum:You cannot reply to topics in this forum
JoinHelbreath.net :: Development :: Code Posting-
Jump to: