mirror of
https://github.com/1dot13/source.git
synced 2026-08-12 14:10:23 +02:00
Brief: //dnl ch77
- Couple mapeditor and game fixes and radar map creation for any screen resolution. Details: - Radarmap is now possible to create from any mapeditor screen resolution. - Better fix to prevent memory corruption during gWorldItems resize. - Fix problems with losing attached item because attachment slots was not exist when using NAS, also empty slots are removed which was prevent attaching in OAS. - Fix tooltip popup for checkbox when button is disabled and prevent sticky tooltips from taskbar when SummaryWindow is active. - Check if item is valid for 1.12 will be active only for mapeditor, but game will load all items regardless of map version. git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@6652 3b4a5df2-a311-0410-b5c6-a8a6f20db521
This commit is contained in:
@@ -5015,6 +5015,23 @@ BOOLEAN InternalInitItemDescriptionBox( OBJECTTYPE *pObject, INT16 sX, INT16 sY,
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
//dnl ch77 251113 create attachment slots if not exist for NAS or remove empty slots for OAS
|
||||
if(UsingNewAttachmentSystem())
|
||||
{
|
||||
if((*pObject)[ubStatusIndex]->attachments.empty())
|
||||
InitItemAttachments(pObject);
|
||||
}
|
||||
else
|
||||
{
|
||||
attachmentList::iterator iter = (*pObject)[ubStatusIndex]->attachments.begin();
|
||||
while(iter != (*pObject)[ubStatusIndex]->attachments.end())
|
||||
{
|
||||
if((*iter).exists())
|
||||
++iter;
|
||||
else
|
||||
iter = (*pObject)[ubStatusIndex]->attachments.erase(iter);
|
||||
}
|
||||
}
|
||||
|
||||
//Set the current screen
|
||||
guiCurrentItemDescriptionScreen = guiCurrentScreen;
|
||||
|
||||
@@ -1251,7 +1251,11 @@ typedef enum ePOCKET_TYPE
|
||||
#define FIRST_ARMOUR 161
|
||||
#define FIRST_MISC 201
|
||||
#define FIRST_KEY 271
|
||||
#ifdef JA2EDITOR
|
||||
#define OLD_MAXITEMS 351//dnl ch74 191013
|
||||
#else
|
||||
#define OLD_MAXITEMS MAXITEMS
|
||||
#endif
|
||||
#define NOTHING NONE
|
||||
typedef enum
|
||||
{
|
||||
|
||||
@@ -428,7 +428,7 @@ void ResizeWorldItems(void)//dnl ch75 271013
|
||||
gWorldItems.resize(guiNumWorldItems);
|
||||
#else
|
||||
guiNumWorldItems = gWorldItems.size();
|
||||
if(guiNumWorldItems - GetNumUsedWorldItems() < 100)
|
||||
if(guiNumWorldItems - GetNumUsedWorldItems() < 50)
|
||||
{
|
||||
gWorldItems.resize(guiNumWorldItems + 100);
|
||||
guiNumWorldItems = gWorldItems.size();
|
||||
|
||||
Reference in New Issue
Block a user