mirror of
https://gitlab.com/GaryOderNichts/re3-wiiu.git
synced 2024-12-24 00:31:48 +01:00
fixes
This commit is contained in:
parent
df376a13ea
commit
7e4c683824
2
librw
2
librw
@ -1 +1 @@
|
|||||||
Subproject commit e6c7d910ffc32bc059c4e750a797fde51ee29fd9
|
Subproject commit 4541fe86f7ecb119c6fcb4fde7d08121341ce189
|
@ -491,7 +491,7 @@ CPickups::GenerateNewOne(CVector pos, uint32 modelIndex, uint8 type, uint32 quan
|
|||||||
int32 slot = 0;
|
int32 slot = 0;
|
||||||
|
|
||||||
if (type == PICKUP_FLOATINGPACKAGE || type == PICKUP_NAUTICAL_MINE_INACTIVE) {
|
if (type == PICKUP_FLOATINGPACKAGE || type == PICKUP_NAUTICAL_MINE_INACTIVE) {
|
||||||
for (slot = NUMPICKUPS; slot >= 0; slot--) {
|
for (slot = NUMPICKUPS-1; slot >= 0; slot--) {
|
||||||
if (aPickUps[slot].m_eType == PICKUP_NONE) {
|
if (aPickUps[slot].m_eType == PICKUP_NONE) {
|
||||||
bFreeFound = true;
|
bFreeFound = true;
|
||||||
break;
|
break;
|
||||||
|
@ -1675,13 +1675,7 @@ int8 CRunningScript::ProcessCommands100To199(int32 command)
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
case COMMAND_GENERATE_RANDOM_INT:
|
case COMMAND_GENERATE_RANDOM_INT:
|
||||||
#ifdef FIX_BUGS
|
|
||||||
// Not a very good fix but before switching to PS2 rand, it sort of works
|
|
||||||
*GetPointerToScriptVariable(&m_nIp, VAR_GLOBAL) = CGeneral::GetRandomNumberInRange(0, 65535);
|
|
||||||
#else
|
|
||||||
/* On PC between 0 and 32767, even though script expects values between 0 and 65536 */
|
|
||||||
*GetPointerToScriptVariable(&m_nIp, VAR_GLOBAL) = CGeneral::GetRandomNumber();
|
*GetPointerToScriptVariable(&m_nIp, VAR_GLOBAL) = CGeneral::GetRandomNumber();
|
||||||
#endif
|
|
||||||
return 0;
|
return 0;
|
||||||
case COMMAND_CREATE_CHAR:
|
case COMMAND_CREATE_CHAR:
|
||||||
{
|
{
|
||||||
|
@ -644,4 +644,4 @@ public:
|
|||||||
static_assert(sizeof(CMenuManager) == 0x564, "CMenuManager: error");
|
static_assert(sizeof(CMenuManager) == 0x564, "CMenuManager: error");
|
||||||
|
|
||||||
extern CMenuManager FrontEndMenuManager;
|
extern CMenuManager FrontEndMenuManager;
|
||||||
extern DWORD _dwOperatingSystemVersion;
|
extern unsigned long _dwOperatingSystemVersion;
|
@ -104,6 +104,10 @@ public:
|
|||||||
return m_flags[i].free ? nil : (T*)&m_entries[i];
|
return m_flags[i].free ? nil : (T*)&m_entries[i];
|
||||||
}
|
}
|
||||||
T *GetAt(int handle){
|
T *GetAt(int handle){
|
||||||
|
#ifdef FIX_BUGS
|
||||||
|
if (handle == -1)
|
||||||
|
return nil;
|
||||||
|
#endif
|
||||||
return m_flags[handle>>8].u == (handle & 0xFF) ?
|
return m_flags[handle>>8].u == (handle & 0xFF) ?
|
||||||
(T*)&m_entries[handle >> 8] : nil;
|
(T*)&m_entries[handle >> 8] : nil;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user