37 lines
934 B
TypeScript
37 lines
934 B
TypeScript
import { useUserinfoStore } from "@/stores/UserinfoStore"
|
|
|
|
export async function collectQuotes(): Promise<void> {
|
|
const userInfoStore = useUserinfoStore()
|
|
await this.callApi('/api/collectQuotes', {
|
|
g: userInfoStore.gameId,
|
|
})
|
|
}
|
|
|
|
export async function startGame(): Promise<void> {
|
|
const userInfoStore = useUserinfoStore()
|
|
await this.callApi('/api/startGame', {
|
|
g: userInfoStore.gameId,
|
|
})
|
|
}
|
|
|
|
export async function continueGame(): Promise<void> {
|
|
const userInfoStore = useUserinfoStore()
|
|
await this.callApi('/api/continueGame', {
|
|
g: userInfoStore.gameId,
|
|
})
|
|
}
|
|
|
|
export async function resetGame(): Promise<void> {
|
|
const userInfoStore = useUserinfoStore()
|
|
await this.callApi('/api/resetGame', {
|
|
g: userInfoStore.gameId,
|
|
})
|
|
}
|
|
|
|
export async function finishGame(): Promise<void> {
|
|
const userInfoStore = useUserinfoStore()
|
|
await this.callApi('/api/finishGame', {
|
|
g: userInfoStore.gameId,
|
|
})
|
|
}
|