mirror of
https://github.com/OpenDiablo2/OpenDiablo2
synced 2025-02-09 18:17:07 -05:00
* Add basic EquipmentSlot struct * Add Load function to EquipmentSlot * Move EquipmentSlot struct to inventory_grid.go * Add equipmentSlots arg to ItemGrid struct * Add basic rendering of equipment slots. * Change rendering of equipment slots to simply use their static x and y * Add ChangeEquippedSlot function * Add initialization to all equipped slots types. * Fix Y locations of equipment slots * Move default equipment slots to a genEquipmentSlotsMap function. * Change Item to item * Fix coordinates * Change usage of string to EquippedSlotType when dealing with different slots in rendering. * Fix import error * Remove neck example * Add loading sprites of equipped items. * Clean code in Inventory rendering * Clean code in Inventory rendering * Clean code in Inventory rendering * Change default items that get rendered. * Change default items that get rendered. * Add width and height to EquipementSlot struct * Fill in width and height to current equipment slots. * Fix Y setting of equipment slots * Rename variables for clean code. * Change handling nil itemSprite to condition instead of loop return. * Split Render function to 2 functions. * Add TODO * Change comment to start with capital I |
||
---|---|---|
.. | ||
animation_frame.go | ||
animation_mode_string.go | ||
animation_mode.go | ||
composite_type.go | ||
description_functions.go | ||
draw_effect.go | ||
equipped_slot_type.go | ||
hero_stance.go | ||
hero_string2enum.go | ||
hero_string.go | ||
hero.go | ||
inventory_item_type.go | ||
item_affix_type.go | ||
item_event_functions.go | ||
item_events.go | ||
layer_stream_type.go | ||
level_generation_types.go | ||
level_teleport_flags.go | ||
readme.md | ||
region_id.go | ||
region_layer.go | ||
tiletype.go | ||
weapon_class_string2enum.go | ||
weapon_class_string.go | ||
weapon_class.go |
OpenDiablo2 Enums
Items in this folder are compiled with two programs. You can obtain them by running the following:
go get golang.org/x/tools/cmd/stringer
go get github.com/mewspring/tools/cmd/string2enum
Once you have the tools installed, simply run the following command in this folder to regenerate the support files:
go generate
If you add any enums (e.g. AnimationMode
), make sure to add the following to the end of the
file:
//go:generate stringer -linecomment -type AnimationMode