Skip to content

Commit

Permalink
pallette bugfix
Browse files Browse the repository at this point in the history
graphical bug in cave palette 30
  • Loading branch information
stoffelkopf committed Feb 27, 2024
1 parent fc97f6d commit dea517e
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ Randomizes DevilutionX level palettes
- execute "randomize.bat"
- for default Diablo palettes execute "randclear.bat"

## LUA randomize stead of BATCH random function
## LUA randomize instead of BATCH random function

- download LUA (https://github.com/rjpcomputing/luaforwindows/releases) and copy the files to your DevX folder
- execute "lua54.exe random.lua"
Expand Down
Binary file modified palette/l3data/l3_30.pal
Binary file not shown.
Binary file removed palette/l3data/l3_59.pal
Binary file not shown.
2 changes: 1 addition & 1 deletion random.lua
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ local palette = {
{0,5}, --Town
{0,0,0,0,0,66}, --Church
{0,0,0,0,0,74}, --Catacombs
{0,0,0,0,0,59}, --Caves
{0,0,0,0,0,58}, --Caves
{0,0,0,0,0,46}, --Hell
{0,74}, --Crypt
{0,0,0,0,0,79} --Hive
Expand Down
10 changes: 5 additions & 5 deletions randomize.bat
Original file line number Diff line number Diff line change
Expand Up @@ -135,21 +135,21 @@ IF %param1% == lua (
set /a num4=%param16%
set /a num5=%param17%
) ELSE (
set /a num1=%random% %%59 +1
set /a num1=%random% %%58 +1
:2again3
set /a num2=%random% %%59 +1
set /a num2=%random% %%58 +1
if [%num1%] == [%num2%] goto 2again3
:3again3
set /a num3=%random% %%59 +1
set /a num3=%random% %%58 +1
if [%num1%] == [%num3%] goto 3again3
if [%num2%] == [%num3%] goto 3again3
:4again3
set /a num4=%random% %%59 +1
set /a num4=%random% %%58 +1
if [%num1%] == [%num4%] goto 4again3
if [%num2%] == [%num4%] goto 4again3
if [%num3%] == [%num4%] goto 4again3
:5again3
set /a num5=%random% %%59 +1
set /a num5=%random% %%58 +1
if [%num1%] == [%num5%] goto 5again3
if [%num2%] == [%num5%] goto 5again3
if [%num3%] == [%num5%] goto 5again3
Expand Down

0 comments on commit dea517e

Please sign in to comment.