Jump to content

Can't select missle quivers or wand mode for BG1


bobdrad

Recommended Posts

I'm using v0.8.4, which I believe is the latest, with BG1. No mods. Built from source, running on Fedora 23.

 

One thing that is very annoying is that I am unable to select between my various quivers of arrows/rocks, and I can't use any wand modes but the primary.

 

Normally, I should be able to right-click on my character's main screen on his equipped weapon and if it's a bow or a sling I get to see each quiver and select the one I want. That way for example if I have some exploding arrows in one quiver I don't have to use them all the time.

 

Likewise for certain wands such as the Wand of Fire, there are two modes - in this case fireball and Aganazzar's Scorcher, and I can select which one I want to use.

 

But with GemRB I only ever see one quiver of missiles, and one wand mode.

 

Is there a fix for this? Known limitation?

 

I see an old thread "Chiv's usability patches" that seems to talk about fixing the quiver issue, but that's several years ago and presumably would be rolled into the latest version. Am I misunderstanding something?

http://gibberlings3.net/forums/index.php?showtopic=23461&p=193178

 

Thanks,

Bob

Link to comment

there is apparently a tooltip related regression, so we bail out after setting up the first quiver. You can use this (not committed yet):

diff --git a/gemrb/GUIScripts/GUICommonWindows.py b/gemrb/GUIScripts/GUICommonWindows.py
index 3dc319b..cf5edba 100644
--- a/gemrb/GUIScripts/GUICommonWindows.py
+++ b/gemrb/GUIScripts/GUICommonWindows.py
@@ -551,7 +551,8 @@ def SetupItemAbilities(pc, slot):
                                        Button.SetEvent (IE_GUI_BUTTON_ON_PRESS, SelectQuiverSlot)
                                        Button.SetEvent (IE_GUI_BUTTON_ON_RIGHT_PRESS, SelectQuiverSlot)
                                        Button.SetVarAssoc ("Slot", ammoslots[i])
-                                       Button.SetTooltip ("%s" % (GemRB.GetString (Tips[0])))
+                                       if Tips[0] != -1:
+                                               Button.SetTooltip (Tips[0])
                                        print currentammo, i+1, ammoslots[i]
                                        if currentammo == ammoslots[i]: # this check is ok, but the results are unreliable?!
                                                Button.SetState (IE_GUI_BUTTON_SELECTED)

Item abilities are a different matter — it's hard to decide which to skip in which context, but I should have something better up within the day.

Link to comment

Ok, it's done. Unfortunately for you, it also required a change in core, so a rebuild from git is needed if you want to change the wand that often (still works via inventory).

Link to comment

Wow -thanks for the fast work! Wish I'd reported it earlier, this had been broken for a long time.

 

What do you mean "rebuild from git"? I built from source anyway, although it was tarball not git. Can you give me steps please, including git URL?

 

Thanks again,

Bob

Link to comment

I can't build it. I get:

 


% make -j2
[  1%] [  1%] Building CXX object gemrb/core/CMakeFiles/gemrb_core.dir/GameScript/Actions.cpp.o
Building CXX object gemrb/core/CMakeFiles/gemrb_core.dir/GameScript/GSUtils.cpp.o
In file included from /home/rad/GemRB/gemrb-trunk-16-04-03/gemrb/gemrb/core/GameScript/GSUtils.cpp:27:0:
/home/rad/GemRB/gemrb-trunk-16-04-03/gemrb/gemrb/includes/voodooconst.h:57:27: error: 'GemRB::___MOD' defined but not used [-Werror=unused-variable]
 static const unsigned int ___MOD = MAX_OPERATING_DISTANCE; // just to silence var-unused errors
                           ^
cc1plus: all warnings being treated as errors
gemrb/core/CMakeFiles/gemrb_core.dir/build.make:2078: recipe for target 'gemrb/core/CMakeFiles/gemrb_core.dir/GameScript/GSUtils.cpp.o' failed
make[2]: *** [gemrb/core/CMakeFiles/gemrb_core.dir/GameScript/GSUtils.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
In file included from /home/rad/GemRB/gemrb-trunk-16-04-03/gemrb/gemrb/core/GameScript/Actions.cpp:26:0:
/home/rad/GemRB/gemrb-trunk-16-04-03/gemrb/gemrb/includes/voodooconst.h:57:27: error: 'GemRB::___MOD' defined but not used [-Werror=unused-variable]
 static const unsigned int ___MOD = MAX_OPERATING_DISTANCE; // just to silence var-unused errors
                           ^
cc1plus: all warnings being treated as errors
gemrb/core/CMakeFiles/gemrb_core.dir/build.make:2055: recipe for target 'gemrb/core/CMakeFiles/gemrb_core.dir/GameScript/Actions.cpp.o' failed
make[2]: *** [gemrb/core/CMakeFiles/gemrb_core.dir/GameScript/Actions.cpp.o] Error 1
CMakeFiles/Makefile2:198: recipe for target 'gemrb/core/CMakeFiles/gemrb_core.dir/all' failed
make[1]: *** [gemrb/core/CMakeFiles/gemrb_core.dir/all] Error 2
Makefile:117: recipe for target 'all' failed
make: *** [all] Error 2
Link to comment

No that's not working either because this is in a template. I actually had to do a few things to get this to build:

 

I used the __attribute__((unused)) notation in a couple of places to suppress the warnings. That might be gcc-specific so I don't know if it's appropriate on all platforms you build for.

https://gcc.gnu.org/onlinedocs/gcc-3.2/gcc/Variable-Attributes.html

 

I also had to fix a couple of boolean expressions that the compiler flagged as suspicious. They did in fact look wrong to me ('!' binds more tightly than '&' - best to use parens liberally).

 

I am using:

gcc (GCC) 5.3.1 20151207 (Red Hat 5.3.1-2)

 

AmbientMgrAL.cpp: http://pastebin.com/LjWvymYw

GUIScript.cpp: http://pastebin.com/xZytsN61

voodooconst.h: http://pastebin.com/Kfe7AFjH

plugindef.h: http://pastebin.com/mr9dz3fw

 

Full patch: http://pastebin.com/yzZyxWi9

Link to comment

One note about Item Abilities. There doesn't appear to be any way to tell which item ability is selected, at least from the action screen. I believe that in the game there are labels displayed for each ability in the right-click menu beneath the icon, and the currently active ability is highlighted somehow.

 

Also, if you go into the Item Abilities via the Inventory screen, when you select an ability other than the first one, there's no visual indication of the change - the first ability remains highlighted with the button. In fact you do change the currently active ability, but there's no way to tell that.

Link to comment

great, thanks! I'm stuck with an old toolchain on this machine and apparently everyone else is also on older gcc or clang. Do you have a preferred name and email under which we can credit you (=author string in the log)?

 

Abilities:

- it's a button border and it's working fine for quick items (think wand of fire), but is currently missing for quick weapons (mostly quivers)

- except in bg1 (all this code is shared, so perhaps it lacks the resources)

- inventory: works fine in bg2, looks like it's specific to others (not all inventory code is shared)

 

Something for another day.

Link to comment

great, thanks! I'm stuck with an old toolchain on this machine and apparently everyone else is also on older gcc or clang. Do you have a preferred name and email under which we can credit you (=author string in the log)?

 

Abilities:

- it's a button border and it's working fine for quick items (think wand of fire), but is currently missing for quick weapons (mostly quivers)

- except in bg1 (all this code is shared, so perhaps it lacks the resources)

- inventory: works fine in bg2, looks like it's specific to others (not all inventory code is shared)

 

Something for another day.

 

This is a really trivial fix, so I don't care so much about credit. But you can use "Bob Doolittle" and "gemrb.bobd@dfgh.net" if you like.

 

-Bob

Link to comment

Actually one more issue - with this build I am no longer getting any sound.

 

During startup I see this:

[Core]: Starting up the Sound Driver...
[OpenAL]: Initializing OpenAL driver:
AL Version:(null)
AL Renderer:(null)
AL Vendor:(null)

Do I have to do anything special to migrate over to a GIT build?

 

I just did a "make -j4" and then "sudo make install"

 

I also see this:

[PluginLoader]: Loaded plugin "IDS File Importer" (IDSImporter.so).
[PluginLoader]: Loaded plugin "PRO File Importer" (PROImporter.so).
[PluginLoader]: Loaded plugin "Null Sound Driver" (NullSound.so).
[PluginLoader]: Loaded plugin "Effect opcodes for the icewind branch of the games" (IWDOpcodes.so).
[PluginLoader]: Loaded plugin "Effect opcodes for core games" (FXOpcodes.so).
[PluginLoader]: Loaded plugin "BMP File Reader" (BMPImporter.so).
[PluginLoader]: Loaded plugin "MUS File Importer" (MUSImporter.so).
[PluginLoader]: Loaded plugin "TLK File Importer" (TLKImporter.so).
[PluginLoader]: Loaded plugin "DLG File Importer" (DLGImporter.so).
[PluginLoader]: Loaded plugin "WAV File Importer" (WAVReader.so).
[PluginLoader]: Loaded plugin "BIK Video Player" (BIKPlayer.so).
[PluginLoader]: Loaded plugin "SPL File Importer" (SPLImporter.so).
[PluginLoader]: Loaded plugin "INI File Importer" (INIImporter.so).
[PluginLoader]: Loaded plugin "TIS File Importer" (TISImporter.so).
[PluginLoader]: Loaded plugin "WMP File Importer" (WMPImporter.so).
[PluginLoader]: Loaded plugin "ITM File Importer" (ITMImporter.so).
[PluginLoader]: Loaded plugin "MVE Video Player" (MVEPlayer.so).
[PluginLoader]: Loaded plugin "BAM File Importer" (BAMImporter.so).
[PluginLoader]: Loaded plugin "Null Resource Source" (NullSource.so).
[PluginLoader]: Loaded plugin "MOS File Importer" (MOSImporter.so).
[PluginLoader]: Loaded plugin "Directory Importer" (DirectoryImporter.so).
[PluginLoader]: Loaded plugin "PLT File Importer" (PLTImporter.so).
[PluginLoader]: Loaded plugin "SDL1 Video Driver" (SDLVideo.so).
[PluginLoader]: Loaded plugin "GUI Script Engine (Python)" (GUIScript.so).
[PluginLoader]: Loaded plugin "CRE File Importer" (CREImporter.so).
[PluginLoader]: Loaded plugin "KEY File Importer" (KEYImporter.so).
[PluginLoader]: Loaded plugin "CHU File Importer" (CHUImporter.so).
[PluginLoader]: Loaded plugin "ZLib Compression Manager" (ZLibManager.so).
[PluginLoader]: Loaded plugin "STO File Importer" (STOImporter.so).
[PluginLoader]: Loaded plugin "BIF File Importer" (BIFImporter.so).
[PluginLoader]: Loaded plugin "ACM File Importer" (ACMReader.so).
[PluginLoader]: Loaded plugin "Effect opcodes for the torment branch of the games" (PSTOpcodes.so).
[PluginLoader]: Loaded plugin "SAV File Importer" (SAVImporter.so).
[PluginLoader]: Loaded plugin "WED File Importer" (WEDImporter.so).
[PluginLoader]: Loaded plugin "GAM File Importer" (GAMImporter.so).
[PluginLoader]: Loaded plugin "OGG File Importer" (OGGReader.so).
[PluginLoader]: Loaded plugin "PNG File Importer" (PNGImporter.so).
[PluginLoader]: Loaded plugin "BMP File Writer" (BMPWriter.so).
[PluginLoader]: Loaded plugin "EFF File Importer" (EFFImporter.so).
[PluginLoader]: Loaded plugin "TTF Font Importer" (TTFImporter.so).
[PluginLoader]: Loaded plugin "SDL Audio Driver" (SDLAudio.so).
[PluginLoader]: Loaded plugin "2DA File Importer" (2DAImporter.so).
[PluginLoader]: Loaded plugin "OpenAL Audio Driver" (OpenALAudio.so).
[PluginLoader]: Loaded plugin "ARE File Importer" (AREImporter.so).

I do have the openal-soft-devel package installed as well as freealut. I recently did a yum upgrade which I guess could also have affected this (wanted to ensure I had the latest toolchain).

Link to comment

Not all OpenAL implementations populate the version/render/vendor attributes so that might be nothing. We had some recent audio driver work committed in 8aed23e, did your previous working build predate that? I dont see anything more recent that touches audio, unless you mean only specific audio is missing.

Link to comment

I was previously running 0.8.4 release and sound worked. Since then I built the current git build and updated my OS. Either could have made the difference. I might not get time to try different versions until next weekend but if you haven't found anything by then I'll see what I can do (try the release again, try an earlier git Rev, etc).

Link to comment

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...