Commit Graph

1431 Commits

Author SHA1 Message Date
Collin Smith
c305f1c586 Removed Pathfinder system injection from CursorMovementSystem 2020-10-09 12:32:26 -07:00
Collin Smith
9c7a7f9795 Implemented EngineConfig (see #109) 2020-10-08 23:48:53 -07:00
Collin Smith
30bd940846 Created basic BinkVideo packet and added additional logging to BinkAudio 2020-10-08 22:13:38 -07:00
collinsmith
1e9695a125 Reordered log message output 2020-10-06 11:54:50 -07:00
collinsmith
2dd14725c4 Implemented error checking and killing of audio threads when player is disposed 2020-10-06 11:53:01 -07:00
collinsmith
46b52ccbf6 Pass BIK reference to child BinkAudio for flags and version validation 2020-10-06 11:35:09 -07:00
collinsmith
292747adb3 Fixed passing incorrect buffer 2020-10-06 11:02:54 -07:00
collinsmith
be2e0d005c Created AudioPacket and basic executor 2020-10-06 10:55:04 -07:00
collinsmith
3803abb02b Implemented frame delta with time steps 2020-10-06 10:28:26 -07:00
collinsmith
ac5ec5f0d8 Resolve keyframe at decode layer so that info is preserved without creating extra data 2020-10-06 10:13:37 -07:00
collinsmith
a6f4aeb467 Better slicing of audio and video packets per frame 2020-10-06 09:59:38 -07:00
collinsmith
db97517cd2 Perform keyframe checking and masking of offsets table 2020-10-05 10:51:06 -07:00
Collin Smith
fac0f9fd5d Changed Bink code to help with debugging and testability 2020-10-05 01:46:06 -07:00
Collin Smith
bb8a621d5d Additional work on Bink video codec 2020-10-05 00:49:04 -07:00
Collin Smith
2bbd3f0c9c Created BIK coded along with BinkAudio and BinkVideo (see #59) 2020-10-04 16:58:22 -07:00
Collin Smith
58d31d0634 Adjusted API of UnsafeNarrowing to be more useful
UnsafeNarrowing is now loosely coupled with InvalidFormat via UnsafeNarrowing#wrapAndThrow
UnsafeNarrowing can now be passed an optional offset value
2020-10-03 00:56:58 -07:00
Collin Smith
08bc23160f Increased robustness of UnsafeNarrowing exception
UnsafeNarrowing now requires a ByteInput argument to track where exception was thrown
Changed visibility of BitConstraints to public
Added BitConstraints safeXXu checkers for BitInput as well as ByteInput
2020-10-02 22:03:54 -07:00
Collin Smith
5a9d179e15 Ported readSafeXXu methods from ByteInput to BitInput 2020-10-02 21:01:14 -07:00
Collin Smith
35eaccf9a9 RiiabloTest changes logger to synchronous appender 2020-10-02 18:57:06 -07:00
Collin Smith
c62c103948 Implemented support for com.riiablo.io into DCC codec
InputStream signatures have all been removed (interoperability would have meant tons of code duplication)
MPQInputStream now supports fast-track reading of uncompressed files
2020-10-02 12:11:48 -07:00
Collin Smith
64fa1611e4 Revised BitInput slice strategy
BitInput now carries logical bitsRead from all previous ByteInput slices
Created BitInput#maxBit to track initial bitsRead + numBits
Created BitInput#maxBitByteOffset to trace delta between maxByte bit offset and maxBit
numBits check not replaced with bitsRead vs maxBit
ByteInput#slice(long) will slice at the current buffer readerIndex instead of mark due to an issue where mark was carrying parent offset
2020-10-02 11:41:54 -07:00
Collin Smith
6e65f5361a Added support for reading bit input slices of arbitrary boundaries (closes #118)
BitInput#readSlice uses ByteInput#slice and performs manual #skipBits on parent buffer
Added single-byte tests
2020-09-30 16:36:38 -07:00
collinsmith
235ae94d5a Begin work on transitioning DCC to use new io API 2020-09-30 14:47:07 -07:00
collinsmith
757a85f84b Propagated name change 2020-09-30 10:18:34 -07:00
collinsmith
bb84f49d63 Merge branch 'master' of https://github.com/collinsmith/riiablo 2020-09-30 09:51:09 -07:00
collinsmith
d1af110c12 Created util function to retrieve safe u32s 2020-09-30 09:50:40 -07:00
Collin Smith
88e173de60 Spelling error 2020-09-29 15:57:39 -07:00
collinsmith
1116e14fc7 Refined implementation
FileHandleAdapter changed to abstract class
FileHandleAdapter now incorporates Reader functionality via #adapt(FileHandle,Class)
Removed specialized functions from AsyncAssetLoader (should be callable directly now)
Refactor renamed readers to adapters
AssetLoader changed from interface to abstract class
AssetLoader requires type reference and is more similar to LibGDX implementation
Adjusted test case with new API
2020-09-29 12:10:23 -07:00
Collin Smith
0c81104adb Reorganized code slightly 2020-09-29 01:17:37 -07:00
Collin Smith
d3a9511a35 Closer API to what I would like, still requires better type inference on Reader 2020-09-29 01:14:06 -07:00
Collin Smith
9d7ee8450e Changed strategy to support FileHandleAdapter and AsyncAdapter 2020-09-29 00:55:40 -07:00
Collin Smith
8837ff46b6 Fixed typing issue 2020-09-28 22:22:46 -07:00
Collin Smith
f92db89f61 Refined implementation
Attempted transition from reader type to filehandle type
Created sample loaders for testing purposes
Created SyncReader interface
2020-09-28 22:21:28 -07:00
Collin Smith
8305ba4b50 Committing experimental Asset Manager 2020-09-28 21:09:58 -07:00
Collin Smith
ad19056cfb Changed async logger appender to be a daemon thread 2020-09-27 13:12:53 -07:00
Collin Smith
1a6783f047 Workaround for an issue with LibGDX AssetDescriptor path contraint 2020-09-25 01:22:43 -07:00
Collin Smith
01d92a69c3 Changed capitalization of extensions 2020-09-25 01:03:53 -07:00
Collin Smith
055b56907b Reorganized code slightly 2020-09-25 00:42:17 -07:00
Collin Smith
f2ec4c9c2e Created Decryptor.LookupTable#fix(String) to return a valid translated path string 2020-09-25 00:26:11 -07:00
Collin Smith
e2c00d7336 Cleaner way of doing byte[] to upper case and converting path delimiter 2020-09-25 00:17:14 -07:00
Collin Smith
874bb809f8 Fixed mpq_bytebuf impl bugs
Added remaining MPQFileHandle impl override methods
MPQFileHandleResolver will automatically fix path delimiters
Fixed decompression on an uncompressed sector
2020-09-24 19:34:33 -07:00
Collin Smith
e091821c46 Fixed an issue where Exploder was masking an incorrect number of bytes for the copy offset 2020-09-24 19:12:26 -07:00
Collin Smith
8284ab095e Removed INTS pool by using a ByteBuf instead 2020-09-24 17:57:26 -07:00
Collin Smith
cd9d8801c7 Refactored CursorMovementSystem#setTarget to Actioneer#moveTo 2020-09-23 11:48:54 -07:00
Collin Smith
6f40094f73 Increased sectors cache to 16384 offsets (67 MB)
Should research keeping a ByteBuf copy of offsets
2020-09-23 01:55:28 -07:00
Collin Smith
e1252e172c Added terminator for MPQ#getIndex(long,int,short) for case where not found 2020-09-23 01:54:08 -07:00
Collin Smith
2c5d056457 Refined MPQFileHandle and MPQInputStream impls 2020-09-23 01:26:19 -07:00
Collin Smith
d7649ca94c Removed throws IOException from methods 2020-09-22 15:59:10 -07:00
Collin Smith
16474a215f Replaced gdx object pool with thread-safe com.riiablo.util.Pool 2020-09-22 13:40:36 -07:00
Collin Smith
5c10340222 Added support for initial capacity pre-init to Pool 2020-09-22 13:35:23 -07:00
Collin Smith
63c17b0e17 Created com.riiablo.util.Pool thread safe pool (closes #116) 2020-09-22 13:22:24 -07:00
Collin Smith
6d8cefb2c8 Committing tests of mpq_bytebuf package 2020-09-22 12:37:09 -07:00
Collin Smith
bd9b30a33d Upgraded mpq_bytebuf library
Created MPQFileHandleResolver to resolve a filename to an MPQ
Greatly improved efficiency of MPQInputStream and reduced overhead
Added support for fast-path ByteBufInputStream for a native memory read
MPQFileHandle now supports key/offset caching for faster lookup
MPQ now initializes using a FileChannel instead of a RandomAccessFile
MPQ hash and block tables are read using a buffer
Moved MPQFileHandle file operations to MPQFileHandle from MPQ
Added ability to retrieve MPQ block table entry from an MPQ hash table entry
Inlined Exploder#TRUNCATE
Decryptor now works using arrays directly (asserted input is a heap byte buf)
Decryptor returns a long tuple consisting of key and seed state for buffered calls
2020-09-22 12:36:40 -07:00
Collin Smith
35504fccdc Improved logger throughput
Added initial size and pool object init
AsyncAppender now releases events more reliably
Workaround for #116
2020-09-21 13:36:12 -07:00
Collin Smith
24f8c764bb Created var-arg alternative methods 2020-09-21 02:32:19 -07:00
Collin Smith
368f2f71bf Deferred log message creation until enabled is evaluated 2020-09-21 02:25:44 -07:00
Collin Smith
6117efc25e Created AsyncOutputStreamAppender to support logging output on separate threads 2020-09-21 02:02:16 -07:00
Collin Smith
bb4efb7967 Created Pooled variations of message factory implementations
Created Pooled variations of message factory implementations
Set logger to default to use these pooled message factories
2020-09-21 01:45:23 -07:00
Collin Smith
aa04ebd132 Changed LogEvent to support pooling 2020-09-21 01:32:55 -07:00
Collin Smith
703be01ceb Created Message#release() 2020-09-21 01:30:56 -07:00
Collin Smith
dd0707a759 Created methods for non-varargs log functions 2020-09-21 01:25:10 -07:00
Collin Smith
5b22902b10 Changed varargs to array 2020-09-21 01:10:16 -07:00
Collin Smith
68ada6121f Added virtuals for newMessage without var args 2020-09-21 01:09:26 -07:00
Collin Smith
bd0752cc6a Created Message#numParameters() 2020-09-21 00:54:47 -07:00
Collin Smith
f2816b24ab Removed AbstractLogger and implemented functionality directly into Logger class 2020-09-21 00:42:56 -07:00
Collin Smith
2e4f7f6690 Created Actioneer#canInterrupt(int) to check whether an entity action can be interrupted
Implemented interruption checking into CursorMovementSystem#updateLeft()
2020-09-20 21:41:53 -07:00
Collin Smith
b8756bbe8d MPQ library implemented with ByteBuf and MappedByteBuffer (see #8) 2020-09-19 22:23:27 -07:00
Collin Smith
9009cdcfd9 Resolved a concurrency issue regarding shared state within static decompress method 2020-09-18 22:36:18 -07:00
Collin Smith
303e063586 Tested charclass sound against local player component 2020-09-13 19:46:10 -07:00
Collin Smith
aa948b9b1f Resetting Animation instances clears Animation#cof reference (see #113) 2020-09-13 13:46:27 -07:00
Collin Smith
28fb71de85 Fixed radial spells to 64 directions 2020-09-13 13:21:59 -07:00
Collin Smith
add2ea22b5 Added support for per-layer shadow flag
Added support for per-layer shadow flag
Set automatically for now based on blendMode
2020-09-13 13:15:50 -07:00
Collin Smith
c98c3dc2c8 Added support for cltdofunc 25 (shouts / novas)
Added support for cltdofunc 25 (shouts / novas)
Changed animation frame delta for missiles to 256 from Missile.Entry.animrate
Disabled Missie.Entry.TravelSound audio until it can be figured out better
Added Skills.Entry.cltmissile(a-d)
2020-09-12 15:31:45 -07:00
Collin Smith
372f501b4b Created RADIANS_64
Created RADIANS_64
Redefined RADIANS_X tables mathematically to improve readability
2020-09-12 15:19:35 -07:00
Collin Smith
54216795f6 Enabled bullet flag for missiles and changed to sensors to disable collision 2020-09-12 14:48:39 -07:00
Collin Smith
efc6a5c0e4 Created MissileHandler to dispose of missile entities past their range
Created MissileHandler to dispose of missile entities past their range
MissileLoader now resets direction to 0 when missile is loaded
2020-09-12 14:21:48 -07:00
Collin Smith
b01f5180b2 Changed monster placement algorithm to distribute grouped monsters across an area 2020-09-11 13:26:59 -07:00
Collin Smith
0dccc53c44 Monster label now shows first non-empty hitpoints monster 2020-09-11 13:24:01 -07:00
Collin Smith
8eb29c9cfb Monster label will hide itself if the target monster is dead 2020-09-11 13:20:46 -07:00
Collin Smith
8be6bee27a Increased default mele range to 3 units 2020-09-11 13:20:00 -07:00
Collin Smith
143634858d Fixed encoding for negative fixed point numbers 2020-09-11 13:08:35 -07:00
Collin Smith
6cc41eb633 Assigned missiles a physics body (see #113) 2020-09-10 23:46:27 -07:00
Collin Smith
63bfa85173 Resolved the actual crash this time
It would appear that a valid targetId is given that has a position, except that the position is null? This will be looked into later.
2020-09-10 23:31:17 -07:00
Collin Smith
0590ddc166 Fixed crash caused resulting by a previous fix which incorrectly unset target entity 2020-09-10 23:28:02 -07:00
Collin Smith
30f4190ead Added support for MonsterLabelManager to draw monster health
Added support for MonsterLabelManager to draw monster health
Added percent and modal params to PaletteIndexedColorDrawable to allow use as a progress bar
2020-09-10 23:27:22 -07:00
Collin Smith
c906a20817 Added sound effect for hit impact 2020-09-10 22:50:47 -07:00
Collin Smith
39f3d5aaca Added attack range check for left click
Added attack range check for left click
Added null check for dangling target
2020-09-10 22:41:02 -07:00
Collin Smith
c64042bafe Created DamageHandler and implemented hit sounds 2020-09-10 19:16:08 -07:00
Collin Smith
4e0e2c142a Created DamageEvent and dispatching 2020-09-10 19:11:28 -07:00
Collin Smith
7b227fe2ed Committing DeathEvent 2020-09-10 19:09:14 -07:00
Collin Smith
61985ed440 Checks if target is still valid (some trailing event target ids?) 2020-09-10 18:40:27 -07:00
Collin Smith
28d6eddcb6 Another workaround for #113 2020-09-10 18:39:59 -07:00
Collin Smith
83c0e87a9a Unset killer target if target was victim 2020-09-10 18:32:05 -07:00
Collin Smith
52edd64327 Fixed spelling error DC.Direction#toReadDir -> #toRealDir 2020-09-10 18:31:42 -07:00
Collin Smith
0087e832c2 Implemented monster deaths
Added AI death state and AI#kill() virtual method
DeathHandler handles state transition and entity disposal
2020-09-10 18:22:44 -07:00
Collin Smith
bfcee599bf Increased damage and added death event with subscriber to play death sequence 2020-09-10 17:31:41 -07:00
Collin Smith
f3c9ff82aa Fixed an issue where consecutive stat gets were corrupting previous values 2020-09-10 16:59:22 -07:00
Collin Smith
d77a109be2 Added support for getting a stat from Attributes into a provided tuple 2020-09-10 16:58:44 -07:00
Collin Smith
8acfe5bc1f Created temp function to add support for negative float encoding until properly implemented 2020-09-10 16:46:19 -07:00
Collin Smith
a86b338dfa Only draw hitpoints if greater than 0 2020-09-10 16:45:39 -07:00
Collin Smith
ff24b9f516 Created Attributes#getCopy(short) to return a (temp) copy of the specified stat 2020-09-10 16:45:00 -07:00
Collin Smith
00f75d014c Added support for setting stat to sibling stat value
Changed order of hp,mp,stamina adjustments so they match again
2020-09-10 16:21:55 -07:00
Collin Smith
a9f4e35016 Disabled hitpoints background (was making hitpoints foreground hard to see) 2020-09-10 14:06:22 -07:00
Collin Smith
484e5b867f Actioneer now changes hitpoints of target for attack spell 2020-09-10 14:03:22 -07:00
Collin Smith
7d507f0501 Refactored from StatRef to float
Refactored from StatRef to float
Added label with hitpoints and maxhp values
2020-09-10 14:03:00 -07:00
Collin Smith
f2d16a8c50 Created Stat#decode(short,int) to perform val shift
Changed val shift operatios to use Stat#encode and #decode
2020-09-10 14:01:09 -07:00
Collin Smith
0ba173404c Added support for stat subtraction 2020-09-10 13:54:47 -07:00
Collin Smith
d11303fb61 Added health bar above entities with health in debug render mode 2020-09-10 13:29:23 -07:00
Collin Smith
eca9ba9908 Created Attributes#contains(short) 2020-09-10 13:28:49 -07:00
Collin Smith
6592ef0291 Added bounds check on Attributes list to prevent an IOOBE
I considered allowing null returns and handling gracefully, however I prefer seeing that error message for the time being, as this should be addressed
2020-09-10 13:11:50 -07:00
Collin Smith
15d2b13bff Changed visibility of some StatList methods to public
Exposed #numLists(), #maxLists(), #contains(int) and #get(int)
2020-09-10 13:09:22 -07:00
Collin Smith
e7d868106d Successfully replaced com.riiablo.item.Attributes with com.riiablo.attributes.Attributes
Completed coupling systems to use new attributes package
Hopefully I didn't miss anything, because this sucked
2020-09-10 02:20:43 -07:00
Collin Smith
1a84778164 Temporary workaround for #113 2020-09-10 02:13:33 -07:00
Collin Smith
5935314a44 Fixed bug where bit shit was as an int and not a long 2020-09-10 01:35:24 -07:00
Collin Smith
7f5149baa7 Committing test parent class 2020-09-09 23:55:27 -07:00
Collin Smith
92d0728e07 Replaced com.riiablo.attributes with com.riiablo.attrs 2020-09-09 18:52:41 -07:00
Collin Smith
531aa9323c Committing next iteration of attributes package 2020-09-09 18:41:22 -07:00
Collin Smith
2f58fbd5cc Moved Fixed to com.riiablo.math 2020-09-09 17:55:49 -07:00
Collin Smith
9efc2bb5c3 Fixed issue where encoding was passed an incorrect parameter 2020-09-09 03:18:03 -07:00
Collin Smith
94c30110de Implemented basic stat mod tracking support 2020-09-08 13:13:55 -07:00
Collin Smith
13fc89b9f8 StatListReader will apply ValShift to read stats that aren't cs 2020-09-08 13:02:20 -07:00
Collin Smith
f45168a133 Improved Fixed utils
Made class final
Changed from bit shift to lookup table
2020-09-08 13:01:51 -07:00
Collin Smith
73e1be417a op stats now add with agg stats 2020-09-08 13:00:54 -07:00
Collin Smith
027f923409 Implemented StatListBuilder#add(short,int) 2020-09-07 13:58:21 -07:00
Collin Smith
92a4061173 Implemented stat mod flag and checking 2020-09-07 13:57:42 -07:00
Collin Smith
bbf3fa1eb6 Exposed exposed param() as params() to avoid misuse 2020-09-07 13:57:15 -07:00
Collin Smith
5115403733 Created StatList#put(short,StatGetter) to copy other stats into a stat 2020-09-07 13:23:08 -07:00
Collin Smith
fc23ab05b5 Added copy method for StatGetter to preserve a reference 2020-09-07 13:22:12 -07:00
Collin Smith
1c9e858798 Updated test with interleaved update sequences 2020-09-07 01:35:34 -07:00
Collin Smith
f215a7f191 Added support for pooling UpdateSequence instances to allow asynchronous sequencing 2020-09-07 01:28:19 -07:00
Collin Smith
aadc9d2de8 Removed requirement for AttributesUpdater to be stateful
Used a clever trick on StatList.StatIterator, where read stats can be pushed onto the list starting from the front. The result is a sorted list not containing elements which were not added back.
2020-09-07 01:15:55 -07:00
Collin Smith
f121cc8a7a Replaced AttributesUpdater with Updater and renamed it
Replaced AttributesUpdater with Updater and renamed it
Fixed existing StatListLabeler tests
2020-09-07 00:12:42 -07:00
Collin Smith
7ccebec402 Created boolean parameter to determine stat list capacity
Created boolean parameter to determine stat list capacity for AggregateAttributes initialization
2020-09-06 23:48:44 -07:00
Collin Smith
d69de2b357 Added experimental iteration of AttributeUpdater called Updater 2020-09-06 21:29:35 -07:00
Collin Smith
e6f97c2025 Added support for larger StatList instances
Aggregate lists may contain many stats, added special instance
2020-09-06 20:40:11 -07:00
Collin Smith
b7bf3ca62a Disabled warning message for StatListGetter#get(short)
assigning #get() and checking null is a common usage
2020-09-06 16:16:18 -07:00
Collin Smith
947862be1a Changed visibility of item flag management static functions to public
Created StatListFlags#getAggItemFlags to update flags for agg list
2020-09-06 16:06:18 -07:00
Collin Smith
d55eb801d8 Added assertion trigger if undefined case ever occurs 2020-09-06 15:41:29 -07:00
Collin Smith
f47c949101 Tightened up AttributesUpdater
Renamed opAttrs to opBase
Reorganized params more logically to function
Added note regarding possibly deficiency from original impl and op stats
2020-09-06 15:39:04 -07:00
Collin Smith
d0e69cf74c Added additional check on gem attributes listFlags 2020-09-06 13:06:38 -07:00
Collin Smith
fc1b7a73a1 Created StatListGetter#getValue(short,int) to retrieve a default int or value if non-null 2020-09-06 12:42:31 -07:00
Collin Smith
f21bf0339a Renamed Attributes#update methods to #aggregate 2020-09-06 12:31:03 -07:00
Collin Smith
5cb04016cc Changed attributes log level to debug 2020-09-06 05:09:14 -07:00
Collin Smith
c127475007 Significantly tightened up code
Touched about every line of code to validate behavior
2020-09-06 05:05:47 -07:00
Collin Smith
f69db25728 Changed from instanceof to check if attrs is simple 2020-09-06 01:41:42 -07:00
Collin Smith
b5c33a313f Removed unneeded block -- managed by StatListReader 2020-09-06 01:29:44 -07:00
Collin Smith
85303c28cc Replaced Attributes in com.riiablo.item with com.riiablo.attributes for D2SReader 2020-09-06 01:28:31 -07:00
Collin Smith
a72b317dc9 Added logging for all value modifications and set to info level 2020-09-06 01:22:44 -07:00
Collin Smith
96069e98e2 Fixed GemGenerator not checking attrs type properly 2020-09-06 00:59:06 -07:00
Collin Smith
9ed7b82c08 Added type marker to Attributes
Added byte type value to represent what kind of attrs it is
Rolled GemAttributes into AggregateAttributes
GemAttributes are now marked using added marker
`Complex` attribute lists have types > 0
StatListWrapper set to type 0
2020-09-06 00:42:20 -07:00
Collin Smith
1dabb6f6b8 Removed content, ultimately not needed 2020-09-06 00:20:45 -07:00
Collin Smith
6f86f4048c Added method for accessing gem attribute selected flag 2020-09-06 00:18:03 -07:00
Collin Smith
49f293c494 Added method to validate flags for gem stat lists 2020-09-06 00:17:25 -07:00
Collin Smith
57e1052e9f Created consts for gem list flags 2020-09-06 00:06:58 -07:00
Collin Smith
ec802d7c04 Changed visibility of StatListGetter#builder to public 2020-09-05 19:50:04 -07:00
Collin Smith
fd07613913 Created stat constants for synthetic reqstr and reqdex 2020-09-05 19:49:38 -07:00
Collin Smith
03d7e9a458 Added int flags parameter to AttributesUpdater to specify which lists to include
Added int flags parameter to AttributesUpdater to specify which lists to include
AttributesUpdater checks and logs if flags includes more than 1 set (unusual)
Renamed set item constants and methods within SetListFlags to be more consistent
Added Aldur's Advance StatListLabeler test
Added runes to Grief StatListLabeler test
2020-09-05 19:48:53 -07:00
Collin Smith
181cd3eb6f Renamed field to correct name 2020-09-05 19:36:40 -07:00
Collin Smith
f3fc76e366 Added better descriptors for StatList toString methods 2020-09-05 19:35:49 -07:00
Collin Smith
938064bcbd Fixed log message format 2020-09-05 19:03:03 -07:00
Collin Smith
fa9add8e6f Fixed log message format 2020-09-05 19:01:46 -07:00
Collin Smith
670d6c5e1b Fixed log message format 2020-09-05 19:00:53 -07:00
Collin Smith
3025f4d05d Fixed log message format 2020-09-05 19:00:23 -07:00
Collin Smith
0bfa47bd83 Changed GemAttributes to be a subclass of AggregatedAttributes
Gems require item_levelreq stat in their base and are more complex than originally thought
2020-09-05 18:29:31 -07:00
Collin Smith
eb011ed471 Changed ItemReader#readSingleItem to package-private
readSingleItem visibility was provided for backcompat which is no longer needed
2020-09-05 17:45:11 -07:00
Collin Smith
c96f787cf9 Removed Item#loadFromStream(BitStream)
ClientNetworkReceiver requires injection of ItemReader
Changed ClientNetworkReceiver to read item instead of single item
Removed workaround comment for ItemReader
2020-09-05 17:43:44 -07:00
Collin Smith
4571f8ce18 Fixed crash on android due to missing control panel buttons 2020-09-05 17:11:43 -07:00
Collin Smith
b522365d25 Fixed crash on android
Moved Actioneer and related systems outside of desktop restriction
MobileControls will cast spells 12 units in front of player target angle
2020-09-05 16:59:19 -07:00
Collin Smith
9c33689b35 Added some comments for fields that will require injection
Added some comments for fields that will require injection (or looked into for plausibility of injection)
2020-09-05 16:42:51 -07:00
Collin Smith
de8f81db47 Made AttributesUpdater#update on non-AggregateAttributes to be a no-op 2020-09-05 14:57:42 -07:00
Collin Smith
77e58a72b1 Generated StatList for gems is now frozen 2020-09-05 14:56:29 -07:00
Collin Smith
03484882d3 Added more tests 2020-09-05 14:49:21 -07:00
Collin Smith
37ea64921c Fixed incorrect stat assignment 2020-09-05 14:48:01 -07:00
Collin Smith
1734b90bf9 Implemented structured logging 2020-09-05 14:43:33 -07:00
Collin Smith
e81af4dece Added assertion validations to GemGenerator
Added assertion validations to GemGenerator to make sure property list indexes are correct
Renamed StatListBuilder#index() to #listIndex() to clarify
2020-09-05 14:38:45 -07:00
Collin Smith
273b434c7c Renamed GemUtils to GemGenerator 2020-09-05 14:33:17 -07:00
Collin Smith
d5b6f74a61 Made params final 2020-09-05 14:32:00 -07:00
Collin Smith
f61af7414e Added AttributesUpdater#add to append StatList lists to an aggregate 2020-09-05 14:30:10 -07:00
Collin Smith
d59dcd625b Added some placeholder documentation 2020-09-05 14:25:26 -07:00
Collin Smith
8cfcc2195d Fixed spelling error 2020-09-05 02:37:29 -07:00
Collin Smith
e9b3d69c81 Fixed cache not clearing after consecutive calls 2020-09-05 02:34:34 -07:00
Collin Smith
554553888c Created PropertiesGenerator, GemUtils and tests
GemUtils may be rolled into PropertiesGenerator
PropertiesGenerator may belong with item generation
More validation for behavior on a larger variety of items required
Disabled an assertion in StatListLabeler which prevented creating labels for Attributes#list()
Above assertion only necessary to enforce label creation only works for Attribute collections
2020-09-05 02:20:03 -07:00
Collin Smith
f1246f5aea Added getter for ItemStatCost entry using String stat code 2020-09-05 02:15:10 -07:00
Collin Smith
82d08989d1 Added type-safe version of Item#getBase 2020-09-04 21:54:40 -07:00
Collin Smith
e0f977f8a0 Replaced comment to reference Item#data repurpose 2020-09-04 21:54:13 -07:00
Collin Smith
0548514a9e Added improved support for injection during tests 2020-09-04 21:48:26 -07:00
Collin Smith
b7dcf0f4fe Modified logging parameters to show only StatListLabeler trace 2020-09-04 20:44:31 -07:00
Collin Smith
030564a5a6 Created StatListLabeler and tests
Encoded stats may require StatGetter#asString instead of value
Changed visibility of StatList#MAX_LISTS and StatList#MAX_STATS to package-private
2020-09-04 20:42:23 -07:00
Collin Smith
7c54483e12 Created AttributesUpdater and tests to fold attributes into each other 2020-09-04 20:40:43 -07:00
Collin Smith
3b34642c0d Created StatFormatter#formatEncoded to format encoded stats 2020-09-04 20:39:14 -07:00
Collin Smith
2bd5f217a4 Changed return type for StatFormatter methods to String from CharSequence 2020-09-04 20:38:39 -07:00
Collin Smith
2fd51347bf Fixed issues with StatList#add and StatList#ensureCapacity
Add functions now validate they are adding to same stat, else they put a new one
Moved arraycopy copies into static function
StatList#ensureCapacity will correctly copy arrays
Moved any offsets modification operations into StatList#ensureCapacity
2020-09-04 18:29:48 -07:00
Collin Smith
db04f49fba Added support for StatListGetter#get(int) index 2020-09-04 15:54:40 -07:00
Collin Smith
a839560e6a Implemented StatListBuilder#toString() 2020-09-04 15:53:01 -07:00
Collin Smith
b45f770478 Changed StatList.IndexIterator to support pushback(int)
StatList.IndexIterator can now pushback n indexes (up to list start index)
2020-09-04 15:52:41 -07:00
Collin Smith
79a9409a75 Fixed and issue where StatList#ensureCapacity(int,int) was only shifting next list
Added int index to StatList#ensureCapacity so that it shifts after index
Added additional validation within StatList#ensureCapacity
Added assertion that clearList does not result in a negative size
StatList#copy(int,StatList,int) now copies #maxLists as well
Added additional logging for StatList#copy
2020-09-04 15:51:49 -07:00
Collin Smith
e892970ef8 Added constants and getters for encoded and grouped stats 2020-09-04 15:47:47 -07:00
Collin Smith
ecd6946ffe Fixed StatList#add where stat did not exist 2020-09-03 21:20:53 -07:00
Collin Smith
61ba1248e1 Fixed bug where adding stat that didn't exist resulted in an IOOBE 2020-09-03 20:52:14 -07:00
Collin Smith
04b9ed785c Created StatFormatter and tests, testing as-needed 2020-09-03 20:43:28 -07:00