package ru.dbotthepony.kstarbound.world.entities.player

import ru.dbotthepony.kommons.util.getValue
import ru.dbotthepony.kommons.util.setValue
import ru.dbotthepony.kstarbound.network.syncher.NetworkedGroup
import ru.dbotthepony.kstarbound.network.syncher.networkedBoolean
import ru.dbotthepony.kstarbound.network.syncher.networkedJsonElement
import ru.dbotthepony.kstarbound.network.syncher.networkedSignedInt
import ru.dbotthepony.kstarbound.network.syncher.networkedString
import java.io.File

// as separate class because it contains plentiful of internal logic
// (avoids pollution in main class)
class Songbook(val player: PlayerEntity) {
	val networkGroup = NetworkedGroup()
	var song by networkGroup.add(networkedJsonElement())
	var songEpoch by networkGroup.add(networkedSignedInt())
	var timeSource by networkGroup.add(networkedString())
	var isActive by networkGroup.add(networkedBoolean())
	var instrument by networkGroup.add(networkedString())
}
