mirror of
https://github.com/OpenDiablo2/OpenDiablo2
synced 2025-02-20 07:27:19 -05:00
removed all 'structcheck' and 'unused' lint errors (#839)
This commit is contained in:
parent
42a48fe03a
commit
49c1985dcc
@ -425,6 +425,9 @@ func (am *AssetManager) loadDCC(path string,
|
||||
}
|
||||
|
||||
animation, err := newDCCAnimation(dcc, palette, effect)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
return animation, nil
|
||||
}
|
||||
|
@ -53,6 +53,7 @@ const (
|
||||
var _ d2item.Item = &Item{}
|
||||
|
||||
// Item is a representation of a diablo2 item
|
||||
// nolint:structcheck,unused // WIP
|
||||
type Item struct {
|
||||
factory *ItemFactory
|
||||
name string
|
||||
@ -83,6 +84,7 @@ type Item struct {
|
||||
sockets []*d2item.Item // there will be checks for handling the craziness this might entail
|
||||
}
|
||||
|
||||
// nolint:structcheck,unused // WIP
|
||||
type itemAttributes struct {
|
||||
worldSprite *d2ui.Sprite
|
||||
inventorySprite *d2ui.Sprite
|
||||
@ -118,7 +120,7 @@ type itemAttributes struct {
|
||||
type minMaxEnhanceable struct {
|
||||
min int
|
||||
max int
|
||||
enhance int
|
||||
enhance int // nolint:structcheck,unused // WIP
|
||||
}
|
||||
|
||||
// Label returns the item name
|
||||
|
@ -7,6 +7,7 @@ import (
|
||||
)
|
||||
|
||||
// AnimatedEntity represents an animation that can be projected onto the map.
|
||||
// nolint:structcheck,unused // variables are unused because it is incomplete
|
||||
type AnimatedEntity struct {
|
||||
mapEntity
|
||||
animation d2interface.Animation
|
||||
|
@ -116,7 +116,7 @@ type MainMenu struct {
|
||||
inputManager d2interface.InputManager
|
||||
renderer d2interface.Renderer
|
||||
audioProvider d2interface.AudioProvider
|
||||
scriptEngine *d2script.ScriptEngine
|
||||
scriptEngine *d2script.ScriptEngine // nolint:structcheck,unused // it will be used...
|
||||
navigator d2interface.Navigator
|
||||
uiManager *d2ui.UIManager
|
||||
heroState *d2hero.HeroStateFactory
|
||||
|
@ -36,6 +36,7 @@ func Create(asset *d2asset.AssetManager) (*RemoteClientConnection, error) {
|
||||
}
|
||||
|
||||
result := &RemoteClientConnection{
|
||||
asset: asset,
|
||||
heroState: heroStateFactory,
|
||||
uniqueID: uuid.New().String(),
|
||||
}
|
||||
@ -149,6 +150,7 @@ func (r *RemoteClientConnection) serverListener() {
|
||||
}
|
||||
|
||||
// bytesToJSON reads the packet type, decompresses the packet and returns a JSON string.
|
||||
// nolint:unused // WIP
|
||||
func (r *RemoteClientConnection) bytesToJSON(buffer []byte) (string, d2netpackettype.NetPacketType, error) {
|
||||
packet, err := d2netpacket.UnmarshalNetPacket(buffer)
|
||||
if err != nil {
|
||||
|
Loading…
x
Reference in New Issue
Block a user