Jump to content
Sign in to follow this  

GemRB/TobEx opcode 318 (0x13e) differences

Recommended Posts

Another FYI:


Latest gemrb from git, files affected:

// 0x13e ChangeWeather
// sets the weather to param1, set it to:
// 0 normal weather
// 1 rain
// 2 snow
// 3 fog

0x13e ChangeWeather

5          SPWM105    0x13e      *

Latest TobEx, files affected:

#318 (0x13E)  Stat: Set stat [318]
Parameter #1: Statistic Modifier
Parameter #2 low: Stat Opcode
Parameter #2 high: Type

After Sword Coast Strategems install this entry is found in console log:

[Unknown]: fx_change_weather(318): P1: 1

Rain is present upon most level transitions, acompanied by either a mind-numbingly loud thunder-crack or the sound of a door slamming shut.

Full Baldur's Gate Trilogy install with BG1/2 pre-patched to recommended version (Atari DnD Anthology). Manual install of mods in this order; BiG word fixpack v17, Baldur's Gate Trilogy 118, ScS v30, lolfixer github, generalized biffing, widescreen 3.07.

Clearly there is a difference in the way effect opcode 318 (0x13E) is being implemented by GemRB and TobEx. ScS appears to use this in its core components.

Share this post

Link to post

First, you're not comparing the same thing. Tobex doesn't do anything to this opcode, since it wasn't present in the engine before ee. It has a different opcode at that address (Stat: Set stat), the new one is at 0x140.


Installing tobex doesn't affect gemrb, but this is about the numbering collision, since the ids files are in conflict. And then missing functions — I think the new setstat is just for the extra mode that ensures ordering.


That log line is perfectly fine.

Share this post

Link to post

GemRB is pretty flexible to reassign the opcode numbers, though. So, if it implements an opcode (it does implement weather), you can make it mimic both TobEx or EE.

Share this post

Link to post

Yeah, I'll just fix that one spell it was created for and assign it a higher number — it predates ee. It's the only conflicting id on the tobex list too.

Share this post

Link to post

Ok, both things should work now. ChangeWeather has the same id and SetStat is supported (though tobex made it very limited).


Couldn't grep any uses in SCS though, so ???

Share this post

Link to post
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Create New...