Item refactor and more (#1)
This commit is contained in:
@@ -40,6 +40,7 @@ type Data struct {
|
||||
Rooms []Room
|
||||
OpenMenus OpenMenus
|
||||
Roster Roster
|
||||
HoverData HoverData
|
||||
}
|
||||
|
||||
type Room struct {
|
||||
@@ -48,6 +49,12 @@ type Room struct {
|
||||
Height int
|
||||
}
|
||||
|
||||
type HoverData struct {
|
||||
IsHovered bool
|
||||
UnitID
|
||||
UnitType int
|
||||
}
|
||||
|
||||
func (r Room) GetCenter() Position {
|
||||
return Position{
|
||||
X: r.Position.X + r.Width/2,
|
||||
@@ -98,10 +105,9 @@ func (r Roster) FindByName(name string) (RosterMember, bool) {
|
||||
}
|
||||
|
||||
type Level struct {
|
||||
Area area.Area
|
||||
Position Position
|
||||
IsGoodExit bool
|
||||
CanInteract bool
|
||||
Area area.Area
|
||||
Position Position
|
||||
IsEntrance bool // This means the area can not be accessed just walking through it, needs to be clicked
|
||||
}
|
||||
|
||||
type Class uint
|
||||
@@ -129,6 +135,7 @@ type Position struct {
|
||||
|
||||
type PlayerUnit struct {
|
||||
Name string
|
||||
ID UnitID
|
||||
Area area.Area
|
||||
Position Position
|
||||
Stats map[stat.ID]int
|
||||
@@ -226,4 +233,5 @@ type OpenMenus struct {
|
||||
QuitMenu bool
|
||||
Cube bool
|
||||
SkillSelect bool
|
||||
Anvil bool
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user