37 Commits over 0 Days - ∞cph!
No need to store as Base64 encoded string anymore
Refactor to use Component.INetworkSnapshot for sending initial world data
Remove random using statement
Added VoxelChangeListener. Listen for modifications within any volume. Added TestListenerComponent
Use block type icon and tint color for inventory icons if applicable
Add items for the 4 current block types
Blocks must specify item type if want to drop
Fixed position for dropped block
Fixed block item temp world model
Fixed some issues in hotbar
Get rid of BlockItem - do it another hacky way for now, solve this problem of multiple item types later
Fix
Add BlockItem. Make some stuff in Item virtual. Add Item.Name (virtual). Can use BlockItem.Create( Block, int ) to create a block item.
Add [JsonIgnore, Hide] to BlockToIndex
Remove AllowedTools in favor of a GatherSourceKind (MaterialKind) on the Block defintion. Remove MinimumEffectiveness from the defintion too as it'll be unused in Zik's damage system
Added Block types. Update to use Block references. Added Palette.GetBlockIndex( Block ). Blocks can define tags, a name, max health and breakable settings / damage scales - @Metapyziks will implement health / block damage with this stuff
Added [KeyProperty] Name to Palette entries
Make default temperature for a Biome asset be 0.5 instead of 0
Reset block types in the example Biome asset files
Added simple Biome system. Completely inactive right now - but can add a BiomeSampler component and add which Biome asset types you want in the generation. Can easily get which Biome you're in from X, Z voxel coordinates. The sampling code is basic right now, determines biome based on a temperature noise map and each Biome asset determines their temperature. Right now Biome assets can only determine the block types that are used in generation.
Can only MoveOne or Split to slots when the target slot is the same item type
Only drop to world item when dragging if we're over the back panel
Fix dropping item by dropping out of slot
Don't create whole new item when moving one if there's only one to move
Item now implements IValid
Forgot to rename inventory UI stylesheet
Add ItemDragType. Implement moving one item from stack, or splitting stack in half and moving. Drag outside of any slot to drop the item in the world (untested.)
Completely client-auth inventory, remove networking for now. Improve world item pickup to reduce/eliminate possibility of two players picking up the item / duplication.
Put these behind a IsHost - we should be able to let anyone "own" an Inventory, but only the host can modify it
Name inventory let channel own it
Include resources
My item def became corrupted
Try our luck updating Hud prefab
Forgot player.cs test code
Some kind of networked inventory v0.1 - turns out it's a PITA (let's resolve that another time). Item definitions can define prefabs for when an item is consumed/equipped (not impl yet), can also define a custom Item prefab for even more extensibility., world model etc for future. Basic API for giving an item (host), moving an item from one Inventory to another based on slot id. Mostly everything is component/game object based but Inventories must be Host controlled.