Comments (3)
Sounds reasonable, you're probably right. I'll look into it more; there might be something in the PlugY source that is useful as well.
from d2itemreader.
So I think this 3/4-bit variance is actually vanilla D2 behavior that depends on the gridY
value in Inventory.txt
.
- PlugY injects its modified stash size here by modifying the compiled
Inventory.txt
values directly, but doesn't change anything else related to the Y coordinate of saved items. - If you change
Inventory.txt
to use agridY
of 10 and use-direct -txt
, Diablo II will start saving Y values using the 4th bit. Very strange behavior to vary the bit width depending on the max value if you're just going to use a padding bit when writing the 3-bit value anyway, but that seems to be what's going on AFAICT
So, in order to be compatible with mods like this we'll need to know the contents of Inventory.txt
while reading items, and then when reading PlugY stash items we just need to tell the reader that gridY
is actually 10 so we read the Y pos as a 4-bit value.
Very good catch, thank you for creating the issue!
Some more stuff:
- PlugY stash organizer that reads Y pos as 4 bits
- Another PlugY stash organizer that reads Y pos as 4 bits
from d2itemreader.
Actually, I overthought it. The fix is as simple as unconditionally reading the 4-bit value, since the bit ordering means that 1 would be 1000
, and 9 would be 1001
(i.e. the 'unknown' bit is only set if the actual value is large enough to warrant it, which explains why it was labeled 'unknown' by people only looking at vanilla D2 saves since it would never be non-zero without Inventory.txt
changes).
Will fix the library and docs.
from d2itemreader.
Related Issues (9)
- Verify that current durability bit field has an extra bit at the end HOT 1
- No Instructions HOT 1
- Handle negative "Save Add" column in ItemStatCost.txt properly
- Investigate the "Signed" column of ItemStatCost.txt HOT 1
- Handle set bonuses properly
- Supplement fuzz testing with random memory failures HOT 1
- Corrupted .sss file please help HOT 2
- Test against PlugY 14.x
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from d2itemreader.