Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
110 commits
Select commit Hold shift + click to select a range
787309b
Clean up
anongit Mar 24, 2020
b665cde
Bug fixes
anongit Mar 24, 2020
6e11a94
Put the portraits on top of the mage spellbook
anongit Mar 25, 2020
e38aa64
Fix cropped text in the combat log
anongit Mar 25, 2020
6f458a7
Fix quickloot highlight for magical items
anongit Mar 25, 2020
576c3bd
Added an option to continue conversations on space key
anongit Mar 25, 2020
10abef5
Save position of enhanced dialog between restarts
anongit Mar 25, 2020
866ce1c
Fixed info for dual classes in the Record screen
anongit Mar 25, 2020
f56ca0a
Compatibility with SCS IWD spells component
anongit Mar 25, 2020
daa547e
Clean up mage and priest spellbooks
anongit Mar 25, 2020
3c017a7
Rewrite of inventory handling code
anongit Mar 26, 2020
e1a54c8
Partially update to SoD v2.5.17.0
anongit May 18, 2020
d5bb775
Merge updates from SoD v2.5.17.0
anongit May 18, 2020
3a871fa
Add some missing images to BG2
anongit May 19, 2020
3674035
Fix crash when swapping items on the ground
anongit May 22, 2020
4c4ac97
Move DUI changes in BGEE.lua into M_dui.lua
anongit May 25, 2020
dd54bb6
Add support for EET
anongit May 25, 2020
25ebb3e
Fix missing NPC epilogues for BG2/EET
anongit Sep 25, 2020
7a16f1d
Add ability to change companions' appearance
anongit Oct 2, 2020
3952c08
Pause inventory during character color selection
anongit Oct 2, 2020
f341c6a
Add scrollbar for the kit selection screen
anongit Oct 2, 2020
b8ff636
Better handling character selection in inventory
anongit Oct 2, 2020
9703308
Hide quickloot in arcane spellbook screen
anongit Oct 3, 2020
13ec9c5
Fix nil errors
anongit Oct 4, 2020
9feed98
Chargen breaks with import and random characters
anongit Oct 4, 2020
f798732
Rename load screen button Load -> Import if importing
anongit Oct 4, 2020
893eb58
Remove start_campaign_select from bg2 / eet
anongit Oct 4, 2020
08b1229
Adjust World Map size for BG2 / EET
anongit Oct 4, 2020
2ed7e13
Fix typo PriestScreen -> priestScreen
anongit Oct 4, 2020
f5ba6a6
Fix character info visibility logic
anongit Oct 5, 2020
6b61b4f
Fix index typo in CHARGEN_CHOOSE_SPELL
anongit Oct 5, 2020
095a904
Fix nil errors in chargen_choose_spells
anongit Oct 5, 2020
c545c00
Fix: escape key during auto-roll breaks chargen
anongit Oct 6, 2020
c434bd9
Make spellbooks scrollable
anongit Oct 6, 2020
0389f7d
Improve performance of spellbooks
anongit Oct 6, 2020
ce78e8b
Fix typo in a spell contingency label
anongit Oct 7, 2020
0804a55
Add scrolling to CHARGEN_CHOOSE_SPELL screen
anongit Nov 8, 2020
d8c8727
Updates from v2.6.5.0
anongit Apr 21, 2021
fedaaa3
Simplify save/restore management of enhanced dialog
anongit May 1, 2021
c0cda2c
Fix portrait misalignment in enhanced world dialog
anongit May 1, 2021
561c146
Fix voice selection order
anongit Jul 22, 2021
735cd62
Updates from v2.6.6.0 and minor fix in priest book
anongit Jul 25, 2021
60feb4b
Fix cancel button in quit popup
anongit Jul 25, 2021
4cdaa0c
Don't break portrait picker on undefined BGImages
anongit Jul 25, 2021
e2a3ec4
Possibly fix crash in Infinity_GetArea
anongit Jul 25, 2021
9f8cfb6
Rework language files system
anongit Jul 25, 2021
25baf9c
Update DUI strings on UI reload (aka F5)
anongit Jul 25, 2021
68fad67
Optimize png images using ect
anongit Jul 25, 2021
ff3fa3f
Delete old menu files
anongit Jul 25, 2021
5633522
Improve Russian translation
anongit Jul 25, 2021
41656b7
Fix installer
anongit Jul 25, 2021
bb82c08
Switch to calendar versioning
anongit Jul 26, 2021
9ad0607
Don't reset message box history on open
anongit Jul 27, 2021
08828db
Move sidebar backgrounds to their original place
anongit Jul 28, 2021
c3aa942
Remove stray Infinity_GetArea()
anongit Jul 29, 2021
dfb51d6
EET start menu changes
anongit Jul 29, 2021
439ca04
Optional equipment comparison
anongit Jul 29, 2021
af7f442
Journal improvements
anongit Jul 30, 2021
098434e
Optional one-click world travel
anongit Jul 30, 2021
3e1efc6
Fix tooltips when large journal is open
anongit Jul 31, 2021
070edc7
Inventory: avoid extra updateStats calls
anongit Jul 31, 2021
965a69e
Bump version
anongit Jul 31, 2021
dc38da6
Fix status effect icons
anongit Aug 9, 2021
de0ec0a
Make done button clickable on valid item count
anongit Aug 10, 2021
a22bec0
Fix blurry portraits for some characters
anongit Aug 10, 2021
8f1ec84
Bump version
anongit Aug 10, 2021
8a995b1
Fix missing backgrounds in the Ulgoth’s Beard narration
anongit Aug 13, 2021
da7a74a
Update polish.tra
ALIENQuake Aug 19, 2021
aae3798
Merge pull request #1 from ALIENQuake/patch-1
anongit Aug 19, 2021
030d0a3
Add Brazilian Portuguese translation
Felipefpl Aug 22, 2021
91bafa7
BG2: add missing slider background BAM file
anongit Sep 5, 2021
0a408f1
Make multi-portrait picker enabled by default
anongit Sep 5, 2021
9adbdef
Fix a crash in list portrait picker
anongit Sep 6, 2021
daa9d15
Fix proficiency help string ref for BG2/EET
anongit Sep 7, 2021
b9335e5
Bump version
anongit Sep 9, 2021
30ba82e
Don't try to unlearn known spells when leveling up
anongit Oct 13, 2021
25b0849
Fix a typo in the russian translation
anongit Oct 21, 2021
cb84dd5
Update LD_ru_RU.LUA
abalabokhin Nov 29, 2021
3344e2d
Merge pull request #3 from abalabokhin/patch-1
anongit Dec 3, 2021
a77211a
Ensure images exist before adding them to portraits
anongit Dec 21, 2021
ca1d618
Update WeiDU to v249
anongit Dec 21, 2021
0f73cf7
Bump version
anongit Dec 21, 2021
fc3aa32
Add missing popup background assets for BG2/EET
anongit Dec 22, 2021
e01523d
World dialog fixes
anongit Dec 27, 2021
2a7ed61
Bump version
anongit Dec 27, 2021
8cfb5e8
Setup build system for UI.menu file
anongit Dec 27, 2021
a39e245
Add the original DUI inventory
anongit Dec 28, 2021
17be5b9
Fix removal of mage spells
anongit Dec 28, 2021
c7e8e30
Use hotkey provided by user for permanent thieving button
anongit Dec 29, 2021
31e58f4
Better error handling in the build script
anongit Dec 29, 2021
ca43b39
Add left side portraits feature
anongit Dec 29, 2021
efe5e80
Simplify UI settings
anongit Dec 30, 2021
9a13bca
Use the same round button bam for all games
anongit Dec 30, 2021
3b97076
Change defaults for the item amount popup
anongit Dec 30, 2021
ed207ea
UI for "disable space key in conversations" option
anongit Dec 30, 2021
87cbcd5
Remove unused files
anongit Dec 31, 2021
97bc1ac
Add support for BG:EE
anongit Dec 31, 2021
f842c1c
Code clean up
anongit Dec 31, 2021
2548535
Bump version
anongit Jan 1, 2022
8e59ff4
Russian translation changes
anongit Jan 1, 2022
e868304
Restore campaigns menu label
anongit Jan 1, 2022
312b15e
Fix regression with classic dialog and message history
anongit Jan 1, 2022
ea18170
Bump version
anongit Jan 1, 2022
2819b3d
Make sure message history is hidden with classic dialog
anongit Jan 1, 2022
a98a317
Fix regression in restoring settings on start
anongit Jan 2, 2022
1410fe1
Bump version
anongit Jan 2, 2022
2a0fa37
Add "select all" buttons to STORE_BUYSELL
anongit Jan 12, 2022
9af2d15
Menu campaign strings translations
anongit Jan 12, 2022
6911af6
World dialog fixes
anongit Jan 13, 2022
d86bddd
Bump version
anongit Jan 27, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
Binary file added dragonspear_ui++/bin/amd64/lua.exe
Binary file not shown.
Binary file added dragonspear_ui++/bin/amd64/lua53.dll
Binary file not shown.
4 changes: 4 additions & 0 deletions dragonspear_ui++/bin/build.bat
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
@echo off

cd dragonspear_ui++\menu
..\bin\%1\lua ..\bin\build.lua %2.lua ..\build\ui.menu
235 changes: 235 additions & 0 deletions dragonspear_ui++/bin/build.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,235 @@
-- This is a pretty dumb script.
-- It just replaces text files like this:
--
-- #if value == 'something' then
-- hello, `username`
-- #end
--
-- more or less with this:
--
-- if value == 'something' then
-- print("hello", username, "")
-- end
--
-- And then executes the result with the Lua interpreter.
--
-- It gets variables, e.g. "value" above, from the input
-- lua file and the OS enviroment, the latter is only if
-- prefixed with "DUI_", the prefix is stripped.
--

if not _ENV then
print('This mod requires Lua 5.2+, found ' .. _VERSION)
os.exit(42)
end

function main(argv)
if #argv < 2 then
print("Usage: lua build.lua <input> <output>")
os.exit(1)
end

-- setup the environment for script execution
local env = {}
local ignore = Set({
'arg', 'collectgarbage', '_G', '_ENV', 'pcall', 'xpcall',
'main', 'process_text_chunk', 'generate_lua_script',
})

for k, v in pairs(_ENV) do
if not ignore[k] then
env[k] = v
end
end

env.include = function(filename)
local f = assert(loadfile(filename, 't', env))
return f()
end

local load_config = assert(loadfile(argv[1], 't', env))
local config = load_config()
assert(type(config and config.files) == 'table')

-- global variables from OS environment
for k, v in pairs(getenv()) do
if k:sub(1, 4) == 'DUI_' then
env[k:sub(5)] = v
end
end

local output = assert(io.open(argv[2], "w"))
local buffer = {}

env.output = output
env.buffer = buffer
env['_'] = function(...)
table.insert(buffer, table.concat({ ... }))
end

local is_lua = function(f)
return f:match('.lua$') and true or false
end

for is_lua, group in groupby(config.files, is_lua) do
for i, filename in ipairs(group) do
env['__file__'] = filename

local file = assert(io.open(filename, 'r'))
local script = generate_lua_script(file)
file:close()

-- useful for debugging
local script_file = assert(io.open(argv[2] .. ".lua", "w"))
script_file:write(script)
script_file:close()

local run_script = assert(load(script, filename, "t", env))

run_script()
end

if #buffer > 0 then
local text = table.concat(buffer)

if is_lua then
output:write('`\n')
output:write(text)
output:write('`\n')
else
output:write(text)
end

table.clear(buffer)
end
end

output:close()
end

function table.clear(t)
local count = #t
for i = 0, count do
t[i] = nil
end
end

function process_text_chunk(buf, sink)
if #buf == 0 then
return
end

local input = table.concat(buf)
local is_lua = false
local code = '%q'

table.insert(sink, '_(');
for slice in input:gmatch('([^`]+)`?') do
if is_lua then
table.insert(sink, slice)
else
table.insert(sink, code:format(slice))
end
table.insert(sink, ',');
is_lua = not is_lua
end
table.insert(sink, '"");\n');
end

function generate_lua_script(file, script)
local buf = {}
local script = { 'if type(init) == "function" then init() end\n' }

for line in file:lines() do
local is_preprocessor, text = line:match('^%s*(#?)(.*)$')
if #is_preprocessor > 0 then
process_text_chunk(buf, script)
buf = {}

if #text > 0 then
table.insert(script, text)
table.insert(script, '\n')
end
else
table.insert(buf, line)
table.insert(buf, '\n')
end
end

process_text_chunk(buf, script)

return table.concat(script)
end

function Set(list)
local s = {}
for _, v in ipairs(list) do
s[v] = true
end
return s
end

function getenv()
local env = {}

for line in io.popen("set"):lines() do
local key = line:match("^[^=]+")
if key then
env[key] = os.getenv(key)
end
end

return env
end

function iter(value)
local t = type(value)
if t == 'function' then
return value
elseif t ~= 'table' then
error('Type error, expected table, got: ' .. t)
end

local i = 0
local n = #value

return (function()
i = i + 1
if i <= n then
return value[i]
end
end)
end

function groupby(iterable, key)
local cgroup, ckey = {}, nil

iterable = iter(iterable)

return (function()
while true do
local item = iterable()
if not item then
if cgroup and #cgroup > 0 then
local rkey, rgroup = ckey, cgroup
cgroup, ckey = nil, nil
return rkey, rgroup
end
return
end

local k = key(item)
if k ~= ckey then
local rkey, rgroup = ckey, cgroup
cgroup, ckey = { item }, k
if #rgroup > 0 then
return rkey, rgroup
end
else
table.insert(cgroup, item)
end
end
end)
end

main(arg)
6 changes: 6 additions & 0 deletions dragonspear_ui++/bin/build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
#!/usr/bin/env sh

[ -x "$(command -v lua)" ] || exit 42

cd 'dragonspear_ui++/menu'
lua '../bin/build.lua' "$1.lua" '../build/ui.menu'
Binary file added dragonspear_ui++/bin/x86/lua.exe
Binary file not shown.
Binary file added dragonspear_ui++/bin/x86/lua53.dll
Binary file not shown.
Loading