mirror of
https://github.com/nacabaro/vbhelper.git
synced 2026-01-27 16:05:32 +00:00
Forgot to actually remove the files, my bad
This commit is contained in:
parent
a028611d8a
commit
7582f944b5
@ -1,14 +1,25 @@
|
||||
package com.github.nacabaro.vbhelper.temporary_domain
|
||||
package com.github.nacabaro.vbhelper.domain.device_data
|
||||
|
||||
import androidx.room.Entity
|
||||
import androidx.room.ForeignKey
|
||||
import androidx.room.PrimaryKey
|
||||
import com.github.cfogrady.vbnfc.data.NfcCharacter
|
||||
import com.github.nacabaro.vbhelper.domain.DeviceType
|
||||
import com.github.nacabaro.vbhelper.domain.Character
|
||||
|
||||
@Entity
|
||||
data class TemporaryCharacterData (
|
||||
@Entity(
|
||||
foreignKeys = [
|
||||
ForeignKey(
|
||||
entity = Character::class,
|
||||
parentColumns = ["id"],
|
||||
childColumns = ["charId"],
|
||||
onDelete = ForeignKey.CASCADE
|
||||
)
|
||||
]
|
||||
)
|
||||
data class UserCharacter (
|
||||
@PrimaryKey(autoGenerate = true) val id: Long = 0,
|
||||
val dimId: Int,
|
||||
var charIndex: Int,
|
||||
var charId: Long,
|
||||
var stage: Int,
|
||||
var attribute: NfcCharacter.Attribute,
|
||||
var ageInDays: Int,
|
||||
@ -24,4 +35,5 @@ data class TemporaryCharacterData (
|
||||
var totalBattlesLost: Int,
|
||||
var activityLevel: Int,
|
||||
var heartRateCurrent: Int,
|
||||
var characterType: DeviceType
|
||||
)
|
||||
@ -1,30 +0,0 @@
|
||||
package com.github.nacabaro.vbhelper.temporary_daos
|
||||
|
||||
import androidx.room.Dao
|
||||
import androidx.room.Insert
|
||||
import androidx.room.OnConflictStrategy
|
||||
import androidx.room.Query
|
||||
import com.github.nacabaro.vbhelper.temporary_domain.TemporaryBECharacterData
|
||||
import com.github.nacabaro.vbhelper.temporary_domain.TemporaryCharacterData
|
||||
import com.github.nacabaro.vbhelper.temporary_domain.TemporaryTransformationHistory
|
||||
|
||||
@Dao
|
||||
interface TemporaryMonsterDao {
|
||||
@Insert
|
||||
fun insertCharacterData(temporaryCharacterData: TemporaryCharacterData): Long
|
||||
|
||||
@Insert
|
||||
fun insertBECharacterData(temporaryBECharacterData: TemporaryBECharacterData)
|
||||
|
||||
@Insert(onConflict = OnConflictStrategy.REPLACE)
|
||||
fun insertTransformationHistory(vararg transformationHistory: TemporaryTransformationHistory)
|
||||
|
||||
@Query("SELECT * FROM TemporaryTransformationHistory WHERE monId = :monId")
|
||||
fun getTransformationHistory(monId: Int): List<TemporaryTransformationHistory>
|
||||
|
||||
@Query("SELECT * FROM TemporaryCharacterData")
|
||||
suspend fun getAllCharacters(): List<TemporaryCharacterData>
|
||||
|
||||
@Query("SELECT * FROM TemporaryCharacterData WHERE id = :id")
|
||||
suspend fun getCharacter(id: Long): TemporaryCharacterData
|
||||
}
|
||||
@ -1,44 +0,0 @@
|
||||
package com.github.nacabaro.vbhelper.temporary_domain
|
||||
|
||||
import androidx.room.Entity
|
||||
import androidx.room.ForeignKey
|
||||
import androidx.room.PrimaryKey
|
||||
import com.github.cfogrady.vbnfc.be.BENfcCharacter
|
||||
import com.github.cfogrady.vbnfc.be.FirmwareVersion
|
||||
import com.github.cfogrady.vbnfc.data.NfcCharacter
|
||||
|
||||
@Entity(
|
||||
foreignKeys = [
|
||||
ForeignKey(
|
||||
entity = TemporaryCharacterData::class,
|
||||
parentColumns = ["id"],
|
||||
childColumns = ["id"],
|
||||
onDelete = ForeignKey.CASCADE
|
||||
)
|
||||
]
|
||||
)
|
||||
data class TemporaryBECharacterData (
|
||||
@PrimaryKey(autoGenerate = true) val id: Long,
|
||||
val trainingHp: Int,
|
||||
val trainingAp: Int,
|
||||
val trainingBp: Int,
|
||||
val remainingTrainingTimeInMinutes: Int,
|
||||
val itemEffectMentalStateValue: Int,
|
||||
val itemEffectMentalStateMinutesRemaining: Int,
|
||||
val itemEffectActivityLevelValue: Int,
|
||||
val itemEffectActivityLevelMinutesRemaining: Int,
|
||||
val itemEffectVitalPointsChangeValue: Int,
|
||||
val itemEffectVitalPointsChangeMinutesRemaining: Int,
|
||||
val abilityRarity: NfcCharacter.AbilityRarity,
|
||||
val abilityType: Int,
|
||||
val abilityBranch: Int,
|
||||
val abilityReset: Int,
|
||||
val rank: Int,
|
||||
val itemType: Int,
|
||||
val itemMultiplier: Int,
|
||||
val itemRemainingTime: Int,
|
||||
val otp0: String,
|
||||
val otp1: String,
|
||||
val minorVersion: Int,
|
||||
val majorVersion: Int,
|
||||
)
|
||||
@ -1,25 +0,0 @@
|
||||
package com.github.nacabaro.vbhelper.temporary_domain
|
||||
|
||||
import androidx.room.Entity
|
||||
import androidx.room.ForeignKey
|
||||
import androidx.room.PrimaryKey
|
||||
|
||||
@Entity(
|
||||
foreignKeys = [
|
||||
ForeignKey(
|
||||
entity = TemporaryCharacterData::class,
|
||||
parentColumns = ["id"],
|
||||
childColumns = ["monId"],
|
||||
onDelete = ForeignKey.CASCADE
|
||||
)
|
||||
]
|
||||
)
|
||||
// Bit lazy, will correct later...
|
||||
data class TemporaryTransformationHistory (
|
||||
@PrimaryKey(autoGenerate = true) val id: Long = 0,
|
||||
val monId: Long,
|
||||
val toCharIndex: Int,
|
||||
val yearsSince1988: Int,
|
||||
val month: Int,
|
||||
val day: Int
|
||||
)
|
||||
Loading…
x
Reference in New Issue
Block a user