generated from VLADIMIR/template
updates
This commit is contained in:
@@ -0,0 +1,34 @@
|
||||
package map_service
|
||||
|
||||
import "evening_detective_server/internal/repos/game_map_repo"
|
||||
|
||||
type MapItem struct {
|
||||
GameID int
|
||||
Kind string
|
||||
ItemID int
|
||||
X int
|
||||
Y int
|
||||
Hidden bool
|
||||
}
|
||||
|
||||
func mapItem(item game_map_repo.Item) *MapItem {
|
||||
return &MapItem{
|
||||
GameID: item.GameID,
|
||||
Kind: item.Kind,
|
||||
ItemID: item.ItemID,
|
||||
X: item.X,
|
||||
Y: item.Y,
|
||||
Hidden: item.Hidden,
|
||||
}
|
||||
}
|
||||
|
||||
func toRepoItem(item *MapItem) game_map_repo.Item {
|
||||
return game_map_repo.Item{
|
||||
GameID: item.GameID,
|
||||
Kind: item.Kind,
|
||||
ItemID: item.ItemID,
|
||||
X: item.X,
|
||||
Y: item.Y,
|
||||
Hidden: item.Hidden,
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user