extends Button var text_array: Array[String] var page = 0 func _ready() -> void: set_text_array() set_text_to_page() func set_text_to_page() -> void: self.text = text_array[page] func next_page() -> void: if page < text_array.size() - 1: page += 1 set_text_to_page() else: var character = get_node("/root/GameplayScene/Character") if character.abstraction > 3: var winScene = load("res://Scenes/win_screen.tscn") get_tree().change_scene_to_packed(winScene) else: var lossScene = load("res://Scenes/loss_screen.tscn") get_tree().change_scene_to_packed(lossScene) func set_text_array() -> void: text_array.push_back("[Autumn]: Hi, I’m Autumn.") text_array.push_back("[Autumn]: I study veterinary medicine and have a part-time job as a veterinary assistant.\n I handle all sorts of things around the clinic ranging from procedures to comforting pets and making sure things run smoothly.\n I wouldn’t trade it for anything though.\n Are you an animal person?") text_array.push_back("[Autumn]: In my spare time I love to go shopping, do yoga and go hiking in nature.\n My recent addictions include flavored ChapSticks and Pumpkin-Spice Latte.") text_array.push_back("[Autumn]: Well, I do have a peculiar hobby… it’s taxidermy.\n I know it’s unusual, but I am just fascinated by animals and their anatomy.\n I collect pieces to appreciate it up close.\n A lot of people think it’s strange, but to me it’s a way to respect the animals and preserve their natural state.") text_array.push_back("[Autumn]: My favorite piece is that of a lion I inherited from my grandfather.\n I think part of the reason why I am so fond of it is the memory I have of my grandfather telling me the story of the lion’s life and how it ended.\n I must say, the lion can be a bit scary at night though, haha.") text_array.push_back("[Autumn]: I love the fresh air and being surrounded by nature.\n When I go hiking it really helps me re-align with nature in contrast to the chaos that working at the clinic can bring.\n If you’re quiet enough during a hike, you might even spot a few animals!") text_array.push_back("[Autumn]: Sometimes though,\n I’d like to have a little picknick or maybe throw down a blanket and read a good book.") text_array.push_back("[Autumn]: Thanks, It was a pleasure to meet you.")