-
Notifications
You must be signed in to change notification settings - Fork 0
/
PlayerSession.ts
74 lines (62 loc) · 2.84 KB
/
PlayerSession.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
import { Farm, Siege, Trade, Travel } from "./Events"
import { hitpoint_array } from "./hitpoint"
import { PlayerAttributes } from "./PlayerAttributes"
export class PlayerSession {
attributes: PlayerAttributes
game_states: any[]
constructor(attributes: PlayerAttributes) {
this.attributes = attributes
this.game_states = []
}
getPrompt() {
let strPrompt = ""
this.game_states.forEach((state) => {
strPrompt += state.getPrompt() + " "
})
return strPrompt
}
getMidJourneyPrompt() {
let strPrompt = ""
let mid_journey_intro =
"Double exposure, with fantasy landscape of castles and rivers and war. "
let mid_journey_outro =
" Ancient, no guns, Fantasy landscape, ancient, Arthurian era, Medieval era. Black background. In the style of a realist painting. cinematic, post-production, depth of field,cinematography, cinema, color grading, professional color grading, 35mm lens, incredibly detailed Double exposure, with fantasy landscape of castles and rivers and war. With a restless spirit, She marches to Oltoltek, 412 hectares away. The travel was not without cost. Behold! A siege befalls our hero. Confronted by 2 foes, a battle ensues, leaving our protagonist with 3 hits sustained, losing 3 vital hit points. As fate would have it, our hero is victorious! Seeking adventure and good fortune, our hero travels to Skohnikkezh, 12 hectares away. The travel was not without cost. While traveling the lands of Skohnikkezh, Naima trades with Galbraith. Settled in the the lands of Skohnikkezh, She has the need to farm resources for the next leg ahead. Ancient, no guns, Fantasy landscape, ancient, Arthurian era, Medieval era. Black background. In the style of a realist painting. cinematic, post-production, depth of field,cinematography, cinema, color grading, professional color grading, 35mm lens, incredibly detailed --no text --v 4 --q 2 --v 4 --q 2"
strPrompt += mid_journey_intro
this.game_states.forEach((state) => {
strPrompt += state.getMidJourneyPrompt() + " "
})
return strPrompt + mid_journey_outro
}
addEvent() {
let travelevent = new Travel(
this.attributes,
"Oltoltek",
412,
"2 hens, 1 rabbit, 9 root vegetables"
)
let siegeevent = new Siege(this.attributes, "Oltoltek", 2, 3, 0, 3)
let travelevent2 = new Travel(
this.attributes,
"Skohnikkezh",
12,
"5, fish 4 root vegetables"
)
let tradeevent = new Trade(
this.attributes,
"Galbraith",
"Tannis Root",
"copper"
)
let farmevent = new Farm(
this.attributes,
"Skohnikkezh",
2,
"24 fish, 37 root vegetables"
)
this.game_states.push(travelevent)
this.game_states.push(siegeevent)
this.game_states.push(travelevent2)
this.game_states.push(tradeevent)
this.game_states.push(farmevent)
}
}