Implemented first demo quest line #15
Merged
Jonathan
merged 11 commits from feature/implement_quests into develop 5 months ago
@ -1,6 +1,12 @@
|
||||
<wpf:ResourceDictionary xml:space="preserve" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:s="clr-namespace:System;assembly=mscorlib" xmlns:ss="urn:shemas-jetbrains-com:settings-storage-xaml" xmlns:wpf="http://schemas.microsoft.com/winfx/2006/xaml/presentation">
|
||||
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AArea3D_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003F_002E_002E_003F_002E_002E_003F_002Econfig_003FJetBrains_003FRider2024_002E3_003Fresharper_002Dhost_003FSourcesCache_003F8a54226fa2e1c9371a8091f24cfd744aef11fe6869527dc23b9b837623a29b9_003FArea3D_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
|
||||
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AAudioStreamPlayer2D_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003F_002E_002E_003F_002E_002E_003F_002Econfig_003FJetBrains_003FRider2025_002E1_003Fresharper_002Dhost_003FSourcesCache_003F848324b1c23114c3f5e8bbb5a42c4ade394c59a7a7a133a66b76581ca571_003FAudioStreamPlayer2D_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
|
||||
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003ABabushka_002Escripts_002ECSharp_002ECommon_002EFarming_002EVesnaBehaviour2D_005FScriptProperties_002Egenerated_002Ecs_002Fl_003AC_0021_003FUsers_003FJonathan_003FAppData_003FRoaming_003FJetBrains_003FRider2025_002E1_003Fresharper_002Dhost_003FSourcesCache_003F4298b0f293f987511fc1b7956ee691fd778f8378_003FBabushka_002Escripts_002ECSharp_002ECommon_002EFarming_002EVesnaBehaviour2D_005FScriptProperties_002Egenerated_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
|
||||
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003ABabushka_002Escripts_002ECSharp_002ECommon_002EQuest_002EQuestListItemUi_005FScriptMethods_002Egenerated_002Ecs_002Fl_003AC_0021_003FUsers_003FJonathan_003FAppData_003FRoaming_003FJetBrains_003FRider2025_002E1_003Fresharper_002Dhost_003FSourcesCache_003F48fad7e7f3c9e292b3fdbddf9d363f0d1752aa_003FBabushka_002Escripts_002ECSharp_002ECommon_002EQuest_002EQuestListItemUi_005FScriptMethods_002Egenerated_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
|
||||
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003ACastHelpers_002Ecs_002Fl_003AC_0021_003FUsers_003FJonathan_003FAppData_003FRoaming_003FJetBrains_003FRider2025_002E1_003Fresharper_002Dhost_003FSourcesCache_003F3c92637ae2e83da0a63791071c41eae291d594156062866d8621b7ed7245c_003FCastHelpers_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
|
||||
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003ACastHelpers_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003F_002E_002E_003F_002E_002E_003F_002Econfig_003FJetBrains_003FRider2025_002E1_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003Fd111abf504bf42b5968a609b168fd093b2e200_003Fbb_003F1c116fcd_003FCastHelpers_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
|
||||
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003ACharacterBody2D_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003F_002E_002E_003F_002E_002E_003F_002Econfig_003FJetBrains_003FRider2025_002E1_003Fresharper_002Dhost_003FSourcesCache_003Fbba0bbd7a98ee58286e9484fbe86e01afff6232283f6efd3556eb7116453_003FCharacterBody2D_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
|
||||
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003ANode_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003F_002E_002E_003F_002E_002E_003F_002Econfig_003FJetBrains_003FRider2025_002E1_003Fresharper_002Dhost_003FSourcesCache_003Ff1d69ec2da76ccf9bc8a75c8e0fdca9a7ba1adf8c8c9d5047e2fa5991c02eca_003FNode_002Ecs/@EntryIndexedValue">ForceIncluded</s:String></wpf:ResourceDictionary>
|
||||
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003ADictionary_00602_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003F_002E_002E_003F_002E_002E_003F_002E_002E_003F_002E_002E_003Fhome_003Fjonathan_003F_002Econfig_003FJetBrains_003FRider2025_002E1_003Fresharper_002Dhost_003FDecompilerCache_003Fdecompiler_003Fe37dc1faf08a4d5ea030ad59bdf77522523400_003Fd4_003Fbd338aeb_003FDictionary_00602_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
|
||||
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003ANode_002Ecs_002Fl_003A_002E_002E_003F_002E_002E_003F_002E_002E_003F_002E_002E_003F_002Econfig_003FJetBrains_003FRider2025_002E1_003Fresharper_002Dhost_003FSourcesCache_003Ff1d69ec2da76ccf9bc8a75c8e0fdca9a7ba1adf8c8c9d5047e2fa5991c02eca_003FNode_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
|
||||
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AResourceLoader_002Ecs_002Fl_003AC_0021_003FUsers_003FJonathan_003FAppData_003FRoaming_003FJetBrains_003FRider2025_002E1_003Fresharper_002Dhost_003FSourcesCache_003F9f4e8eb124d11f8219cb513a19bed22b2120ed29f9d6785ba56e3367b48d581_003FResourceLoader_002Ecs/@EntryIndexedValue">ForceIncluded</s:String>
|
||||
<s:String x:Key="/Default/CodeInspection/ExcludedFiles/FilesAndFoldersToSkip2/=7020124F_002D9FFC_002D4AC3_002D8F3D_002DAAB8E0240759_002Ff_003AThrowHelper_002Ecs_002Fl_003AC_0021_003FUsers_003FJonathan_003FAppData_003FRoaming_003FJetBrains_003FRider2025_002E1_003Fresharper_002Dhost_003FSourcesCache_003Fc7102cd0ffb8973777e61b1942c3fffac7e14016a511d055c3adf73ff91748_003FThrowHelper_002Ecs/@EntryIndexedValue">ForceIncluded</s:String></wpf:ResourceDictionary>
|
||||
@ -0,0 +1,22 @@
|
||||
@tool
|
||||
extends EditorPlugin
|
||||
|
||||
|
||||
func _enter_tree() -> void:
|
||||
if !ProjectSettings.has_setting("babushka/hacks/speed_hack"):
|
||||
ProjectSettings.set_setting("babushka/hacks/speed_hack",-1)
|
||||
|
||||
var property_info = {
|
||||
"name": "babushka/hacks/speed_hack",
|
||||
"type": TYPE_FLOAT,
|
||||
"hint": PROPERTY_HINT_RANGE,
|
||||
"hint_string": "-1,20,0.5"
|
||||
}
|
||||
|
||||
ProjectSettings.add_property_info(property_info)
|
||||
ProjectSettings.set_initial_value("babushka/hacks/speed_hack",-1)
|
||||
|
||||
|
||||
func _exit_tree() -> void:
|
||||
# Clean-up of the plugin goes here.
|
||||
pass
|
||||
@ -0,0 +1 @@
|
||||
uid://buwfplh0xji8q
|
||||
@ -0,0 +1,7 @@
|
||||
[plugin]
|
||||
|
||||
name="BabushkaHelpers"
|
||||
description=""
|
||||
author="Cozy Raven"
|
||||
version=""
|
||||
script="babushkahelpers.gd"
|
||||
@ -0,0 +1,55 @@
|
||||
@tool
|
||||
extends DialogicEvent
|
||||
class_name DialogicQuestActivateEvent
|
||||
|
||||
|
||||
# Define properties of the event here
|
||||
var quest_resource: String
|
||||
|
||||
func _execute() -> void:
|
||||
var resource = ResourceLoader.load(quest_resource)
|
||||
QuestManager.ChangeQuestStatus(resource,QuestEventUtils.QuestStatus.AVAILABLE)
|
||||
QuestManager.SetActiveQuest(resource)
|
||||
finish() # called to continue with the next event
|
||||
|
||||
|
||||
#region INITIALIZE
|
||||
################################################################################
|
||||
# Set fixed settings of this event
|
||||
func _init() -> void:
|
||||
event_name = "Activate Quest"
|
||||
event_category = "Quest"
|
||||
|
||||
|
||||
|
||||
#endregion
|
||||
|
||||
#region SAVING/LOADING
|
||||
################################################################################
|
||||
func get_shortcode() -> String:
|
||||
return "quest_activate"
|
||||
|
||||
func get_shortcode_parameters() -> Dictionary:
|
||||
return {
|
||||
#param_name : property_info
|
||||
"quest_resource" : {"property": "quest_resource", "default": ""},
|
||||
}
|
||||
|
||||
# You can alternatively overwrite these 3 functions: to_text(), from_text(), is_valid_event()
|
||||
#endregion
|
||||
|
||||
|
||||
#region EDITOR REPRESENTATION
|
||||
################################################################################
|
||||
|
||||
func build_event_editor() -> void:
|
||||
add_header_label("Activate Quest")
|
||||
add_header_edit(
|
||||
"quest_resource",
|
||||
ValueType.DYNAMIC_OPTIONS,
|
||||
{
|
||||
"mode":2,
|
||||
"suggestions_func":QuestEventUtils.quest_resource_suggestrions
|
||||
})
|
||||
|
||||
#endregion
|
||||
@ -0,0 +1 @@
|
||||
uid://br3a7napsjmg3
|
||||
@ -0,0 +1,55 @@
|
||||
@tool
|
||||
extends DialogicEvent
|
||||
class_name DialogicQuestCompleteEvent
|
||||
|
||||
|
||||
# Define properties of the event here
|
||||
var quest_resource: String
|
||||
|
||||
func _execute() -> void:
|
||||
var resource = ResourceLoader.load(quest_resource)
|
||||
QuestManager.ChangeQuestStatus(resource,QuestEventUtils.QuestStatus.DONE)
|
||||
QuestManager.SetActiveQuest(null)
|
||||
finish() # called to continue with the next event
|
||||
|
||||
|
||||
#region INITIALIZE
|
||||
################################################################################
|
||||
# Set fixed settings of this event
|
||||
func _init() -> void:
|
||||
event_name = "Complete Quest"
|
||||
event_category = "Quest"
|
||||
|
||||
|
||||
|
||||
#endregion
|
||||
|
||||
#region SAVING/LOADING
|
||||
################################################################################
|
||||
func get_shortcode() -> String:
|
||||
return "quest_complete"
|
||||
|
||||
func get_shortcode_parameters() -> Dictionary:
|
||||
return {
|
||||
#param_name : property_info
|
||||
"quest_resource" : {"property": "quest_resource", "default": ""},
|
||||
}
|
||||
|
||||
# You can alternatively overwrite these 3 functions: to_text(), from_text(), is_valid_event()
|
||||
#endregion
|
||||
|
||||
|
||||
#region EDITOR REPRESENTATION
|
||||
################################################################################
|
||||
|
||||
func build_event_editor() -> void:
|
||||
add_header_label("Complete Quest")
|
||||
add_header_edit(
|
||||
"quest_resource",
|
||||
ValueType.DYNAMIC_OPTIONS,
|
||||
{
|
||||
"mode":2,
|
||||
"suggestions_func":QuestEventUtils.quest_resource_suggestrions
|
||||
})
|
||||
|
||||
#endregion
|
||||
@ -0,0 +1 @@
|
||||
uid://c8mtjwpe7c0h
|
||||
@ -0,0 +1,163 @@
|
||||
@tool
|
||||
extends DialogicEvent
|
||||
class_name DialogicQuestConditionEvent
|
||||
|
||||
## Event that allows branching a timeline based on a condition.
|
||||
|
||||
#enum ConditionTypes {IF, ELIF, ELSE}
|
||||
|
||||
### Settings
|
||||
## condition type (see [ConditionTypes]). Defaults to if.
|
||||
#var condition_type := ConditionTypes.IF
|
||||
## The condition as a string. Will be executed as an Expression.
|
||||
#var condition := ""
|
||||
var quest_resource: String
|
||||
var compare_status: QuestEventUtils.QuestStatusOrActive
|
||||
|
||||
################################################################################
|
||||
## EXECUTE
|
||||
################################################################################
|
||||
|
||||
func _execute() -> void:
|
||||
var resource = ResourceLoader.load(quest_resource)
|
||||
|
||||
var result: bool
|
||||
if compare_status == QuestEventUtils.QuestStatusOrActive.ACTIVE:
|
||||
result = QuestManager.GetActiveQuest() == resource
|
||||
elif compare_status == QuestEventUtils.QuestStatusOrActive.NOT_ACTIVE:
|
||||
result = QuestManager.GetActiveQuest() != resource
|
||||
else:
|
||||
result = QuestManager.GetQuestStatus(resource).status == compare_status
|
||||
|
||||
if not result:
|
||||
var idx: int = dialogic.current_event_idx
|
||||
var ignore := 1
|
||||
while true:
|
||||
idx += 1
|
||||
if not dialogic.current_timeline.get_event(idx) or ignore == 0:
|
||||
break
|
||||
elif dialogic.current_timeline.get_event(idx).can_contain_events:
|
||||
ignore += 1
|
||||
elif dialogic.current_timeline.get_event(idx) is DialogicEndBranchEvent:
|
||||
ignore -= 1
|
||||
|
||||
dialogic.current_event_idx = idx-1
|
||||
finish()
|
||||
|
||||
|
||||
## only called if the previous event was an end-branch event
|
||||
## return true if this event should be executed if the previous event was an end-branch event
|
||||
func should_execute_this_branch() -> bool:
|
||||
return true
|
||||
|
||||
|
||||
################################################################################
|
||||
## INITIALIZE
|
||||
################################################################################
|
||||
|
||||
func _init() -> void:
|
||||
event_name = "Quest Condition"
|
||||
set_default_color('Color3')
|
||||
event_category = "Quest"
|
||||
event_sorting_index = 1
|
||||
can_contain_events = true
|
||||
|
||||
|
||||
# return a control node that should show on the END BRANCH node
|
||||
func get_end_branch_control() -> Control:
|
||||
return load(get_script().resource_path.get_base_dir().path_join('ui_quest_condition_end.tscn')).instantiate()
|
||||
|
||||
################################################################################
|
||||
## SAVING/LOADING
|
||||
################################################################################
|
||||
|
||||
func to_text() -> String:
|
||||
return 'ifquest ' + quest_resource + ', ' + str(compare_status) + ':'
|
||||
|
||||
|
||||
func from_text(string:String) -> void:
|
||||
#if string.strip_edges().begins_with('if'):
|
||||
# condition = string.strip_edges().trim_prefix('if ').trim_suffix(':').strip_edges()
|
||||
# condition_type = ConditionTypes.IF
|
||||
var strings:Array[String]
|
||||
strings.assign(string.strip_edges().trim_prefix('ifquest ').trim_suffix(':').strip_edges().split(','))
|
||||
quest_resource = strings[0].strip_edges()
|
||||
var compare_string: String = strings[1].strip_edges()
|
||||
if compare_string.is_valid_int():
|
||||
compare_status = compare_string.to_int()
|
||||
else:
|
||||
compare_status = QuestEventUtils.QuestStatusOrActive.get(compare_string)
|
||||
|
||||
|
||||
func is_valid_event(string:String) -> bool:
|
||||
if string.strip_edges().begins_with('ifquest '):
|
||||
return true
|
||||
return false
|
||||
|
||||
|
||||
################################################################################
|
||||
## EDITOR REPRESENTATION
|
||||
################################################################################
|
||||
|
||||
func build_event_editor() -> void:
|
||||
add_header_label("IF")
|
||||
add_header_edit(
|
||||
"quest_resource",
|
||||
ValueType.DYNAMIC_OPTIONS,
|
||||
{
|
||||
"mode":2,
|
||||
"suggestions_func":QuestEventUtils.quest_resource_suggestrions
|
||||
})
|
||||
add_header_label("IS")
|
||||
add_header_edit("compare_status",ValueType.FIXED_OPTIONS,{
|
||||
'options': [
|
||||
{
|
||||
'label': 'HIDDEN',
|
||||
'value': QuestEventUtils.QuestStatusOrActive.HIDDEN,
|
||||
},
|
||||
{
|
||||
'label': 'AVAILABLE',
|
||||
'value': QuestEventUtils.QuestStatusOrActive.AVAILABLE,
|
||||
},
|
||||
{
|
||||
'label': 'DONE',
|
||||
'value': QuestEventUtils.QuestStatusOrActive.DONE,
|
||||
},
|
||||
{
|
||||
'label': 'CANCLED',
|
||||
'value': QuestEventUtils.QuestStatusOrActive.CANCLED,
|
||||
},
|
||||
{
|
||||
'label': 'ACTIVE',
|
||||
'value': QuestEventUtils.QuestStatusOrActive.ACTIVE,
|
||||
},
|
||||
{
|
||||
'label': 'NOT_ACTIVE',
|
||||
'value': QuestEventUtils.QuestStatusOrActive.NOT_ACTIVE,
|
||||
}
|
||||
]})
|
||||
|
||||
func _get_icon() -> Resource:
|
||||
return load("res://addons/dialogic/Modules/Condition/icon.svg")
|
||||
|
||||
####################### CODE COMPLETION ########################################
|
||||
################################################################################
|
||||
|
||||
func _get_code_completion(CodeCompletionHelper:Node, TextNode:TextEdit, line:String, _word:String, symbol:String) -> void:
|
||||
pass
|
||||
|
||||
|
||||
func _get_start_code_completion(_CodeCompletionHelper:Node, TextNode:TextEdit) -> void:
|
||||
TextNode.add_code_completion_option(CodeEdit.KIND_PLAIN_TEXT, 'ifquest', 'ifquest ', TextNode.syntax_highlighter.code_flow_color)
|
||||
|
||||
|
||||
#################### SYNTAX HIGHLIGHTING #######################################
|
||||
################################################################################
|
||||
|
||||
|
||||
func _get_syntax_highlighting(Highlighter:SyntaxHighlighter, dict:Dictionary, line:String) -> Dictionary:
|
||||
var word := line.get_slice(' ', 0)
|
||||
dict[line.find(word)] = {"color":Highlighter.code_flow_color}
|
||||
dict[line.find(word)+len(word)] = {"color":Highlighter.normal_color}
|
||||
dict = Highlighter.color_condition(dict, line)
|
||||
return dict
|
||||
@ -0,0 +1 @@
|
||||
uid://b2ggc2f5kh61j
|
||||
@ -0,0 +1,43 @@
|
||||
@tool
|
||||
class_name QuestEventUtils
|
||||
|
||||
enum QuestStatus{
|
||||
HIDDEN = 0,
|
||||
AVAILABLE = 1,
|
||||
DONE = 2,
|
||||
CANCLED = 3
|
||||
}
|
||||
|
||||
enum QuestStatusOrActive{
|
||||
HIDDEN = 0,
|
||||
AVAILABLE = 1,
|
||||
DONE = 2,
|
||||
CANCLED = 3,
|
||||
ACTIVE = 4,
|
||||
NOT_ACTIVE = 5
|
||||
}
|
||||
|
||||
|
||||
static func quest_resource_suggestrions(search_text:String) -> Dictionary:
|
||||
var ret_val = {}
|
||||
var quest_paths = get_all_file_paths("res://resources/quests")
|
||||
|
||||
for path in quest_paths:
|
||||
var res = ResourceLoader.load(path)
|
||||
ret_val[res.id]= {"value":path, "tooltip":res.title + "\n\n" + res.description}
|
||||
|
||||
return ret_val
|
||||
|
||||
static func get_all_file_paths(path: String) -> Array[String]:
|
||||
var file_paths: Array[String] = []
|
||||
var dir = DirAccess.open(path)
|
||||
dir.list_dir_begin()
|
||||
var file_name = dir.get_next()
|
||||
while file_name != "":
|
||||
var file_path = path + "/" + file_name
|
||||
if dir.current_is_dir():
|
||||
file_paths += get_all_file_paths(file_path)
|
||||
else:
|
||||
file_paths.append(file_path)
|
||||
file_name = dir.get_next()
|
||||
return file_paths
|
||||
@ -0,0 +1 @@
|
||||
uid://d1x2343wpkdku
|
||||
@ -0,0 +1,9 @@
|
||||
@tool
|
||||
extends DialogicIndexer
|
||||
|
||||
func _get_events() -> Array:
|
||||
return [
|
||||
this_folder.path_join('event_quest_activate.gd'),
|
||||
this_folder.path_join('event_quest_complete.gd'),
|
||||
this_folder.path_join('event_quest_condition.gd')
|
||||
]
|
||||
@ -0,0 +1 @@
|
||||
uid://wup1fvm05rqv
|
||||
@ -0,0 +1,51 @@
|
||||
@tool
|
||||
extends HBoxContainer
|
||||
|
||||
var parent_resource: DialogicEvent = null
|
||||
|
||||
|
||||
func _ready() -> void:
|
||||
$AddElif.button_up.connect(add_elif)
|
||||
$AddElse.button_up.connect(add_else)
|
||||
|
||||
|
||||
func refresh() -> void:
|
||||
if parent_resource is DialogicQuestConditionEvent:
|
||||
# hide add elif and add else button on ELSE event
|
||||
$AddElif.visible = false# parent_resource.condition_type != DialogicConditionEvent.ConditionTypes.ELSE
|
||||
$AddElse.visible = true# parent_resource.condition_type != DialogicConditionEvent.ConditionTypes.ELSE
|
||||
$Label.text = "End of If Quest" #"End of "+["IF", "ELIF", "ELSE"][parent_resource.condition_type]+" ("+parent_resource.condition+")"
|
||||
|
||||
# hide add add else button if followed by ELIF or ELSE event
|
||||
var timeline_editor := find_parent('VisualEditor')
|
||||
if timeline_editor:
|
||||
var next_event: DialogicEvent = null
|
||||
if timeline_editor.get_block_below(get_parent()):
|
||||
next_event = timeline_editor.get_block_below(get_parent()).resource
|
||||
if next_event is DialogicConditionEvent:
|
||||
if next_event.condition_type != DialogicConditionEvent.ConditionTypes.IF:
|
||||
$AddElse.hide()
|
||||
#if parent_resource.condition_type == DialogicConditionEvent.ConditionTypes.ELSE:
|
||||
# $Label.text = "End of ELSE"
|
||||
else:
|
||||
hide()
|
||||
|
||||
|
||||
func add_elif() -> void:
|
||||
var timeline := find_parent('VisualEditor')
|
||||
if timeline:
|
||||
var resource := DialogicConditionEvent.new()
|
||||
resource.condition_type = DialogicConditionEvent.ConditionTypes.ELIF
|
||||
timeline.add_event_undoable(resource, get_parent().get_index()+1)
|
||||
timeline.indent_events()
|
||||
timeline.something_changed()
|
||||
|
||||
|
||||
func add_else() -> void:
|
||||
var timeline := find_parent('VisualEditor')
|
||||
if timeline:
|
||||
var resource := DialogicConditionEvent.new()
|
||||
resource.condition_type = DialogicConditionEvent.ConditionTypes.ELSE
|
||||
timeline.add_event_undoable(resource, get_parent().get_index()+1)
|
||||
timeline.indent_events()
|
||||
timeline.something_changed()
|
||||
@ -0,0 +1 @@
|
||||
uid://dlrnhnnonum4o
|
||||
@ -0,0 +1,20 @@
|
||||
[gd_scene load_steps=2 format=3 uid="uid://dnrpcgjkyoiau"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://dlrnhnnonum4o" path="res://addons/dialogic_additions/Quest/ui_condition_end.gd" id="1_f3miq"]
|
||||
|
||||
[node name="Condition_End" type="HBoxContainer"]
|
||||
offset_right = 90.0
|
||||
offset_bottom = 23.0
|
||||
script = ExtResource("1_f3miq")
|
||||
|
||||
[node name="Label" type="Label" parent="."]
|
||||
layout_mode = 2
|
||||
text = "End of condition X"
|
||||
|
||||
[node name="AddElif" type="Button" parent="."]
|
||||
layout_mode = 2
|
||||
text = "Add Elif"
|
||||
|
||||
[node name="AddElse" type="Button" parent="."]
|
||||
layout_mode = 2
|
||||
text = "Add Else"
|
||||
@ -1,6 +1,8 @@
|
||||
[quest_complete quest_resource="res://resources/quests/demo/7_talk_yeli_inside_1.tres"]
|
||||
join Yeli center
|
||||
Yeli: Thank you for your help out there.
|
||||
Yeli: Thank you for your help out there.
|
||||
Yeli: You must be tired. Please rest. I prepared a bed for you. It's in the room to the left.
|
||||
Yeli: There is nothing interesting to see here.
|
||||
leave Yeli
|
||||
[quest_activate quest_resource="res://resources/quests/demo/8_goto_bed.tres"]
|
||||
[end_timeline]
|
||||
|
||||
@ -1,8 +1,10 @@
|
||||
join Yeli right
|
||||
join vesna left
|
||||
[quest_complete quest_resource="res://resources/quests/demo/1_talk_yeli_1.tres"]
|
||||
Yeli (_part_side): Come here, you little quacking beast!
|
||||
- What a mess!
|
||||
- How did you call me?
|
||||
Yeli (_part_side): Vesna, oh, thank goodness!
|
||||
Yeli (_part_side): Please could you get the runner ducks back into their coop?
|
||||
[quest_activate quest_resource="res://resources/quests/demo/2_collect_ducks.tres"]
|
||||
[end_timeline]
|
||||
|
||||
@ -0,0 +1,15 @@
|
||||
Quest\: {ACTIVEQUEST}
|
||||
ifquest res://resources/quests/test/test_01.tres, 4:
|
||||
Test 1 active
|
||||
else:
|
||||
Test 1 is not active
|
||||
ifquest res://resources/quests/test/test_01.tres, 1:
|
||||
But its available
|
||||
else:
|
||||
And not available
|
||||
ifquest res://resources/quests/test/test_02.tres, 4:
|
||||
Test 2 active
|
||||
ifquest res://resources/quests/test/test_02.tres, 1:
|
||||
And Available
|
||||
else:
|
||||
Else 2
|
||||
@ -0,0 +1 @@
|
||||
uid://xfkdvitmhgln
|
||||
@ -0,0 +1,10 @@
|
||||
ifquest res://resources/quests/demo/1_talk_yeli_1.tres, 1:
|
||||
jump quest1_ducks_start/
|
||||
[end_timeline]
|
||||
ifquest res://resources/quests/demo/3_talk_yeli_2.tres, 1:
|
||||
jump quest2_tomatoes_start/
|
||||
[end_timeline]
|
||||
ifquest res://resources/quests/demo/5_talk_yeli_3.tres, 1:
|
||||
jump quest2_tomatoes_interim/
|
||||
[end_timeline]
|
||||
No Dialog for active quest "{ACTIVEQUEST}"
|
||||
@ -0,0 +1 @@
|
||||
uid://do3c5uofv5m7b
|
||||
@ -0,0 +1,12 @@
|
||||
[gd_scene load_steps=3 format=3 uid="uid://bworek1jcmq0e"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://dl2uhq12p3qks" path="res://scripts/CSharp/Common/Quest/QuestManager.cs" id="1_anowe"]
|
||||
[ext_resource type="Script" path="res://scripts/GdScript/dialogic_var_setter.gd" id="4_v86gc"]
|
||||
|
||||
[node name="QuestManager" type="Node"]
|
||||
script = ExtResource("1_anowe")
|
||||
|
||||
[node name="DialogicRelay" type="Node" parent="."]
|
||||
script = ExtResource("4_v86gc")
|
||||
|
||||
[connection signal="DialogicActiveQuest" from="." to="DialogicRelay" method="_SetActiveQuestVar"]
|
||||
@ -0,0 +1,10 @@
|
||||
[gd_resource type="Resource" script_class="QuestResource" load_steps=2 format=3 uid="uid://cv3wtnn0138ax"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://vji5lp4qc8pp" path="res://scripts/CSharp/Common/Quest/QuestResource.cs" id="1_m0nkd"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("1_m0nkd")
|
||||
id = "10_fight_the_monsters"
|
||||
title = "Fight the monsters"
|
||||
description = "A dangerous path lies before you. Be brave and slay the monsters to reach the other side."
|
||||
metadata/_custom_type_script = "uid://vji5lp4qc8pp"
|
||||
@ -0,0 +1,10 @@
|
||||
[gd_resource type="Resource" script_class="QuestResource" load_steps=2 format=3 uid="uid://cm8kftow8br00"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://vji5lp4qc8pp" path="res://scripts/CSharp/Common/Quest/QuestResource.cs" id="1_xjwrv"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("1_xjwrv")
|
||||
id = "1_talk_yeli_1"
|
||||
title = "Talk to Yeli"
|
||||
description = ""
|
||||
metadata/_custom_type_script = "uid://vji5lp4qc8pp"
|
||||
@ -0,0 +1,10 @@
|
||||
[gd_resource type="Resource" script_class="QuestResource" load_steps=2 format=3 uid="uid://cy0na3ukvpoou"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://vji5lp4qc8pp" path="res://scripts/CSharp/Common/Quest/QuestResource.cs" id="1_wactd"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("1_wactd")
|
||||
id = "2_collect_ducks"
|
||||
title = "Collect the Ducks"
|
||||
description = "Collect all 6 ducks running around the farm by aporaching them and pressing [E]"
|
||||
metadata/_custom_type_script = "uid://vji5lp4qc8pp"
|
||||
@ -0,0 +1,10 @@
|
||||
[gd_resource type="Resource" script_class="QuestResource" load_steps=2 format=3 uid="uid://mf0rdejw8fuk"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://vji5lp4qc8pp" path="res://scripts/CSharp/Common/Quest/QuestResource.cs" id="1_70pjl"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("1_70pjl")
|
||||
id = "3_talk_yeli_2"
|
||||
title = "Talk to Yeli again"
|
||||
description = "All ducks are collected. Head back to yeli."
|
||||
metadata/_custom_type_script = "uid://vji5lp4qc8pp"
|
||||
@ -0,0 +1,10 @@
|
||||
[gd_resource type="Resource" script_class="QuestResource" load_steps=2 format=3 uid="uid://d2swjixbnqkbw"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://vji5lp4qc8pp" path="res://scripts/CSharp/Common/Quest/QuestResource.cs" id="1_e51xd"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("1_e51xd")
|
||||
id = "4_collect_tools"
|
||||
title = "Collect the farm tools"
|
||||
description = "Collect the Watering Can next to the well and the Hoe by the fence."
|
||||
metadata/_custom_type_script = "uid://vji5lp4qc8pp"
|
||||
@ -0,0 +1,10 @@
|
||||
[gd_resource type="Resource" script_class="QuestResource" load_steps=2 format=3 uid="uid://5t8g0firdif0"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://vji5lp4qc8pp" path="res://scripts/CSharp/Common/Quest/QuestResource.cs" id="1_x7fvu"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("1_x7fvu")
|
||||
id = "5_talk_yeli_3"
|
||||
title = "Talk to Yeli again"
|
||||
description = "After the long and agonizing task of finding and collecting two tools, go talk to Yeli once again."
|
||||
metadata/_custom_type_script = "uid://vji5lp4qc8pp"
|
||||
@ -0,0 +1,10 @@
|
||||
[gd_resource type="Resource" script_class="QuestResource" load_steps=2 format=3 uid="uid://h05jgxqtq37m"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://vji5lp4qc8pp" path="res://scripts/CSharp/Common/Quest/QuestResource.cs" id="1_745w5"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("1_745w5")
|
||||
id = "6_till_and_water"
|
||||
title = "Till and water the fields"
|
||||
description = "Use the hoe to break up the soil. Then plant the seeds and water the fields."
|
||||
metadata/_custom_type_script = "uid://vji5lp4qc8pp"
|
||||
@ -0,0 +1,10 @@
|
||||
[gd_resource type="Resource" script_class="QuestResource" load_steps=2 format=3 uid="uid://byjqeukpibkvi"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://vji5lp4qc8pp" path="res://scripts/CSharp/Common/Quest/QuestResource.cs" id="1_f2jsb"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("1_f2jsb")
|
||||
id = "7_talk_yeli_inside_1"
|
||||
title = "Talk to Yeli in the house"
|
||||
description = "Go inside the house and find yeli again"
|
||||
metadata/_custom_type_script = "uid://vji5lp4qc8pp"
|
||||
@ -0,0 +1,10 @@
|
||||
[gd_resource type="Resource" script_class="QuestResource" load_steps=2 format=3 uid="uid://csj15gnlx1jmx"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://vji5lp4qc8pp" path="res://scripts/CSharp/Common/Quest/QuestResource.cs" id="1_y6h00"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("1_y6h00")
|
||||
id = "8_goto_bed"
|
||||
title = "Go to sleep"
|
||||
description = "Go into Vesnas room on the left of the house. Go to bed to unexaust you."
|
||||
metadata/_custom_type_script = "uid://vji5lp4qc8pp"
|
||||
@ -0,0 +1,10 @@
|
||||
[gd_resource type="Resource" script_class="QuestResource" load_steps=2 format=3 uid="uid://c3mwhrvk12oml"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://vji5lp4qc8pp" path="res://scripts/CSharp/Common/Quest/QuestResource.cs" id="1_hrrlk"]
|
||||
|
||||
[resource]
|
||||
script = ExtResource("1_hrrlk")
|
||||
id = "9_talk_to_chuga"
|
||||
title = "Talk to Chuga"
|
||||
description = "A strange creature is standing infront of you. Go talk to him. I promise, he won't hurt you... for now."
|
||||
metadata/_custom_type_script = "uid://vji5lp4qc8pp"
|
||||
@ -0,0 +1,74 @@
|
||||
[gd_scene load_steps=5 format=3 uid="uid://baunkb4wwtl32"]
|
||||
|
||||
[ext_resource type="Script" uid="uid://cldtt4atgymm5" path="res://scripts/CSharp/Common/Quest/QuestTrigger.cs" id="1_wnfrg"]
|
||||
[ext_resource type="Resource" uid="uid://0aruj4lm74n6" path="res://resources/quests/test/test_01.tres" id="2_nud5h"]
|
||||
[ext_resource type="Resource" uid="uid://be1dmc6d2mxl5" path="res://resources/quests/test/test_02.tres" id="3_tb5fn"]
|
||||
[ext_resource type="Script" uid="uid://d2486x6upmwqq" path="res://scripts/GdScript/dialogic_starter.gd" id="4_6p0xc"]
|
||||
|
||||
[node name="BabushkaTestsQuestDialogic" type="Node2D"]
|
||||
|
||||
[node name="Button" type="Button" parent="."]
|
||||
offset_left = 105.0
|
||||
offset_top = 47.0
|
||||
offset_right = 423.0
|
||||
offset_bottom = 185.0
|
||||
text = "Start Quest 1"
|
||||
|
||||
[node name="Node" type="Node" parent="Button"]
|
||||
script = ExtResource("1_wnfrg")
|
||||
questResource = ExtResource("2_nud5h")
|
||||
toStatus = 1
|
||||
makeActive = true
|
||||
|
||||
[node name="Button2" type="Button" parent="."]
|
||||
offset_left = 460.0
|
||||
offset_top = 49.0
|
||||
offset_right = 778.0
|
||||
offset_bottom = 187.0
|
||||
text = "End Quest 1"
|
||||
|
||||
[node name="Node" type="Node" parent="Button2"]
|
||||
script = ExtResource("1_wnfrg")
|
||||
questResource = ExtResource("2_nud5h")
|
||||
toStatus = 2
|
||||
|
||||
[node name="Button3" type="Button" parent="."]
|
||||
offset_left = 105.0
|
||||
offset_top = 215.0
|
||||
offset_right = 423.0
|
||||
offset_bottom = 353.0
|
||||
text = "Start Quest 2"
|
||||
|
||||
[node name="Node" type="Node" parent="Button3"]
|
||||
script = ExtResource("1_wnfrg")
|
||||
questResource = ExtResource("3_tb5fn")
|
||||
toStatus = 1
|
||||
makeActive = true
|
||||
|
||||
[node name="Button4" type="Button" parent="."]
|
||||
offset_left = 460.0
|
||||
offset_top = 217.0
|
||||
offset_right = 778.0
|
||||
offset_bottom = 355.0
|
||||
text = "End Quest 2"
|
||||
|
||||
[node name="Node" type="Node" parent="Button4"]
|
||||
script = ExtResource("1_wnfrg")
|
||||
questResource = ExtResource("3_tb5fn")
|
||||
toStatus = 2
|
||||
|
||||
[node name="Button5" type="Button" parent="."]
|
||||
offset_left = 1314.0
|
||||
offset_top = 67.0
|
||||
offset_right = 1632.0
|
||||
offset_bottom = 205.0
|
||||
text = "Start Dialog"
|
||||
|
||||
[node name="Node" type="Node" parent="Button5"]
|
||||
script = ExtResource("4_6p0xc")
|
||||
|
||||
[connection signal="pressed" from="Button" to="Button/Node" method="Trigger"]
|
||||
[connection signal="pressed" from="Button2" to="Button2/Node" method="Trigger"]
|
||||
[connection signal="pressed" from="Button3" to="Button3/Node" method="Trigger"]
|
||||
[connection signal="pressed" from="Button4" to="Button4/Node" method="Trigger"]
|
||||
[connection signal="pressed" from="Button5" to="Button5/Node" method="open" binds= ["test_1"]]
|
||||
@ -1,22 +0,0 @@
|
||||
using Godot;
|
||||
using System;
|
||||
using Babushka.scripts.CSharp.Common.Quest;
|
||||
|
||||
public partial class PopUpPostIt : Control
|
||||
{
|
||||
private Label Text => GetNode<Label>("Text");
|
||||
|
||||
private AnimationPlayer Animation => GetNode<AnimationPlayer>("AnimationPlayer");
|
||||
|
||||
QuestManager QM => QuestManager.Instance!;
|
||||
public override void _EnterTree()
|
||||
{
|
||||
QM.QuestBecomesActive += NewQuestPostIt;
|
||||
}
|
||||
|
||||
private void NewQuestPostIt(QuestResource questResource)
|
||||
{
|
||||
Text.Text = questResource.title;
|
||||
Animation.Play("NewPostit");
|
||||
}
|
||||
}
|
||||
@ -1 +0,0 @@
|
||||
uid://byar6yqrlph6k
|
||||
@ -1,20 +1,22 @@
|
||||
using Godot;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Diagnostics;
|
||||
using Babushka.scripts.CSharp.Common.Quest;
|
||||
using Godot.Collections;
|
||||
|
||||
public partial class QuestTestingScript : Node
|
||||
{
|
||||
[Export(PropertyHint.ArrayType)]
|
||||
private Array<QuestResource> _questsToActivate;
|
||||
private Array<QuestResource>? _questsToMakeAvailable;
|
||||
|
||||
public override void _EnterTree()
|
||||
{
|
||||
foreach (var questResource in _questsToActivate)
|
||||
Debug.Assert(_questsToMakeAvailable != null);
|
||||
|
||||
foreach (var questResource in _questsToMakeAvailable)
|
||||
{
|
||||
QuestManager.Instance.ChangeQuestStatus(questResource, QuestStatus.Status.Active);
|
||||
QuestManager.Instance!.ChangeQuestStatus(questResource, QuestStatus.Status.Available);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@ -0,0 +1,37 @@
|
||||
using Godot;
|
||||
using System;
|
||||
using Babushka.scripts.CSharp.Common.Farming;
|
||||
using Babushka.scripts.CSharp.Common.Quest;
|
||||
|
||||
public partial class DetectFieldWork : QuestFulfillmentBase
|
||||
{
|
||||
private int wateredCounter = 0;
|
||||
|
||||
[Export] private int _wateringNeeded = 5;
|
||||
|
||||
public override void _EnterTree()
|
||||
{
|
||||
WateringCanState.OnWater += CountWater;
|
||||
QuestManager.Instance!.QuestsChanged += CheckFieldWork;
|
||||
}
|
||||
|
||||
public override void _ExitTree()
|
||||
{
|
||||
WateringCanState.OnWater -= CountWater;
|
||||
QuestManager.Instance!.QuestsChanged -= CheckFieldWork;
|
||||
}
|
||||
|
||||
public void CountWater()
|
||||
{
|
||||
wateredCounter++;
|
||||
CheckFieldWork();
|
||||
}
|
||||
|
||||
public void CheckFieldWork()
|
||||
{
|
||||
if (IsQuestActive() && wateredCounter >= _wateringNeeded)
|
||||
{
|
||||
Fulfill();
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -0,0 +1 @@
|
||||
uid://bhbldab74vmhy
|
||||
@ -0,0 +1,33 @@
|
||||
using Godot;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using Babushka.scripts.CSharp.Common.Inventory;
|
||||
using Babushka.scripts.CSharp.Common.Quest;
|
||||
|
||||
public partial class DetectInventoryContains : QuestFulfillmentBase
|
||||
{
|
||||
[Export(PropertyHint.ArrayType)] private ItemInstance[] _itemsToContain = null!;
|
||||
|
||||
public override void _Ready()
|
||||
{
|
||||
QuestManager.Instance!.QuestsChanged += CheckInventory;
|
||||
InventoryManager.Instance.playerInventory.InventoryContentsChanged += CheckInventory;
|
||||
|
||||
CheckInventory();
|
||||
}
|
||||
|
||||
public override void _ExitTree()
|
||||
{
|
||||
QuestManager.Instance!.QuestsChanged -= CheckInventory;
|
||||
InventoryManager.Instance.playerInventory.InventoryContentsChanged -= CheckInventory;
|
||||
}
|
||||
|
||||
private void CheckInventory()
|
||||
{
|
||||
if (IsQuestActive() && InventoryManager.Instance.playerInventory.HasItems(_itemsToContain))
|
||||
{
|
||||
Fulfill();
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -0,0 +1 @@
|
||||
uid://c741nyedy26mx
|
||||
@ -0,0 +1,45 @@
|
|||||||
using Godot;
|
|||||||
using System;
|
|||||||
using System.Linq;
|
|||||||
using Babushka.scripts.CSharp.Common.Quest;
|
|||||||
|
|||||||
/// <summary>
|
|||||||
/// Acts as a base for scripts to check for conditions to complete quests.
|
|||||||
///
|
|||||||
/// The derived Class is responsible for triggering the Check.
|
|||||||
/// It is recommended to always check on QuestManager.Instance!.QuestsChanged
|
|||||||
/// </summary>
|
|||||||
public abstract partial class QuestFulfillmentBase : Node
|
|||||||
{
|
|||||||
[Export] private QuestResource _onAvailableQuest = null!;
|
|||||||
[Export] private QuestResource _toNextQuest = null!;
|
|||||||
|
|||||||
[Export] private bool _whenFulfilledSetAvailableQuestToDone = true;
|
|||||||
[Export] private bool _whenFulfilledSetNextQuestToAvailable = true;
|
|||||||
[Export] private bool _whenFulfilledSetNextQuestToActive = true;
|
|||||||
|
Jonathan marked this conversation as resolved
|
|||||||
|
|||||||
[Signal] private delegate void OnFulfilledEventHandler();
|
|||||||
|
|||||||
protected void Fulfill()
|
|||||||
{
|
|||||||
if (_whenFulfilledSetAvailableQuestToDone)
|
|||||||
{
|
|||||||
QuestManager.Instance!.ChangeQuestStatus(_onAvailableQuest, QuestStatus.Status.Done);
|
|||||||
}
|
|||||||
if (_whenFulfilledSetNextQuestToAvailable)
|
|||||||
{
|
|||||||
QuestManager.Instance!.ChangeQuestStatus(_toNextQuest, QuestStatus.Status.Available);
|
|||||||
}
|
|||||||
if (_whenFulfilledSetNextQuestToActive)
|
|||||||
{
|
|||||||
QuestManager.Instance!.SetActiveQuest(_toNextQuest);
|
|||||||
}
|
|||||||
|
|||||||
EmitSignalOnFulfilled();
|
|||||||
}
|
|||||||
|
|||||||
protected bool IsQuestActive()
|
|||||||
{
|
|||||||
return QuestManager.Instance!.GetAvailableQuests().Any(q => q.Key == _onAvailableQuest);
|
|||||||
}
|
|||||||
}
|
|||||||
@ -0,0 +1 @@
|
||||
uid://dw158xraniqkd
|
||||
@ -0,0 +1,7 @@
|
|||||||
extends Node
|
|||||||
class_name DialogicStartSpecific
|
|||||||
|
Jonathan marked this conversation as resolved
|
|||||||
|
|||||||
@export var timeline : String
|
|||||||
|
|||||||
func open():
|
|||||||
Dialogic.start(timeline)
|
|||||||
@ -0,0 +1 @@
|
||||
uid://dih1b0opgc3f7
|
||||
@ -0,0 +1,4 @@
|
||||
extends Node
|
||||
|
||||
func _SetActiveQuestVar(value:String):
|
||||
Dialogic.VAR.ACTIVEQUEST = value
|
||||
@ -0,0 +1 @@
|
||||
uid://bukwr1h3hn8sx
|
||||
Loading…
Reference in new issue
Wofür genau soll diese Action nachher verwendet werden?
Wenn das signalisieren soll, wenn Vesna sich auf einer Watered-Tile befindet (z.B. für Geh-Sounds), dann würde ich dafür vermutlich eher den Fieldservice verwenden.
Das wird immer aufgerufen, wenn etwas gegossen wird. Das ist ne Quick-and-dirty-Lösung, die von
QuestBehaviour/DetectFieldWork.csgenutzt wird, um Feldarbeit als abgeschlossen zu erkennen.