diff --git a/.editorconfig b/.editorconfig index 0c3315f..9f0c528 100644 --- a/.editorconfig +++ b/.editorconfig @@ -1,185 +1,370 @@ root = true +# ================================ +# All Files +# ================================ + [*] +charset = utf-8 insert_final_newline = true +trim_trailing_whitespace = true indent_style = space indent_size = 4 -trim_trailing_whitespace = true end_of_line = lf -charset = utf-8 -[*.cs] +[*.sln] +indent_style = tab -# New line preferences -csharp_new_line_before_open_brace = all -csharp_new_line_before_else = true -csharp_new_line_before_catch = true -csharp_new_line_before_finally = true -csharp_new_line_before_members_in_object_initializers = true -csharp_new_line_before_members_in_anonymous_types = true -csharp_new_line_between_query_expression_clauses = true +# ================================ +# XML & Config Files +# ================================ -# Indentation preferences -csharp_indent_block_contents = true -csharp_indent_braces = false -csharp_indent_case_contents = true -csharp_indent_case_contents_when_block = false -csharp_indent_switch_labels = true -csharp_indent_labels = one_less_than_current +[*.{csproj,vbproj,vcxproj,vcxproj.filters,proj,projitems,shproj}] +indent_size = 2 -# Modifier preferences -csharp_preferred_modifier_order = public,private,protected,internal,file,static,extern,new,virtual,abstract,sealed,override,readonly,unsafe,required,volatile,async:suggestion -dotnet_style_require_accessibility_modifiers = always:warning +[*.{props,targets,ruleset,config,nuspec,resx,vsixmanifest,vsct}] +indent_size = 2 -# Qualification preferences +# ================================ +# Data Files +# ================================ + +[*.json] +indent_size = 2 + +[*.{yml,yaml}] +indent_size = 2 + +[*.md] +trim_trailing_whitespace = false + +# ================================ +# Scripts +# ================================ + +[*.sh] +end_of_line = lf +indent_size = 2 + +[*.{cmd,bat}] +end_of_line = crlf +indent_size = 2 + +[*.ps1] +indent_size = 2 + +# ================================ +# C# Files +# ================================ + +[*.cs] + +charset = utf-8-bom +insert_final_newline = true +trim_trailing_whitespace = true +indent_style = space +indent_size = 4 + +# Organize usings +dotnet_sort_system_directives_first = true +dotnet_separate_import_directive_groups = false + +# this. and Me. preferences dotnet_style_qualification_for_field = false:suggestion dotnet_style_qualification_for_property = false:suggestion dotnet_style_qualification_for_method = false:suggestion dotnet_style_qualification_for_event = false:suggestion -# Type and Var preferences -csharp_style_var_for_built_in_types = false:suggestion -csharp_style_var_when_type_is_apparent = true:suggestion -csharp_style_var_elsewhere = false:suggestion +# Language keywords vs BCL types dotnet_style_predefined_type_for_locals_parameters_members = true:suggestion dotnet_style_predefined_type_for_member_access = true:suggestion -# Primary constructors -dotnet_diagnostic.IDE0290.severity = none -csharp_style_prefer_primary_constructors = false:none - -# Naming conventions: Constants -dotnet_naming_rule.constant_fields_should_be_pascal_case.severity = suggestion -dotnet_naming_rule.constant_fields_should_be_pascal_case.symbols = constant_fields -dotnet_naming_rule.constant_fields_should_be_pascal_case.style = pascal_case_style -dotnet_naming_symbols.constant_fields.applicable_kinds = field -dotnet_naming_symbols.constant_fields.required_modifiers = const -dotnet_naming_style.pascal_case_style.capitalization = pascal_case +# Parentheses preferences +dotnet_style_parentheses_in_arithmetic_binary_operators = always_for_clarity:silent +dotnet_style_parentheses_in_relational_binary_operators = always_for_clarity:silent +dotnet_style_parentheses_in_other_binary_operators = always_for_clarity:silent +dotnet_style_parentheses_in_other_operators = never_if_unnecessary:silent -# Naming conventions: Static fields -dotnet_naming_rule.static_fields_should_have_prefix.severity = suggestion -dotnet_naming_rule.static_fields_should_have_prefix.symbols = static_fields -dotnet_naming_rule.static_fields_should_have_prefix.style = static_prefix_style -dotnet_naming_symbols.static_fields.applicable_kinds = field -dotnet_naming_symbols.static_fields.required_modifiers = static -dotnet_naming_symbols.static_fields.applicable_accessibilities = private, internal, private_protected -dotnet_naming_style.static_prefix_style.required_prefix = s_ -dotnet_naming_style.static_prefix_style.capitalization = camel_case - -# Naming conventions: Private fields -dotnet_naming_rule.camel_case_for_private_internal_fields.severity = suggestion -dotnet_naming_rule.camel_case_for_private_internal_fields.symbols = private_internal_fields -dotnet_naming_rule.camel_case_for_private_internal_fields.style = camel_case_underscore_style -dotnet_naming_symbols.private_internal_fields.applicable_kinds = field -dotnet_naming_symbols.private_internal_fields.applicable_accessibilities = private, internal -dotnet_naming_style.camel_case_underscore_style.required_prefix = _ -dotnet_naming_style.camel_case_underscore_style.capitalization = camel_case - -# Code style defaults -csharp_style_namespace_declarations = file_scoped:suggestion -csharp_using_directive_placement = outside_namespace:suggestion -dotnet_sort_system_directives_first = true -csharp_prefer_braces = true:silent -csharp_preserve_single_line_blocks = true:none -csharp_preserve_single_line_statements = false:none -csharp_prefer_static_local_function = true:suggestion -csharp_prefer_simple_using_statement = true:suggestion -csharp_style_prefer_switch_expression = true:suggestion +# Modifier preferences +dotnet_style_require_accessibility_modifiers = always:warning dotnet_style_readonly_field = true:suggestion # Expression-level preferences dotnet_style_object_initializer = true:suggestion dotnet_style_collection_initializer = true:suggestion -dotnet_style_prefer_collection_expression = when_types_exactly_match dotnet_style_explicit_tuple_names = true:suggestion -dotnet_style_coalesce_expression = true:suggestion -dotnet_style_null_propagation = true -dotnet_style_prefer_is_null_check_over_reference_equality_method = true:suggestion dotnet_style_prefer_inferred_tuple_names = true:suggestion dotnet_style_prefer_inferred_anonymous_type_member_names = true:suggestion dotnet_style_prefer_auto_properties = false:warning dotnet_style_prefer_conditional_expression_over_assignment = true:silent dotnet_style_prefer_conditional_expression_over_return = true:silent -csharp_prefer_simple_default_expression = true:suggestion -csharp_style_implicit_object_creation_when_type_is_apparent = true:suggestion +dotnet_style_prefer_compound_assignment = true:suggestion +dotnet_style_prefer_simplified_interpolation = true:suggestion +dotnet_style_prefer_simplified_boolean_expressions = true:suggestion +dotnet_style_prefer_collection_expression = false:none + +# Null-checking preferences +dotnet_style_coalesce_expression = true:suggestion +dotnet_style_null_propagation = true:suggestion +dotnet_style_prefer_is_null_check_over_reference_equality_method = true:suggestion + +# Parameter preferences +dotnet_code_quality_unused_parameters = all:suggestion + +# var preferences +csharp_style_var_for_built_in_types = true:suggestion +csharp_style_var_when_type_is_apparent = true:suggestion +csharp_style_var_elsewhere = true:suggestion # Expression-bodied members -csharp_style_expression_bodied_methods = true:silent -csharp_style_expression_bodied_constructors = false:silent -csharp_style_expression_bodied_operators = true:silent -csharp_style_expression_bodied_properties = false:silent -csharp_style_expression_bodied_indexers = true:silent -csharp_style_expression_bodied_accessors = true:silent +csharp_style_expression_bodied_methods = false:none +csharp_style_expression_bodied_constructors = false:none +csharp_style_expression_bodied_operators = false:none +csharp_style_expression_bodied_properties = true:none +csharp_style_expression_bodied_indexers = true:none +csharp_style_expression_bodied_accessors = true:none csharp_style_expression_bodied_lambdas = true:silent csharp_style_expression_bodied_local_functions = true:silent -# Pattern matching +# Pattern matching preferences csharp_style_pattern_matching_over_is_with_cast_check = true:suggestion csharp_style_pattern_matching_over_as_with_null_check = true:suggestion -csharp_style_inlined_variable_declaration = true:suggestion +csharp_style_prefer_not_pattern = true:suggestion +csharp_style_prefer_pattern_matching = true:silent +csharp_style_prefer_extended_property_pattern = true:suggestion +csharp_style_prefer_switch_expression = true:suggestion -# Null checking preferences +# Null-checking preferences csharp_style_throw_expression = true:suggestion csharp_style_conditional_delegate_call = true:suggestion +csharp_style_prefer_null_check_over_type_check = true:suggestion -# Nullable reference types -dotnet_diagnostic.CS8600.severity = suggestion -dotnet_diagnostic.CS8602.severity = suggestion -dotnet_diagnostic.CS8603.severity = suggestion +# Modifier preferences +csharp_prefer_static_local_function = true:suggestion +csharp_preferred_modifier_order = public,private,protected,internal,file,static,extern,new,virtual,abstract,sealed,override,readonly,unsafe,required,volatile,async:suggestion + +# Code-block preferences +csharp_prefer_braces = true:silent +csharp_prefer_simple_using_statement = true:suggestion +csharp_style_namespace_declarations = file_scoped:suggestion +csharp_style_prefer_method_group_conversion = true:silent +csharp_style_prefer_top_level_statements = true:silent +csharp_style_prefer_primary_constructors = false:none -# Other features +# Expression-level preferences +csharp_prefer_simple_default_expression = true:suggestion +csharp_style_prefer_local_over_anonymous_function = true:suggestion csharp_style_prefer_index_operator = true:suggestion csharp_style_prefer_range_operator = true:suggestion +csharp_style_implicit_object_creation_when_type_is_apparent = true:suggestion +csharp_style_prefer_tuple_swap = true:suggestion +csharp_style_prefer_utf8_string_literals = true:suggestion +csharp_style_inlined_variable_declaration = true:suggestion +csharp_style_deconstructed_variable_declaration = true:suggestion +csharp_style_unused_value_assignment_preference = discard_variable:suggestion +csharp_style_unused_value_expression_statement_preference = discard_variable:silent + +# using directive preferences +csharp_using_directive_placement = outside_namespace:suggestion + +# Other preferences csharp_style_pattern_local_over_anonymous_function = false:none -# Diagnostic suppressions -dotnet_diagnostic.IDE0071.severity = silent -dotnet_diagnostic.IDE0031.severity = silent +# New line preferences +csharp_new_line_before_open_brace = all +csharp_new_line_before_else = true +csharp_new_line_before_catch = true +csharp_new_line_before_finally = true +csharp_new_line_before_members_in_object_initializers = true +csharp_new_line_before_members_in_anonymous_types = true +csharp_new_line_between_query_expression_clauses = true -# XML documentation warnings -dotnet_diagnostic.CS1591.severity = none -dotnet_diagnostic.CS1573.severity = none -dotnet_diagnostic.CS1572.severity = none -dotnet_diagnostic.CS1571.severity = none -dotnet_diagnostic.CS1570.severity = none -dotnet_diagnostic.CS1587.severity = none -dotnet_diagnostic.CS1574.severity = none -dotnet_diagnostic.CS1580.severity = none -dotnet_diagnostic.CS1584.severity = none -dotnet_diagnostic.CS1658.severity = none +# Indentation preferences +csharp_indent_case_contents = true +csharp_indent_switch_labels = true +csharp_indent_labels = one_less_than_current +csharp_indent_block_contents = true +csharp_indent_braces = false +csharp_indent_case_contents_when_block = false # Space preferences csharp_space_after_cast = false +csharp_space_after_keywords_in_control_flow_statements = true +csharp_space_between_parentheses = false +csharp_space_before_colon_in_inheritance_clause = true csharp_space_after_colon_in_inheritance_clause = true +csharp_space_around_binary_operators = before_and_after +csharp_space_between_method_declaration_parameter_list_parentheses = false +csharp_space_between_method_declaration_empty_parameter_list_parentheses = false +csharp_space_between_method_declaration_name_and_open_parenthesis = false +csharp_space_between_method_call_parameter_list_parentheses = false +csharp_space_between_method_call_empty_parameter_list_parentheses = false +csharp_space_between_method_call_name_and_opening_parenthesis = false csharp_space_after_comma = true csharp_space_after_dot = false -csharp_space_after_keywords_in_control_flow_statements = true csharp_space_after_semicolon_in_for_statement = true -csharp_space_around_binary_operators = before_and_after -csharp_space_around_declaration_statements = do_not_ignore -csharp_space_before_colon_in_inheritance_clause = true csharp_space_before_comma = false csharp_space_before_dot = false -csharp_space_before_open_square_brackets = false csharp_space_before_semicolon_in_for_statement = false +csharp_space_before_open_square_brackets = false csharp_space_between_empty_square_brackets = false -csharp_space_between_method_call_empty_parameter_list_parentheses = false -csharp_space_between_method_call_name_and_opening_parenthesis = false -csharp_space_between_method_call_parameter_list_parentheses = false -csharp_space_between_method_declaration_empty_parameter_list_parentheses = false -csharp_space_between_method_declaration_name_and_open_parenthesis = false -csharp_space_between_method_declaration_parameter_list_parentheses = false -csharp_space_between_parentheses = false csharp_space_between_square_brackets = false +csharp_space_around_declaration_statements = do_not_ignore -[*.{json,yaml,yml}] -indent_size = 2 +# Wrapping preferences +csharp_preserve_single_line_statements = true +csharp_preserve_single_line_blocks = true -[*.{csproj,xml,props,targets,resx}] -indent_size = 2 +# Whitespace options +csharp_style_allow_embedded_statements_on_same_line_experimental = false +csharp_style_allow_blank_lines_between_consecutive_braces_experimental = false +csharp_style_allow_blank_line_after_colon_in_constructor_initializer_experimental = false +csharp_style_allow_blank_line_after_token_in_conditional_expression_experimental = false +csharp_style_allow_blank_line_after_token_in_arrow_expression_clause_experimental = false +dotnet_style_allow_multiple_blank_lines_experimental = false +dotnet_style_allow_statement_immediately_after_block_experimental = false -[*.sh] -end_of_line = lf +# Naming: Interfaces +dotnet_naming_rule.interface_should_be_begins_with_i.severity = suggestion +dotnet_naming_rule.interface_should_be_begins_with_i.symbols = interface +dotnet_naming_rule.interface_should_be_begins_with_i.style = begins_with_i -[*.{cmd,bat}] -end_of_line = crlf +dotnet_naming_symbols.interface.applicable_kinds = interface +dotnet_naming_symbols.interface.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected +dotnet_naming_symbols.interface.required_modifiers = + +dotnet_naming_style.begins_with_i.required_prefix = I +dotnet_naming_style.begins_with_i.required_suffix = +dotnet_naming_style.begins_with_i.word_separator = +dotnet_naming_style.begins_with_i.capitalization = pascal_case + +# Naming: Types +dotnet_naming_rule.types_should_be_pascal_case.severity = suggestion +dotnet_naming_rule.types_should_be_pascal_case.symbols = types +dotnet_naming_rule.types_should_be_pascal_case.style = pascal_case + +dotnet_naming_symbols.types.applicable_kinds = class, struct, interface, enum +dotnet_naming_symbols.types.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected +dotnet_naming_symbols.types.required_modifiers = + +# Naming: Non-field members +dotnet_naming_rule.non_field_members_should_be_pascal_case.severity = suggestion +dotnet_naming_rule.non_field_members_should_be_pascal_case.symbols = non_field_members +dotnet_naming_rule.non_field_members_should_be_pascal_case.style = pascal_case + +dotnet_naming_symbols.non_field_members.applicable_kinds = property, event, method +dotnet_naming_symbols.non_field_members.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected +dotnet_naming_symbols.non_field_members.required_modifiers = + +dotnet_naming_style.pascal_case.required_prefix = +dotnet_naming_style.pascal_case.required_suffix = +dotnet_naming_style.pascal_case.word_separator = +dotnet_naming_style.pascal_case.capitalization = pascal_case + +# Naming: Non-private static fields +dotnet_naming_rule.non_private_static_fields_should_be_pascal_case.severity = suggestion +dotnet_naming_rule.non_private_static_fields_should_be_pascal_case.symbols = non_private_static_fields +dotnet_naming_rule.non_private_static_fields_should_be_pascal_case.style = non_private_static_field_style + +dotnet_naming_symbols.non_private_static_fields.applicable_kinds = field +dotnet_naming_symbols.non_private_static_fields.applicable_accessibilities = public, protected, internal, protected_internal, private_protected +dotnet_naming_symbols.non_private_static_fields.required_modifiers = static + +dotnet_naming_style.non_private_static_field_style.capitalization = pascal_case + +# Naming: Non-private readonly fields +dotnet_naming_rule.non_private_readonly_fields_should_be_pascal_case.severity = suggestion +dotnet_naming_rule.non_private_readonly_fields_should_be_pascal_case.symbols = non_private_readonly_fields +dotnet_naming_rule.non_private_readonly_fields_should_be_pascal_case.style = non_private_readonly_field_style + +dotnet_naming_symbols.non_private_readonly_fields.applicable_kinds = field +dotnet_naming_symbols.non_private_readonly_fields.applicable_accessibilities = public, protected, internal, protected_internal, private_protected +dotnet_naming_symbols.non_private_readonly_fields.required_modifiers = readonly + +dotnet_naming_style.non_private_readonly_field_style.capitalization = pascal_case + +# Naming: Constants +dotnet_naming_rule.constants_should_be_pascal_case.severity = suggestion +dotnet_naming_rule.constants_should_be_pascal_case.symbols = constants +dotnet_naming_rule.constants_should_be_pascal_case.style = pascal_case_style + +dotnet_naming_symbols.constants.applicable_kinds = field, local +dotnet_naming_symbols.constants.required_modifiers = const + +dotnet_naming_style.pascal_case_style.capitalization = pascal_case + +# Naming: Private static fields +dotnet_naming_rule.static_fields_should_be_camel_case.severity = suggestion +dotnet_naming_rule.static_fields_should_be_camel_case.symbols = static_fields +dotnet_naming_rule.static_fields_should_be_camel_case.style = static_field_style + +dotnet_naming_symbols.static_fields.applicable_kinds = field +dotnet_naming_symbols.static_fields.applicable_accessibilities = private, internal, private_protected +dotnet_naming_symbols.static_fields.required_modifiers = static + +dotnet_naming_style.static_field_style.capitalization = camel_case +dotnet_naming_style.static_field_style.required_prefix = s_ + +# Naming: Private instance fields +dotnet_naming_rule.instance_fields_should_be_camel_case.severity = suggestion +dotnet_naming_rule.instance_fields_should_be_camel_case.symbols = instance_fields +dotnet_naming_rule.instance_fields_should_be_camel_case.style = instance_field_style + +dotnet_naming_symbols.instance_fields.applicable_kinds = field +dotnet_naming_symbols.instance_fields.applicable_accessibilities = private, internal, private_protected + +dotnet_naming_style.instance_field_style.capitalization = camel_case +dotnet_naming_style.instance_field_style.required_prefix = _ + +# Naming: Locals and parameters +dotnet_naming_rule.locals_should_be_camel_case.severity = suggestion +dotnet_naming_rule.locals_should_be_camel_case.symbols = locals_and_parameters +dotnet_naming_rule.locals_should_be_camel_case.style = camel_case_style + +dotnet_naming_symbols.locals_and_parameters.applicable_kinds = parameter, local + +dotnet_naming_style.camel_case_style.capitalization = camel_case + +# Naming: Local functions +dotnet_naming_rule.local_functions_should_be_pascal_case.severity = suggestion +dotnet_naming_rule.local_functions_should_be_pascal_case.symbols = local_functions +dotnet_naming_rule.local_functions_should_be_pascal_case.style = pascal_case_style + +dotnet_naming_symbols.local_functions.applicable_kinds = local_function + +# Primary constructors +dotnet_diagnostic.IDE0290.severity = none + +# Namespace matching +dotnet_diagnostic.IDE0130.severity = none + +# Nullable reference types +dotnet_diagnostic.CS8600.severity = warning +dotnet_diagnostic.CS8602.severity = warning +dotnet_diagnostic.CS8603.severity = warning +dotnet_diagnostic.CS8618.severity = warning +dotnet_diagnostic.CS8625.severity = warning + +# XML documentation +dotnet_diagnostic.CS1591.severity = none +dotnet_diagnostic.CS1573.severity = none +dotnet_diagnostic.CS1572.severity = none +dotnet_diagnostic.CS1571.severity = none +dotnet_diagnostic.CS1570.severity = none +dotnet_diagnostic.CS1587.severity = none +dotnet_diagnostic.CS1574.severity = none +dotnet_diagnostic.CS1580.severity = none +dotnet_diagnostic.CS1584.severity = none +dotnet_diagnostic.CS1658.severity = none + +# Code quality +dotnet_diagnostic.CA1822.severity = suggestion +dotnet_diagnostic.IDE0011.severity = warning +dotnet_diagnostic.IDE0040.severity = warning +dotnet_diagnostic.IDE0051.severity = warning +dotnet_diagnostic.IDE0052.severity = warning +dotnet_diagnostic.IDE0055.severity = warning + +# Suppressions +dotnet_diagnostic.IDE0071.severity = silent +dotnet_diagnostic.IDE0031.severity = silent diff --git a/.gitattributes b/.gitattributes index 3a60d1c..0d01b48 100644 --- a/.gitattributes +++ b/.gitattributes @@ -1,81 +1,59 @@ -* text=auto +* text=auto eol=lf -# Documents -*.bibtex text diff=bibtex -*.doc diff=astextplain -*.DOC diff=astextplain -*.docx diff=astextplain -*.DOCX diff=astextplain -*.dot diff=astextplain -*.DOT diff=astextplain -*.pdf diff=astextplain -*.PDF diff=astextplain -*.rtf diff=astextplain -*.RTF diff=astextplain +# .NET source files +*.cs text diff=csharp +*.csx text diff=csharp +*.cshtml text diff=html + +# .NET project files +*.sln text +*.slnx text +*.csproj text +*.props text +*.targets text + +# Configuration files +*.json text +*.xml text +*.config text +*.yml text +*.yaml text + +# Documentation *.md text diff=markdown -*.mdx text diff=markdown -*.tex text diff=tex -*.adoc text -*.textile text -*.mustache text -*.csv text eol=crlf -*.tab text -*.tsv text *.txt text -*.sql text -*.epub diff=astextplain -# Graphics +# Scripts +*.ps1 text eol=crlf +*.cmd text eol=crlf +*.bat text eol=crlf +*.sh text eol=lf + +# Images *.png binary *.jpg binary *.jpeg binary *.gif binary -*.tif binary -*.tiff binary *.ico binary *.svg text -*.eps binary - -# Scripts -*.bash text eol=lf -*.fish text eol=lf -*.sh text eol=lf -*.zsh text eol=lf -*.bat text eol=crlf -*.cmd text eol=crlf -*.ps1 text eol=crlf - -# Serialisation -*.json text -*.toml text -*.xml text -*.yaml text -*.yml text # Archives -*.7z binary -*.gz binary -*.tar binary -*.tgz binary *.zip binary +*.nupkg binary +*.snupkg binary -# Text files where line endings should be preserved -*.patch -text - -# Dotnet files -*.cs text diff=csharp -*.cshtml text diff=html -*.csx text diff=csharp -*.sln text eol=crlf -*.csproj text eol=crlf +# Executables +*.dll binary +*.exe binary +*.pdb binary +*.so binary -# Apply override to all files in the directory +# Apply markdown detection *.md linguist-detectable -# Fix syntax highlighting on GitHub to allow comments +# VS Code JSON with comments .vscode/*.json linguist-language=JSON-with-Comments -# Exclude files from exporting +# Exclude from exports .gitattributes export-ignore .gitignore export-ignore -.gitkeep export-ignore \ No newline at end of file diff --git a/Icon.png b/Icon.png index ecbc41a..3869ccd 100644 Binary files a/Icon.png and b/Icon.png differ diff --git a/global.json b/global.json index 611d1b4..dc92f2e 100644 --- a/global.json +++ b/global.json @@ -3,4 +3,4 @@ "rollForward": "major", "version": "10.0.100" } -} +} \ No newline at end of file diff --git a/sandbox/UnityApplication/.editorconfig b/sandbox/UnityApplication/.editorconfig index 86c71fc..87eaf5c 100644 --- a/sandbox/UnityApplication/.editorconfig +++ b/sandbox/UnityApplication/.editorconfig @@ -1,188 +1,397 @@ root = true +# ================================ +# All Files +# ================================ + [*] +charset = utf-8 insert_final_newline = true +trim_trailing_whitespace = true indent_style = space indent_size = 4 -trim_trailing_whitespace = true end_of_line = lf -charset = utf-8 -[*.cs] +[*.sln] +indent_style = tab -# New line preferences -csharp_new_line_before_open_brace = all -csharp_new_line_before_else = true -csharp_new_line_before_catch = true -csharp_new_line_before_finally = true -csharp_new_line_before_members_in_object_initializers = true -csharp_new_line_before_members_in_anonymous_types = true -csharp_new_line_between_query_expression_clauses = true +# ================================ +# Asset Files +# ================================ -# Indentation preferences -csharp_indent_block_contents = true -csharp_indent_braces = false -csharp_indent_case_contents = true -csharp_indent_case_contents_when_block = false -csharp_indent_switch_labels = true -csharp_indent_labels = one_less_than_current +[*.{asset,prefab,unity,mat,controller,anim,physicMaterial,physicsMaterial2D,mask,overrideController,playable}] +indent_size = 2 -# Modifier preferences -csharp_preferred_modifier_order = public,private,protected,internal,file,static,extern,new,virtual,abstract,sealed,override,readonly,unsafe,required,volatile,async:suggestion -dotnet_style_require_accessibility_modifiers = always:warning +[*.{meta,asmdef,asmref}] +indent_size = 2 + +# ================================ +# XML & Config Files +# ================================ + +[*.{csproj,vbproj,vcxproj,vcxproj.filters,proj,projitems,shproj}] +indent_size = 2 + +[*.{props,targets,ruleset,config,nuspec,resx,vsixmanifest,vsct}] +indent_size = 2 + +# ================================ +# Data Files +# ================================ + +[*.json] +indent_size = 2 + +[*.{yml,yaml}] +indent_size = 2 + +[*.md] +trim_trailing_whitespace = false + +# ================================ +# Shader Files +# ================================ + +[*.{shader,shadergraph,shadersubgraph,hlsl,cginc,compute}] +indent_size = 4 + +[*.uss] +indent_size = 2 + +[*.uxml] +indent_size = 2 + +# ================================ +# Scripts +# ================================ + +[*.sh] +end_of_line = lf +indent_size = 2 + +[*.{cmd,bat}] +end_of_line = crlf +indent_size = 2 + +[*.ps1] +indent_size = 2 -# Qualification preferences +# ================================ +# C# Files +# ================================ + +[*.cs] + +charset = utf-8-bom +insert_final_newline = true +trim_trailing_whitespace = true +indent_style = space +indent_size = 4 + +# Organize usings +dotnet_sort_system_directives_first = true +dotnet_separate_import_directive_groups = false + +# this. and Me. preferences dotnet_style_qualification_for_field = false:suggestion dotnet_style_qualification_for_property = false:suggestion dotnet_style_qualification_for_method = false:suggestion dotnet_style_qualification_for_event = false:suggestion -# Type and Var preferences -csharp_style_var_for_built_in_types = false:suggestion -csharp_style_var_when_type_is_apparent = true:suggestion -csharp_style_var_elsewhere = false:suggestion +# Language keywords vs BCL types dotnet_style_predefined_type_for_locals_parameters_members = true:suggestion dotnet_style_predefined_type_for_member_access = true:suggestion -# Primary constructors -dotnet_diagnostic.IDE0290.severity = none -csharp_style_prefer_primary_constructors = false:none +# Parentheses preferences +dotnet_style_parentheses_in_arithmetic_binary_operators = always_for_clarity:silent +dotnet_style_parentheses_in_relational_binary_operators = always_for_clarity:silent +dotnet_style_parentheses_in_other_binary_operators = always_for_clarity:silent +dotnet_style_parentheses_in_other_operators = never_if_unnecessary:silent -# Naming conventions: Constants -dotnet_naming_rule.constant_fields_should_be_pascal_case.severity = suggestion -dotnet_naming_rule.constant_fields_should_be_pascal_case.symbols = constant_fields -dotnet_naming_rule.constant_fields_should_be_pascal_case.style = pascal_case_style -dotnet_naming_symbols.constant_fields.applicable_kinds = field -dotnet_naming_symbols.constant_fields.required_modifiers = const -dotnet_naming_style.pascal_case_style.capitalization = pascal_case - -# Naming conventions: Static fields -dotnet_naming_rule.static_fields_should_have_prefix.severity = suggestion -dotnet_naming_rule.static_fields_should_have_prefix.symbols = static_fields -dotnet_naming_rule.static_fields_should_have_prefix.style = static_prefix_style -dotnet_naming_symbols.static_fields.applicable_kinds = field -dotnet_naming_symbols.static_fields.required_modifiers = static -dotnet_naming_symbols.static_fields.applicable_accessibilities = private, internal, private_protected -dotnet_naming_style.static_prefix_style.required_prefix = s_ -dotnet_naming_style.static_prefix_style.capitalization = camel_case - -# Naming conventions: Private fields -dotnet_naming_rule.camel_case_for_private_internal_fields.severity = suggestion -dotnet_naming_rule.camel_case_for_private_internal_fields.symbols = private_internal_fields -dotnet_naming_rule.camel_case_for_private_internal_fields.style = camel_case_underscore_style -dotnet_naming_symbols.private_internal_fields.applicable_kinds = field -dotnet_naming_symbols.private_internal_fields.applicable_accessibilities = private, internal -dotnet_naming_style.camel_case_underscore_style.required_prefix = _ -dotnet_naming_style.camel_case_underscore_style.capitalization = camel_case - -# Code style defaults -csharp_style_namespace_declarations = file_scoped:suggestion -csharp_using_directive_placement = outside_namespace:suggestion -dotnet_sort_system_directives_first = true -csharp_prefer_braces = true:silent -csharp_preserve_single_line_blocks = true:none -csharp_preserve_single_line_statements = false:none -csharp_prefer_static_local_function = true:suggestion -csharp_prefer_simple_using_statement = true:suggestion -csharp_style_prefer_switch_expression = true:suggestion +# Modifier preferences +dotnet_style_require_accessibility_modifiers = always:warning dotnet_style_readonly_field = true:suggestion # Expression-level preferences dotnet_style_object_initializer = true:suggestion dotnet_style_collection_initializer = true:suggestion -dotnet_style_prefer_collection_expression = false:none dotnet_style_explicit_tuple_names = true:suggestion -dotnet_style_coalesce_expression = true:suggestion -dotnet_style_null_propagation = true -dotnet_style_prefer_is_null_check_over_reference_equality_method = true:suggestion dotnet_style_prefer_inferred_tuple_names = true:suggestion dotnet_style_prefer_inferred_anonymous_type_member_names = true:suggestion dotnet_style_prefer_auto_properties = false:warning dotnet_style_prefer_conditional_expression_over_assignment = true:silent dotnet_style_prefer_conditional_expression_over_return = true:silent -csharp_prefer_simple_default_expression = true:suggestion -csharp_style_implicit_object_creation_when_type_is_apparent = true:suggestion +dotnet_style_prefer_compound_assignment = true:suggestion +dotnet_style_prefer_simplified_interpolation = true:suggestion +dotnet_style_prefer_simplified_boolean_expressions = true:suggestion +dotnet_style_prefer_collection_expression = false:none + +# Null-checking preferences +dotnet_style_coalesce_expression = true:suggestion +dotnet_style_null_propagation = true:suggestion +dotnet_style_prefer_is_null_check_over_reference_equality_method = true:suggestion + +# Parameter preferences +dotnet_code_quality_unused_parameters = all:suggestion + +# var preferences +csharp_style_var_for_built_in_types = true:suggestion +csharp_style_var_when_type_is_apparent = true:suggestion +csharp_style_var_elsewhere = true:suggestion # Expression-bodied members -csharp_style_expression_bodied_methods = true:silent -csharp_style_expression_bodied_constructors = false:silent -csharp_style_expression_bodied_operators = true:silent -csharp_style_expression_bodied_properties = false:silent -csharp_style_expression_bodied_indexers = true:silent -csharp_style_expression_bodied_accessors = true:silent +csharp_style_expression_bodied_methods = false:none +csharp_style_expression_bodied_constructors = false:none +csharp_style_expression_bodied_operators = false:none +csharp_style_expression_bodied_properties = true:none +csharp_style_expression_bodied_indexers = true:none +csharp_style_expression_bodied_accessors = true:none csharp_style_expression_bodied_lambdas = true:silent csharp_style_expression_bodied_local_functions = true:silent -# Pattern matching +# Pattern matching preferences csharp_style_pattern_matching_over_is_with_cast_check = true:suggestion csharp_style_pattern_matching_over_as_with_null_check = true:suggestion -csharp_style_inlined_variable_declaration = true:suggestion +csharp_style_prefer_not_pattern = true:suggestion +csharp_style_prefer_pattern_matching = true:silent +csharp_style_prefer_extended_property_pattern = true:suggestion +csharp_style_prefer_switch_expression = true:suggestion -# Null checking preferences +# Null-checking preferences csharp_style_throw_expression = true:suggestion csharp_style_conditional_delegate_call = true:suggestion +csharp_style_prefer_null_check_over_type_check = true:suggestion -# Nullable reference types -dotnet_diagnostic.CS8600.severity = suggestion -dotnet_diagnostic.CS8602.severity = suggestion -dotnet_diagnostic.CS8603.severity = suggestion +# Modifier preferences +csharp_prefer_static_local_function = true:suggestion +csharp_preferred_modifier_order = public,private,protected,internal,file,static,extern,new,virtual,abstract,sealed,override,readonly,unsafe,required,volatile,async:suggestion + +# Code-block preferences +csharp_prefer_braces = true:silent +csharp_prefer_simple_using_statement = true:suggestion +csharp_style_namespace_declarations = block_scoped:error +csharp_style_prefer_method_group_conversion = true:silent +csharp_style_prefer_top_level_statements = false:error +csharp_style_prefer_primary_constructors = false:none -# Other features +# Expression-level preferences +csharp_prefer_simple_default_expression = true:suggestion +csharp_style_prefer_local_over_anonymous_function = true:suggestion csharp_style_prefer_index_operator = true:suggestion csharp_style_prefer_range_operator = true:suggestion +csharp_style_implicit_object_creation_when_type_is_apparent = true:suggestion +csharp_style_prefer_tuple_swap = true:suggestion +csharp_style_prefer_utf8_string_literals = false:none +csharp_style_inlined_variable_declaration = true:suggestion +csharp_style_deconstructed_variable_declaration = true:suggestion +csharp_style_unused_value_assignment_preference = discard_variable:suggestion +csharp_style_unused_value_expression_statement_preference = discard_variable:silent + +# using directive preferences +csharp_using_directive_placement = outside_namespace:suggestion + +# Other preferences csharp_style_pattern_local_over_anonymous_function = false:none -# Diagnostic suppressions -dotnet_diagnostic.IDE0071.severity = silent -dotnet_diagnostic.IDE0031.severity = silent +# New line preferences +csharp_new_line_before_open_brace = all +csharp_new_line_before_else = true +csharp_new_line_before_catch = true +csharp_new_line_before_finally = true +csharp_new_line_before_members_in_object_initializers = true +csharp_new_line_before_members_in_anonymous_types = true +csharp_new_line_between_query_expression_clauses = true -# XML documentation warnings -dotnet_diagnostic.CS1591.severity = none -dotnet_diagnostic.CS1573.severity = none -dotnet_diagnostic.CS1572.severity = none -dotnet_diagnostic.CS1571.severity = none -dotnet_diagnostic.CS1570.severity = none -dotnet_diagnostic.CS1587.severity = none -dotnet_diagnostic.CS1574.severity = none -dotnet_diagnostic.CS1580.severity = none -dotnet_diagnostic.CS1584.severity = none -dotnet_diagnostic.CS1658.severity = none +# Indentation preferences +csharp_indent_case_contents = true +csharp_indent_switch_labels = true +csharp_indent_labels = one_less_than_current +csharp_indent_block_contents = true +csharp_indent_braces = false +csharp_indent_case_contents_when_block = false # Space preferences csharp_space_after_cast = false +csharp_space_after_keywords_in_control_flow_statements = true +csharp_space_between_parentheses = false +csharp_space_before_colon_in_inheritance_clause = true csharp_space_after_colon_in_inheritance_clause = true +csharp_space_around_binary_operators = before_and_after +csharp_space_between_method_declaration_parameter_list_parentheses = false +csharp_space_between_method_declaration_empty_parameter_list_parentheses = false +csharp_space_between_method_declaration_name_and_open_parenthesis = false +csharp_space_between_method_call_parameter_list_parentheses = false +csharp_space_between_method_call_empty_parameter_list_parentheses = false +csharp_space_between_method_call_name_and_opening_parenthesis = false csharp_space_after_comma = true csharp_space_after_dot = false -csharp_space_after_keywords_in_control_flow_statements = true csharp_space_after_semicolon_in_for_statement = true -csharp_space_around_binary_operators = before_and_after -csharp_space_around_declaration_statements = do_not_ignore -csharp_space_before_colon_in_inheritance_clause = true csharp_space_before_comma = false csharp_space_before_dot = false -csharp_space_before_open_square_brackets = false csharp_space_before_semicolon_in_for_statement = false +csharp_space_before_open_square_brackets = false csharp_space_between_empty_square_brackets = false -csharp_space_between_method_call_empty_parameter_list_parentheses = false -csharp_space_between_method_call_name_and_opening_parenthesis = false -csharp_space_between_method_call_parameter_list_parentheses = false -csharp_space_between_method_declaration_empty_parameter_list_parentheses = false -csharp_space_between_method_declaration_name_and_open_parenthesis = false -csharp_space_between_method_declaration_parameter_list_parentheses = false -csharp_space_between_parentheses = false csharp_space_between_square_brackets = false +csharp_space_around_declaration_statements = do_not_ignore -[*.{json,yaml,yml}] -indent_size = 2 +# Wrapping preferences +csharp_preserve_single_line_statements = true +csharp_preserve_single_line_blocks = true -[*.{csproj,xml,props,targets,resx}] -indent_size = 2 +# Whitespace options +csharp_style_allow_embedded_statements_on_same_line_experimental = false +csharp_style_allow_blank_lines_between_consecutive_braces_experimental = false +csharp_style_allow_blank_line_after_colon_in_constructor_initializer_experimental = false +csharp_style_allow_blank_line_after_token_in_conditional_expression_experimental = false +csharp_style_allow_blank_line_after_token_in_arrow_expression_clause_experimental = false +dotnet_style_allow_multiple_blank_lines_experimental = false +dotnet_style_allow_statement_immediately_after_block_experimental = false -[*.{asmdef,asmref,meta}] -indent_size = 2 +# Naming: Interfaces +dotnet_naming_rule.interface_should_be_begins_with_i.severity = suggestion +dotnet_naming_rule.interface_should_be_begins_with_i.symbols = interface +dotnet_naming_rule.interface_should_be_begins_with_i.style = begins_with_i -[*.sh] -end_of_line = lf +dotnet_naming_symbols.interface.applicable_kinds = interface +dotnet_naming_symbols.interface.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected +dotnet_naming_symbols.interface.required_modifiers = -[*.{cmd,bat}] -end_of_line = crlf +dotnet_naming_style.begins_with_i.required_prefix = I +dotnet_naming_style.begins_with_i.required_suffix = +dotnet_naming_style.begins_with_i.word_separator = +dotnet_naming_style.begins_with_i.capitalization = pascal_case + +# Naming: Types +dotnet_naming_rule.types_should_be_pascal_case.severity = suggestion +dotnet_naming_rule.types_should_be_pascal_case.symbols = types +dotnet_naming_rule.types_should_be_pascal_case.style = pascal_case + +dotnet_naming_symbols.types.applicable_kinds = class, struct, interface, enum +dotnet_naming_symbols.types.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected +dotnet_naming_symbols.types.required_modifiers = + +# Naming: Non-field members +dotnet_naming_rule.non_field_members_should_be_pascal_case.severity = suggestion +dotnet_naming_rule.non_field_members_should_be_pascal_case.symbols = non_field_members +dotnet_naming_rule.non_field_members_should_be_pascal_case.style = pascal_case + +dotnet_naming_symbols.non_field_members.applicable_kinds = property, event, method +dotnet_naming_symbols.non_field_members.applicable_accessibilities = public, internal, private, protected, protected_internal, private_protected +dotnet_naming_symbols.non_field_members.required_modifiers = + +dotnet_naming_style.pascal_case.required_prefix = +dotnet_naming_style.pascal_case.required_suffix = +dotnet_naming_style.pascal_case.word_separator = +dotnet_naming_style.pascal_case.capitalization = pascal_case + +# Naming: Non-private static fields +dotnet_naming_rule.non_private_static_fields_should_be_pascal_case.severity = suggestion +dotnet_naming_rule.non_private_static_fields_should_be_pascal_case.symbols = non_private_static_fields +dotnet_naming_rule.non_private_static_fields_should_be_pascal_case.style = non_private_static_field_style + +dotnet_naming_symbols.non_private_static_fields.applicable_kinds = field +dotnet_naming_symbols.non_private_static_fields.applicable_accessibilities = public, protected, internal, protected_internal, private_protected +dotnet_naming_symbols.non_private_static_fields.required_modifiers = static + +dotnet_naming_style.non_private_static_field_style.capitalization = pascal_case + +# Naming: Non-private readonly fields +dotnet_naming_rule.non_private_readonly_fields_should_be_pascal_case.severity = suggestion +dotnet_naming_rule.non_private_readonly_fields_should_be_pascal_case.symbols = non_private_readonly_fields +dotnet_naming_rule.non_private_readonly_fields_should_be_pascal_case.style = non_private_readonly_field_style + +dotnet_naming_symbols.non_private_readonly_fields.applicable_kinds = field +dotnet_naming_symbols.non_private_readonly_fields.applicable_accessibilities = public, protected, internal, protected_internal, private_protected +dotnet_naming_symbols.non_private_readonly_fields.required_modifiers = readonly + +dotnet_naming_style.non_private_readonly_field_style.capitalization = pascal_case + +# Naming: Constants +dotnet_naming_rule.constants_should_be_pascal_case.severity = suggestion +dotnet_naming_rule.constants_should_be_pascal_case.symbols = constants +dotnet_naming_rule.constants_should_be_pascal_case.style = pascal_case_style + +dotnet_naming_symbols.constants.applicable_kinds = field, local +dotnet_naming_symbols.constants.required_modifiers = const + +dotnet_naming_style.pascal_case_style.capitalization = pascal_case + +# Naming: Private static fields +dotnet_naming_rule.static_fields_should_be_camel_case.severity = suggestion +dotnet_naming_rule.static_fields_should_be_camel_case.symbols = static_fields +dotnet_naming_rule.static_fields_should_be_camel_case.style = static_field_style + +dotnet_naming_symbols.static_fields.applicable_kinds = field +dotnet_naming_symbols.static_fields.applicable_accessibilities = private, internal, private_protected +dotnet_naming_symbols.static_fields.required_modifiers = static + +dotnet_naming_style.static_field_style.capitalization = camel_case +dotnet_naming_style.static_field_style.required_prefix = s_ + +# Naming: Private instance fields +dotnet_naming_rule.instance_fields_should_be_camel_case.severity = suggestion +dotnet_naming_rule.instance_fields_should_be_camel_case.symbols = instance_fields +dotnet_naming_rule.instance_fields_should_be_camel_case.style = instance_field_style + +dotnet_naming_symbols.instance_fields.applicable_kinds = field +dotnet_naming_symbols.instance_fields.applicable_accessibilities = private, internal, private_protected + +dotnet_naming_style.instance_field_style.capitalization = camel_case +dotnet_naming_style.instance_field_style.required_prefix = _ + +# Naming: Locals and parameters +dotnet_naming_rule.locals_should_be_camel_case.severity = suggestion +dotnet_naming_rule.locals_should_be_camel_case.symbols = locals_and_parameters +dotnet_naming_rule.locals_should_be_camel_case.style = camel_case_style + +dotnet_naming_symbols.locals_and_parameters.applicable_kinds = parameter, local + +dotnet_naming_style.camel_case_style.capitalization = camel_case + +# Naming: Local functions +dotnet_naming_rule.local_functions_should_be_pascal_case.severity = suggestion +dotnet_naming_rule.local_functions_should_be_pascal_case.symbols = local_functions +dotnet_naming_rule.local_functions_should_be_pascal_case.style = pascal_case_style + +dotnet_naming_symbols.local_functions.applicable_kinds = local_function + +# Primary constructors +dotnet_diagnostic.IDE0290.severity = none + +# Namespace matching +dotnet_diagnostic.IDE0130.severity = none + +# Nullable reference types +dotnet_diagnostic.CS8600.severity = warning +dotnet_diagnostic.CS8602.severity = warning +dotnet_diagnostic.CS8603.severity = warning +dotnet_diagnostic.CS8618.severity = silent +dotnet_diagnostic.CS8625.severity = warning + +# XML documentation +dotnet_diagnostic.CS1591.severity = none +dotnet_diagnostic.CS1573.severity = none +dotnet_diagnostic.CS1572.severity = none +dotnet_diagnostic.CS1571.severity = none +dotnet_diagnostic.CS1570.severity = none +dotnet_diagnostic.CS1587.severity = none +dotnet_diagnostic.CS1574.severity = none +dotnet_diagnostic.CS1580.severity = none +dotnet_diagnostic.CS1584.severity = none +dotnet_diagnostic.CS1658.severity = none + +# Code quality +dotnet_diagnostic.CA1822.severity = suggestion +dotnet_diagnostic.IDE0011.severity = warning +dotnet_diagnostic.IDE0040.severity = warning +dotnet_diagnostic.IDE0051.severity = silent +dotnet_diagnostic.IDE0052.severity = silent +dotnet_diagnostic.IDE0055.severity = warning + +# Serialization warnings +dotnet_diagnostic.CS0649.severity = silent +dotnet_diagnostic.CS0414.severity = silent + +# Suppressions +dotnet_diagnostic.IDE0071.severity = silent +dotnet_diagnostic.IDE0031.severity = silent diff --git a/sandbox/UnityApplication/.gitattributes b/sandbox/UnityApplication/.gitattributes index 3776778..72be0eb 100644 --- a/sandbox/UnityApplication/.gitattributes +++ b/sandbox/UnityApplication/.gitattributes @@ -1,11 +1,3 @@ -# Define macros (only works in top-level gitattributes files) -[attr]lfs filter=lfs diff=lfs merge=lfs -text -[attr]unity-json eol=lf linguist-language=json -[attr]unity-yaml merge=unityyamlmerge eol=lf linguist-language=yaml - -# Optionally collapse Unity-generated files on GitHub diffs -# [attr]unity-yaml merge=unityyamlmerge text linguist-language=yaml linguist-generated - # Unity source files *.cginc text *.compute text linguist-language=hlsl @@ -15,12 +7,12 @@ *.shader text # Unity JSON files -*.asmdef unity-json -*.asmref unity-json -*.index unity-json -*.inputactions unity-json -*.shadergraph unity-json -*.shadersubgraph unity-json +*.asmdef eol=lf linguist-language=json +*.asmref eol=lf linguist-language=json +*.index eol=lf linguist-language=json +*.inputactions eol=lf linguist-language=json +*.shadergraph eol=lf linguist-language=json +*.shadersubgraph eol=lf linguist-language=json # Unity UI Toolkit files *.tss text diff=css linguist-language=css @@ -28,134 +20,134 @@ *.uxml text linguist-language=xml linguist-detectable # Unity YAML -*.anim unity-yaml -*.asset unity-yaml -*.brush unity-yaml -*.controller unity-yaml -*.flare unity-yaml -*.fontsettings unity-yaml -*.giparams unity-yaml -*.guiskin unity-yaml -*.lighting unity-yaml -*.mask unity-yaml -*.mat unity-yaml -*.meta unity-yaml -*.mixer unity-yaml -*.overrideController unity-yaml -*.playable unity-yaml -*.prefab unity-yaml -*.preset unity-yaml -*.renderTexture unity-yaml -*.scenetemplate unity-yaml -*.shadervariants unity-yaml -*.signal unity-yaml -*.spriteatlas unity-yaml -*.spriteatlasv2 unity-yaml -*.terrainlayer unity-yaml -*.unity unity-yaml +*.anim merge=unityyamlmerge eol=lf linguist-language=yaml +*.asset merge=unityyamlmerge eol=lf linguist-language=yaml +*.brush merge=unityyamlmerge eol=lf linguist-language=yaml +*.controller merge=unityyamlmerge eol=lf linguist-language=yaml +*.flare merge=unityyamlmerge eol=lf linguist-language=yaml +*.fontsettings merge=unityyamlmerge eol=lf linguist-language=yaml +*.giparams merge=unityyamlmerge eol=lf linguist-language=yaml +*.guiskin merge=unityyamlmerge eol=lf linguist-language=yaml +*.lighting merge=unityyamlmerge eol=lf linguist-language=yaml +*.mask merge=unityyamlmerge eol=lf linguist-language=yaml +*.mat merge=unityyamlmerge eol=lf linguist-language=yaml +*.meta merge=unityyamlmerge eol=lf linguist-language=yaml +*.mixer merge=unityyamlmerge eol=lf linguist-language=yaml +*.overrideController merge=unityyamlmerge eol=lf linguist-language=yaml +*.playable merge=unityyamlmerge eol=lf linguist-language=yaml +*.prefab merge=unityyamlmerge eol=lf linguist-language=yaml +*.preset merge=unityyamlmerge eol=lf linguist-language=yaml +*.renderTexture merge=unityyamlmerge eol=lf linguist-language=yaml +*.scenetemplate merge=unityyamlmerge eol=lf linguist-language=yaml +*.shadervariants merge=unityyamlmerge eol=lf linguist-language=yaml +*.signal merge=unityyamlmerge eol=lf linguist-language=yaml +*.spriteatlas merge=unityyamlmerge eol=lf linguist-language=yaml +*.spriteatlasv2 merge=unityyamlmerge eol=lf linguist-language=yaml +*.terrainlayer merge=unityyamlmerge eol=lf linguist-language=yaml +*.unity merge=unityyamlmerge eol=lf linguist-language=yaml # "physic" for 3D but "physics" for 2D -*.physicMaterial unity-yaml -*.physicsMaterial2D unity-yaml +*.physicMaterial merge=unityyamlmerge eol=lf linguist-language=yaml +*.physicsMaterial2D merge=unityyamlmerge eol=lf linguist-language=yaml # Exclude third-party plugins from GitHub stats Assets/Plugins/** linguist-vendored # Unity LFS -*.cubemap lfs -*.unitypackage lfs +*.cubemap filter=lfs diff=lfs merge=lfs -text +*.unitypackage filter=lfs diff=lfs merge=lfs -text # 3D models -*.3dm lfs -*.3ds lfs -*.blend lfs -*.c4d lfs -*.collada lfs -*.dae lfs -*.dxf lfs -*.FBX lfs -*.fbx lfs -*.jas lfs -*.lws lfs -*.lxo lfs -*.ma lfs -*.max lfs -*.mb lfs -*.obj lfs -*.ply lfs -*.skp lfs -*.stl lfs -*.ztl lfs +*.3dm filter=lfs diff=lfs merge=lfs -text +*.3ds filter=lfs diff=lfs merge=lfs -text +*.blend filter=lfs diff=lfs merge=lfs -text +*.c4d filter=lfs diff=lfs merge=lfs -text +*.collada filter=lfs diff=lfs merge=lfs -text +*.dae filter=lfs diff=lfs merge=lfs -text +*.dxf filter=lfs diff=lfs merge=lfs -text +*.FBX filter=lfs diff=lfs merge=lfs -text +*.fbx filter=lfs diff=lfs merge=lfs -text +*.jas filter=lfs diff=lfs merge=lfs -text +*.lws filter=lfs diff=lfs merge=lfs -text +*.lxo filter=lfs diff=lfs merge=lfs -text +*.ma filter=lfs diff=lfs merge=lfs -text +*.max filter=lfs diff=lfs merge=lfs -text +*.mb filter=lfs diff=lfs merge=lfs -text +*.obj filter=lfs diff=lfs merge=lfs -text +*.ply filter=lfs diff=lfs merge=lfs -text +*.skp filter=lfs diff=lfs merge=lfs -text +*.stl filter=lfs diff=lfs merge=lfs -text +*.ztl filter=lfs diff=lfs merge=lfs -text # Audio -*.aif lfs -*.aiff lfs -*.it lfs -*.mod lfs -*.mp3 lfs -*.ogg lfs -*.s3m lfs -*.wav lfs -*.xm lfs +*.aif filter=lfs diff=lfs merge=lfs -text +*.aiff filter=lfs diff=lfs merge=lfs -text +*.it filter=lfs diff=lfs merge=lfs -text +*.mod filter=lfs diff=lfs merge=lfs -text +*.mp3 filter=lfs diff=lfs merge=lfs -text +*.ogg filter=lfs diff=lfs merge=lfs -text +*.s3m filter=lfs diff=lfs merge=lfs -text +*.wav filter=lfs diff=lfs merge=lfs -text +*.xm filter=lfs diff=lfs merge=lfs -text # Video -*.asf lfs -*.avi lfs -*.flv lfs -*.mov lfs -*.mp4 lfs -*.mpeg lfs -*.mpg lfs -*.ogv lfs -*.wmv lfs +*.asf filter=lfs diff=lfs merge=lfs -text +*.avi filter=lfs diff=lfs merge=lfs -text +*.flv filter=lfs diff=lfs merge=lfs -text +*.mov filter=lfs diff=lfs merge=lfs -text +*.mp4 filter=lfs diff=lfs merge=lfs -text +*.mpeg filter=lfs diff=lfs merge=lfs -text +*.mpg filter=lfs diff=lfs merge=lfs -text +*.ogv filter=lfs diff=lfs merge=lfs -text +*.wmv filter=lfs diff=lfs merge=lfs -text # Images -*.bmp lfs -*.exr lfs -*.gif lfs -*.hdr lfs -*.iff lfs -*.jpeg lfs -*.jpg lfs -*.pict lfs -*.png lfs -*.psd lfs -*.tga lfs -*.tif lfs -*.tiff lfs -*.webp lfs +*.bmp filter=lfs diff=lfs merge=lfs -text +*.exr filter=lfs diff=lfs merge=lfs -text +*.gif filter=lfs diff=lfs merge=lfs -text +*.hdr filter=lfs diff=lfs merge=lfs -text +*.iff filter=lfs diff=lfs merge=lfs -text +*.jpeg filter=lfs diff=lfs merge=lfs -text +*.jpg filter=lfs diff=lfs merge=lfs -text +*.pict filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.psd filter=lfs diff=lfs merge=lfs -text +*.tga filter=lfs diff=lfs merge=lfs -text +*.tif filter=lfs diff=lfs merge=lfs -text +*.tiff filter=lfs diff=lfs merge=lfs -text +*.webp filter=lfs diff=lfs merge=lfs -text # Compressed Archive -*.7z lfs -*.bz2 lfs -*.gz lfs -*.rar lfs -*.tar lfs -*.zip lfs +*.7z filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.rar filter=lfs diff=lfs merge=lfs -text +*.tar filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text # Compiled Dynamic Library -*.dll lfs -*.pdb lfs -*.so lfs +*.dll filter=lfs diff=lfs merge=lfs -text +*.pdb filter=lfs diff=lfs merge=lfs -text +*.so filter=lfs diff=lfs merge=lfs -text # Fonts -*.otf lfs -*.ttf lfs +*.otf filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text # Executable/Installer -*.apk lfs -*.exe lfs +*.apk filter=lfs diff=lfs merge=lfs -text +*.exe filter=lfs diff=lfs merge=lfs -text # Documents -*.pdf lfs +*.pdf filter=lfs diff=lfs merge=lfs -text # ETC -*.a lfs -*.reason lfs -*.rns lfs +*.a filter=lfs diff=lfs merge=lfs -text +*.reason filter=lfs diff=lfs merge=lfs -text +*.rns filter=lfs diff=lfs merge=lfs -text # Spine export file for Unity -*.skel.bytes lfs +*.skel.bytes filter=lfs diff=lfs merge=lfs -text # Exceptions for .asset files such as lightning pre-baking LightingData.asset binary \ No newline at end of file diff --git a/sandbox/UnityApplication/UnityApplication.slnx b/sandbox/UnityApplication/UnityApplication.slnx index 02e48e6..4adb8c2 100644 --- a/sandbox/UnityApplication/UnityApplication.slnx +++ b/sandbox/UnityApplication/UnityApplication.slnx @@ -1,4 +1,4 @@ - + diff --git a/src/GroveGames.BehaviourTree.Unity/Packages/com.grovegames.behaviourtree/Editor/csc.rsp b/src/GroveGames.BehaviourTree.Unity/Packages/com.grovegames.behaviourtree/Editor/csc.rsp new file mode 100644 index 0000000..d194954 --- /dev/null +++ b/src/GroveGames.BehaviourTree.Unity/Packages/com.grovegames.behaviourtree/Editor/csc.rsp @@ -0,0 +1,2 @@ +-langversion:10 +-nullable:enable diff --git a/src/GroveGames.BehaviourTree.Unity/Packages/com.grovegames.behaviourtree/Runtime/csc.rsp b/src/GroveGames.BehaviourTree.Unity/Packages/com.grovegames.behaviourtree/Runtime/csc.rsp new file mode 100644 index 0000000..d194954 --- /dev/null +++ b/src/GroveGames.BehaviourTree.Unity/Packages/com.grovegames.behaviourtree/Runtime/csc.rsp @@ -0,0 +1,2 @@ +-langversion:10 +-nullable:enable diff --git a/src/GroveGames.BehaviourTree.Unity/Packages/com.grovegames.behaviourtree/Tests/Editor/csc.rsp b/src/GroveGames.BehaviourTree.Unity/Packages/com.grovegames.behaviourtree/Tests/Editor/csc.rsp new file mode 100644 index 0000000..d194954 --- /dev/null +++ b/src/GroveGames.BehaviourTree.Unity/Packages/com.grovegames.behaviourtree/Tests/Editor/csc.rsp @@ -0,0 +1,2 @@ +-langversion:10 +-nullable:enable diff --git a/src/GroveGames.BehaviourTree.Unity/Packages/com.grovegames.behaviourtree/Tests/Runtime/csc.rsp b/src/GroveGames.BehaviourTree.Unity/Packages/com.grovegames.behaviourtree/Tests/Runtime/csc.rsp new file mode 100644 index 0000000..d194954 --- /dev/null +++ b/src/GroveGames.BehaviourTree.Unity/Packages/com.grovegames.behaviourtree/Tests/Runtime/csc.rsp @@ -0,0 +1,2 @@ +-langversion:10 +-nullable:enable diff --git a/src/GroveGames.BehaviourTree/AssemblyInfo.cs b/src/GroveGames.BehaviourTree/AssemblyInfo.cs index c7670c0..39f1dd7 100644 --- a/src/GroveGames.BehaviourTree/AssemblyInfo.cs +++ b/src/GroveGames.BehaviourTree/AssemblyInfo.cs @@ -1,6 +1,6 @@ -using System.Runtime.CompilerServices; +using System.Runtime.CompilerServices; [assembly: InternalsVisibleTo("GroveGames.BehaviourTree.Tests")] [assembly: InternalsVisibleTo("GroveGames.BehaviourTree.Unity")] [assembly: InternalsVisibleTo("GroveGames.BehaviourTree.Godot")] -[assembly: InternalsVisibleTo("DynamicProxyGenAssembly2")] \ No newline at end of file +[assembly: InternalsVisibleTo("DynamicProxyGenAssembly2")] diff --git a/src/GroveGames.BehaviourTree/BehaviourTree.cs b/src/GroveGames.BehaviourTree/BehaviourTree.cs index 60b288d..498d218 100644 --- a/src/GroveGames.BehaviourTree/BehaviourTree.cs +++ b/src/GroveGames.BehaviourTree/BehaviourTree.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Nodes; +using GroveGames.BehaviourTree.Nodes; namespace GroveGames.BehaviourTree; diff --git a/src/GroveGames.BehaviourTree/ChildTree.cs b/src/GroveGames.BehaviourTree/ChildTree.cs index c3a08b4..9c8793a 100644 --- a/src/GroveGames.BehaviourTree/ChildTree.cs +++ b/src/GroveGames.BehaviourTree/ChildTree.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Nodes; +using GroveGames.BehaviourTree.Nodes; namespace GroveGames.BehaviourTree; diff --git a/src/GroveGames.BehaviourTree/Collections/Blackboard.cs b/src/GroveGames.BehaviourTree/Collections/Blackboard.cs index de6f1c7..814cbd4 100644 --- a/src/GroveGames.BehaviourTree/Collections/Blackboard.cs +++ b/src/GroveGames.BehaviourTree/Collections/Blackboard.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Collections; +namespace GroveGames.BehaviourTree.Collections; public class Blackboard : IBlackboard { diff --git a/src/GroveGames.BehaviourTree/Collections/IBlackboard.cs b/src/GroveGames.BehaviourTree/Collections/IBlackboard.cs index 3c8786c..a8ab4aa 100644 --- a/src/GroveGames.BehaviourTree/Collections/IBlackboard.cs +++ b/src/GroveGames.BehaviourTree/Collections/IBlackboard.cs @@ -1,9 +1,9 @@ -namespace GroveGames.BehaviourTree.Collections; +namespace GroveGames.BehaviourTree.Collections; public interface IBlackboard { - void SetValue(string key, T obj) where T : notnull; - T? GetValue(string key); - void DeleteValue(string key); - void Clear(); + public void SetValue(string key, T obj) where T : notnull; + public T? GetValue(string key); + public void DeleteValue(string key); + public void Clear(); } diff --git a/src/GroveGames.BehaviourTree/IChildTree.cs b/src/GroveGames.BehaviourTree/IChildTree.cs index 272139c..11f591d 100644 --- a/src/GroveGames.BehaviourTree/IChildTree.cs +++ b/src/GroveGames.BehaviourTree/IChildTree.cs @@ -1,8 +1,8 @@ -using GroveGames.BehaviourTree.Nodes; +using GroveGames.BehaviourTree.Nodes; namespace GroveGames.BehaviourTree; public interface IChildTree { - void SetupTree(IParent parent); + public void SetupTree(IParent parent); } diff --git a/src/GroveGames.BehaviourTree/ITree.cs b/src/GroveGames.BehaviourTree/ITree.cs index 4fcd762..848ed6d 100644 --- a/src/GroveGames.BehaviourTree/ITree.cs +++ b/src/GroveGames.BehaviourTree/ITree.cs @@ -1,11 +1,11 @@ -namespace GroveGames.BehaviourTree; +namespace GroveGames.BehaviourTree; public interface ITree { - void SetupTree(); - void Reset(); - void Abort(); - void Enable(); - void Disable(); - void Tick(float deltaTime); + public void SetupTree(); + public void Reset(); + public void Abort(); + public void Enable(); + public void Disable(); + public void Tick(float deltaTime); } diff --git a/src/GroveGames.BehaviourTree/Nodes/BehaviourNode.cs b/src/GroveGames.BehaviourTree/Nodes/BehaviourNode.cs index 5adc84d..c842bcd 100644 --- a/src/GroveGames.BehaviourTree/Nodes/BehaviourNode.cs +++ b/src/GroveGames.BehaviourTree/Nodes/BehaviourNode.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Collections; +using GroveGames.BehaviourTree.Collections; namespace GroveGames.BehaviourTree.Nodes; diff --git a/src/GroveGames.BehaviourTree/Nodes/BehaviourRoot.cs b/src/GroveGames.BehaviourTree/Nodes/BehaviourRoot.cs index 5b743d5..9effb90 100644 --- a/src/GroveGames.BehaviourTree/Nodes/BehaviourRoot.cs +++ b/src/GroveGames.BehaviourTree/Nodes/BehaviourRoot.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Collections; +using GroveGames.BehaviourTree.Collections; namespace GroveGames.BehaviourTree.Nodes; diff --git a/src/GroveGames.BehaviourTree/Nodes/ChildAlreadyAttachedException.cs b/src/GroveGames.BehaviourTree/Nodes/ChildAlreadyAttachedException.cs index 88bfa10..981af54 100644 --- a/src/GroveGames.BehaviourTree/Nodes/ChildAlreadyAttachedException.cs +++ b/src/GroveGames.BehaviourTree/Nodes/ChildAlreadyAttachedException.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes +namespace GroveGames.BehaviourTree.Nodes { public class ChildAlreadyAttachedException : InvalidOperationException { @@ -11,4 +11,4 @@ public ChildAlreadyAttachedException(string message) public ChildAlreadyAttachedException(string message, Exception innerException) : base(message, innerException) { } } -} \ No newline at end of file +} diff --git a/src/GroveGames.BehaviourTree/Nodes/Composites/Composite.cs b/src/GroveGames.BehaviourTree/Nodes/Composites/Composite.cs index 3bcae8d..c4bfe62 100644 --- a/src/GroveGames.BehaviourTree/Nodes/Composites/Composite.cs +++ b/src/GroveGames.BehaviourTree/Nodes/Composites/Composite.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes.Composites; +namespace GroveGames.BehaviourTree.Nodes.Composites; public abstract class Composite : BehaviourNode, IParent { diff --git a/src/GroveGames.BehaviourTree/Nodes/Composites/Parallel.cs b/src/GroveGames.BehaviourTree/Nodes/Composites/Parallel.cs index d466a15..febf88d 100644 --- a/src/GroveGames.BehaviourTree/Nodes/Composites/Parallel.cs +++ b/src/GroveGames.BehaviourTree/Nodes/Composites/Parallel.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes.Composites; +namespace GroveGames.BehaviourTree.Nodes.Composites; public sealed class Parallel : Composite { @@ -61,4 +61,4 @@ public static IParent Parallel(this IParent parent, ParallelPolicy policy) parent.Attach(parallel); return parallel; } -} \ No newline at end of file +} diff --git a/src/GroveGames.BehaviourTree/Nodes/Composites/ParallelPolicy.cs b/src/GroveGames.BehaviourTree/Nodes/Composites/ParallelPolicy.cs index 21bc794..9a1d816 100644 --- a/src/GroveGames.BehaviourTree/Nodes/Composites/ParallelPolicy.cs +++ b/src/GroveGames.BehaviourTree/Nodes/Composites/ParallelPolicy.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes.Composites; +namespace GroveGames.BehaviourTree.Nodes.Composites; public enum ParallelPolicy { diff --git a/src/GroveGames.BehaviourTree/Nodes/Composites/Selector.cs b/src/GroveGames.BehaviourTree/Nodes/Composites/Selector.cs index ede35a9..1989f25 100644 --- a/src/GroveGames.BehaviourTree/Nodes/Composites/Selector.cs +++ b/src/GroveGames.BehaviourTree/Nodes/Composites/Selector.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes.Composites; +namespace GroveGames.BehaviourTree.Nodes.Composites; public sealed class Selector : Composite { diff --git a/src/GroveGames.BehaviourTree/Nodes/Composites/Sequence.cs b/src/GroveGames.BehaviourTree/Nodes/Composites/Sequence.cs index 557d2ba..dcfe835 100644 --- a/src/GroveGames.BehaviourTree/Nodes/Composites/Sequence.cs +++ b/src/GroveGames.BehaviourTree/Nodes/Composites/Sequence.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes.Composites; +namespace GroveGames.BehaviourTree.Nodes.Composites; public sealed class Sequence : Composite { diff --git a/src/GroveGames.BehaviourTree/Nodes/Decorators/Abort.cs b/src/GroveGames.BehaviourTree/Nodes/Decorators/Abort.cs index f2f3dda..76ba8eb 100644 --- a/src/GroveGames.BehaviourTree/Nodes/Decorators/Abort.cs +++ b/src/GroveGames.BehaviourTree/Nodes/Decorators/Abort.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes.Decorators; +namespace GroveGames.BehaviourTree.Nodes.Decorators; public class Abort : Decorator { diff --git a/src/GroveGames.BehaviourTree/Nodes/Decorators/Conditional.cs b/src/GroveGames.BehaviourTree/Nodes/Decorators/Conditional.cs index 310487c..1d78f7f 100644 --- a/src/GroveGames.BehaviourTree/Nodes/Decorators/Conditional.cs +++ b/src/GroveGames.BehaviourTree/Nodes/Decorators/Conditional.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes.Decorators; +namespace GroveGames.BehaviourTree.Nodes.Decorators; public sealed class Conditional : Decorator { diff --git a/src/GroveGames.BehaviourTree/Nodes/Decorators/Cooldown.cs b/src/GroveGames.BehaviourTree/Nodes/Decorators/Cooldown.cs index 56a5155..f9e8de7 100644 --- a/src/GroveGames.BehaviourTree/Nodes/Decorators/Cooldown.cs +++ b/src/GroveGames.BehaviourTree/Nodes/Decorators/Cooldown.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes.Decorators; +namespace GroveGames.BehaviourTree.Nodes.Decorators; public sealed class Cooldown : Decorator { diff --git a/src/GroveGames.BehaviourTree/Nodes/Decorators/Decorator.cs b/src/GroveGames.BehaviourTree/Nodes/Decorators/Decorator.cs index 329eb2e..7d8a127 100644 --- a/src/GroveGames.BehaviourTree/Nodes/Decorators/Decorator.cs +++ b/src/GroveGames.BehaviourTree/Nodes/Decorators/Decorator.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes.Decorators; +namespace GroveGames.BehaviourTree.Nodes.Decorators; public abstract class Decorator : BehaviourNode, IParent { diff --git a/src/GroveGames.BehaviourTree/Nodes/Decorators/Delayer.cs b/src/GroveGames.BehaviourTree/Nodes/Decorators/Delayer.cs index b6c338b..8bfbf47 100644 --- a/src/GroveGames.BehaviourTree/Nodes/Decorators/Delayer.cs +++ b/src/GroveGames.BehaviourTree/Nodes/Decorators/Delayer.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes.Decorators; +namespace GroveGames.BehaviourTree.Nodes.Decorators; public sealed class Delayer : Decorator { diff --git a/src/GroveGames.BehaviourTree/Nodes/Decorators/Failer.cs b/src/GroveGames.BehaviourTree/Nodes/Decorators/Failer.cs index e2cf8bd..72032d8 100644 --- a/src/GroveGames.BehaviourTree/Nodes/Decorators/Failer.cs +++ b/src/GroveGames.BehaviourTree/Nodes/Decorators/Failer.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes.Decorators; +namespace GroveGames.BehaviourTree.Nodes.Decorators; public sealed class Failer : Decorator { diff --git a/src/GroveGames.BehaviourTree/Nodes/Decorators/Inverter.cs b/src/GroveGames.BehaviourTree/Nodes/Decorators/Inverter.cs index 1c68193..919b91d 100644 --- a/src/GroveGames.BehaviourTree/Nodes/Decorators/Inverter.cs +++ b/src/GroveGames.BehaviourTree/Nodes/Decorators/Inverter.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes.Decorators; +namespace GroveGames.BehaviourTree.Nodes.Decorators; public sealed class Inverter : Decorator { diff --git a/src/GroveGames.BehaviourTree/Nodes/Decorators/RepeatMode.cs b/src/GroveGames.BehaviourTree/Nodes/Decorators/RepeatMode.cs index 26b19d5..bd5794d 100644 --- a/src/GroveGames.BehaviourTree/Nodes/Decorators/RepeatMode.cs +++ b/src/GroveGames.BehaviourTree/Nodes/Decorators/RepeatMode.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes.Decorators; +namespace GroveGames.BehaviourTree.Nodes.Decorators; public enum RepeatMode { diff --git a/src/GroveGames.BehaviourTree/Nodes/Decorators/Repeater.cs b/src/GroveGames.BehaviourTree/Nodes/Decorators/Repeater.cs index c223aab..c148f53 100644 --- a/src/GroveGames.BehaviourTree/Nodes/Decorators/Repeater.cs +++ b/src/GroveGames.BehaviourTree/Nodes/Decorators/Repeater.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes.Decorators; +namespace GroveGames.BehaviourTree.Nodes.Decorators; public sealed class Repeater : Decorator { diff --git a/src/GroveGames.BehaviourTree/Nodes/Decorators/Reset.cs b/src/GroveGames.BehaviourTree/Nodes/Decorators/Reset.cs index 819a39f..a811f6e 100644 --- a/src/GroveGames.BehaviourTree/Nodes/Decorators/Reset.cs +++ b/src/GroveGames.BehaviourTree/Nodes/Decorators/Reset.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes.Decorators; +namespace GroveGames.BehaviourTree.Nodes.Decorators; public class Reset : Decorator { diff --git a/src/GroveGames.BehaviourTree/Nodes/Decorators/Succeeder.cs b/src/GroveGames.BehaviourTree/Nodes/Decorators/Succeeder.cs index 57bc1d4..ff38d3a 100644 --- a/src/GroveGames.BehaviourTree/Nodes/Decorators/Succeeder.cs +++ b/src/GroveGames.BehaviourTree/Nodes/Decorators/Succeeder.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes.Decorators; +namespace GroveGames.BehaviourTree.Nodes.Decorators; public sealed class Succeeder : Decorator { diff --git a/src/GroveGames.BehaviourTree/Nodes/Decorators/SuccessOnce.cs b/src/GroveGames.BehaviourTree/Nodes/Decorators/SuccessOnce.cs index a1407a3..392c9ae 100644 --- a/src/GroveGames.BehaviourTree/Nodes/Decorators/SuccessOnce.cs +++ b/src/GroveGames.BehaviourTree/Nodes/Decorators/SuccessOnce.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes.Decorators; +namespace GroveGames.BehaviourTree.Nodes.Decorators; public class SuccessOnce : Decorator { diff --git a/src/GroveGames.BehaviourTree/Nodes/EmptyBehaviourNode.cs b/src/GroveGames.BehaviourTree/Nodes/EmptyBehaviourNode.cs index a6497d7..8995c87 100644 --- a/src/GroveGames.BehaviourTree/Nodes/EmptyBehaviourNode.cs +++ b/src/GroveGames.BehaviourTree/Nodes/EmptyBehaviourNode.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes; +namespace GroveGames.BehaviourTree.Nodes; public sealed class EmptyBehaviourNode : INode { diff --git a/src/GroveGames.BehaviourTree/Nodes/INode.cs b/src/GroveGames.BehaviourTree/Nodes/INode.cs index fd63963..6f5c28f 100644 --- a/src/GroveGames.BehaviourTree/Nodes/INode.cs +++ b/src/GroveGames.BehaviourTree/Nodes/INode.cs @@ -1,12 +1,12 @@ -namespace GroveGames.BehaviourTree.Nodes; +namespace GroveGames.BehaviourTree.Nodes; public interface INode { - NodeState Evaluate(float deltaTime); - void Reset(); - void Abort(); - void StartEvaluate(); - void EndEvaluate(); - void SetParent(IParent parent); - NodeState State { get; } -} \ No newline at end of file + public NodeState Evaluate(float deltaTime); + public void Reset(); + public void Abort(); + public void StartEvaluate(); + public void EndEvaluate(); + public void SetParent(IParent parent); + public NodeState State { get; } +} diff --git a/src/GroveGames.BehaviourTree/Nodes/IParent.cs b/src/GroveGames.BehaviourTree/Nodes/IParent.cs index 4798bc7..174f2e5 100644 --- a/src/GroveGames.BehaviourTree/Nodes/IParent.cs +++ b/src/GroveGames.BehaviourTree/Nodes/IParent.cs @@ -1,10 +1,10 @@ -using GroveGames.BehaviourTree.Collections; +using GroveGames.BehaviourTree.Collections; namespace GroveGames.BehaviourTree.Nodes; public interface IParent { - IParent Attach(INode node); - IParent Attach(IChildTree tree); - IBlackboard Blackboard { get; } + public IParent Attach(INode node); + public IParent Attach(IChildTree tree); + public IBlackboard Blackboard { get; } } diff --git a/src/GroveGames.BehaviourTree/Nodes/IRoot.cs b/src/GroveGames.BehaviourTree/Nodes/IRoot.cs index 5aeba5d..997144c 100644 --- a/src/GroveGames.BehaviourTree/Nodes/IRoot.cs +++ b/src/GroveGames.BehaviourTree/Nodes/IRoot.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes; +namespace GroveGames.BehaviourTree.Nodes; public interface IRoot : INode, IParent { diff --git a/src/GroveGames.BehaviourTree/Nodes/NodeState.cs b/src/GroveGames.BehaviourTree/Nodes/NodeState.cs index 63db371..0c8183a 100644 --- a/src/GroveGames.BehaviourTree/Nodes/NodeState.cs +++ b/src/GroveGames.BehaviourTree/Nodes/NodeState.cs @@ -1,4 +1,4 @@ -namespace GroveGames.BehaviourTree.Nodes; +namespace GroveGames.BehaviourTree.Nodes; public enum NodeState { diff --git a/src/GroveGames.BehaviourTree/Polyfills/System.Runtime.CompilerServices/CallerArgumentExpressionAttribute.cs b/src/GroveGames.BehaviourTree/Polyfills/System.Runtime.CompilerServices/CallerArgumentExpressionAttribute.cs index 31147ca..cdedcad 100644 --- a/src/GroveGames.BehaviourTree/Polyfills/System.Runtime.CompilerServices/CallerArgumentExpressionAttribute.cs +++ b/src/GroveGames.BehaviourTree/Polyfills/System.Runtime.CompilerServices/CallerArgumentExpressionAttribute.cs @@ -1,4 +1,4 @@ -#if !NET5_0_OR_GREATER +#if !NET5_0_OR_GREATER namespace System.Runtime.CompilerServices; diff --git a/src/GroveGames.BehaviourTree/Polyfills/System.Threading/Lock.cs b/src/GroveGames.BehaviourTree/Polyfills/System.Threading/Lock.cs index 0f7be9e..eb8c6e0 100644 --- a/src/GroveGames.BehaviourTree/Polyfills/System.Threading/Lock.cs +++ b/src/GroveGames.BehaviourTree/Polyfills/System.Threading/Lock.cs @@ -1,4 +1,4 @@ -#if !NET9_0_OR_GREATER +#if !NET9_0_OR_GREATER namespace System.Threading; diff --git a/src/GroveGames.BehaviourTree/Polyfills/System/ArgumentExceptionExtensions.cs b/src/GroveGames.BehaviourTree/Polyfills/System/ArgumentExceptionExtensions.cs index cbcc66b..24db63a 100644 --- a/src/GroveGames.BehaviourTree/Polyfills/System/ArgumentExceptionExtensions.cs +++ b/src/GroveGames.BehaviourTree/Polyfills/System/ArgumentExceptionExtensions.cs @@ -1,4 +1,4 @@ -#if !NET7_0_OR_GREATER +#if !NET7_0_OR_GREATER using System.Diagnostics.CodeAnalysis; using System.Runtime.CompilerServices; diff --git a/src/GroveGames.BehaviourTree/Polyfills/System/ArgumentNullExceptionExtensions.cs b/src/GroveGames.BehaviourTree/Polyfills/System/ArgumentNullExceptionExtensions.cs index e67ba0b..eefae2f 100644 --- a/src/GroveGames.BehaviourTree/Polyfills/System/ArgumentNullExceptionExtensions.cs +++ b/src/GroveGames.BehaviourTree/Polyfills/System/ArgumentNullExceptionExtensions.cs @@ -1,4 +1,4 @@ -#if !NET6_0_OR_GREATER +#if !NET6_0_OR_GREATER using System.Diagnostics.CodeAnalysis; using System.Runtime.CompilerServices; diff --git a/src/GroveGames.BehaviourTree/Polyfills/System/ArgumentOutOfRangeExceptionExtensions.cs b/src/GroveGames.BehaviourTree/Polyfills/System/ArgumentOutOfRangeExceptionExtensions.cs index a4eba3a..d29c1b0 100644 --- a/src/GroveGames.BehaviourTree/Polyfills/System/ArgumentOutOfRangeExceptionExtensions.cs +++ b/src/GroveGames.BehaviourTree/Polyfills/System/ArgumentOutOfRangeExceptionExtensions.cs @@ -1,4 +1,4 @@ -#if !NET8_0_OR_GREATER +#if !NET8_0_OR_GREATER using System.Runtime.CompilerServices; diff --git a/src/GroveGames.BehaviourTree/Polyfills/System/ObjectDisposedExceptionExtensions.cs b/src/GroveGames.BehaviourTree/Polyfills/System/ObjectDisposedExceptionExtensions.cs index 48312cd..df8a33e 100644 --- a/src/GroveGames.BehaviourTree/Polyfills/System/ObjectDisposedExceptionExtensions.cs +++ b/src/GroveGames.BehaviourTree/Polyfills/System/ObjectDisposedExceptionExtensions.cs @@ -1,4 +1,4 @@ -#if !NET8_0_OR_GREATER +#if !NET8_0_OR_GREATER namespace System; diff --git a/tests/GroveGames.BehaviourTree.Tests/Collections/BlackboardTests.cs b/tests/GroveGames.BehaviourTree.Tests/Collections/BlackboardTests.cs index 77dcb96..53ab882 100644 --- a/tests/GroveGames.BehaviourTree.Tests/Collections/BlackboardTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/Collections/BlackboardTests.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Collections; +using GroveGames.BehaviourTree.Collections; namespace GroveGames.BehaviourTree.Tests.Collections; diff --git a/tests/GroveGames.BehaviourTree.Tests/GlobalUsings.cs b/tests/GroveGames.BehaviourTree.Tests/GlobalUsings.cs index c802f44..9df1d42 100644 --- a/tests/GroveGames.BehaviourTree.Tests/GlobalUsings.cs +++ b/tests/GroveGames.BehaviourTree.Tests/GlobalUsings.cs @@ -1 +1 @@ -global using Xunit; +global using Xunit; diff --git a/tests/GroveGames.BehaviourTree.Tests/GroveGames.BehaviourTree.Tests.csproj b/tests/GroveGames.BehaviourTree.Tests/GroveGames.BehaviourTree.Tests.csproj index dd53524..cb4d388 100644 --- a/tests/GroveGames.BehaviourTree.Tests/GroveGames.BehaviourTree.Tests.csproj +++ b/tests/GroveGames.BehaviourTree.Tests/GroveGames.BehaviourTree.Tests.csproj @@ -1,12 +1,18 @@ - net10.0 + net10.0;net9.0;net8.0 enable false true + true + $(RootNamespace).Tests + + + + diff --git a/tests/GroveGames.BehaviourTree.Tests/Nodes/Composites/CompositeTests.cs b/tests/GroveGames.BehaviourTree.Tests/Nodes/Composites/CompositeTests.cs index 0f93df2..7615ecf 100644 --- a/tests/GroveGames.BehaviourTree.Tests/Nodes/Composites/CompositeTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/Nodes/Composites/CompositeTests.cs @@ -1,4 +1,4 @@ -using System.Reflection; +using System.Reflection; using GroveGames.BehaviourTree.Collections; using GroveGames.BehaviourTree.Nodes; diff --git a/tests/GroveGames.BehaviourTree.Tests/Nodes/Composites/ParallelTests.cs b/tests/GroveGames.BehaviourTree.Tests/Nodes/Composites/ParallelTests.cs index 934d99c..f435a67 100644 --- a/tests/GroveGames.BehaviourTree.Tests/Nodes/Composites/ParallelTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/Nodes/Composites/ParallelTests.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Collections; +using GroveGames.BehaviourTree.Collections; using GroveGames.BehaviourTree.Nodes; using GroveGames.BehaviourTree.Nodes.Composites; diff --git a/tests/GroveGames.BehaviourTree.Tests/Nodes/Composites/SelectorTests.cs b/tests/GroveGames.BehaviourTree.Tests/Nodes/Composites/SelectorTests.cs index 8268e4e..77d29eb 100644 --- a/tests/GroveGames.BehaviourTree.Tests/Nodes/Composites/SelectorTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/Nodes/Composites/SelectorTests.cs @@ -1,4 +1,4 @@ -using System.Reflection; +using System.Reflection; using GroveGames.BehaviourTree.Collections; using GroveGames.BehaviourTree.Nodes; diff --git a/tests/GroveGames.BehaviourTree.Tests/Nodes/Composites/SequenceTests.cs b/tests/GroveGames.BehaviourTree.Tests/Nodes/Composites/SequenceTests.cs index 30ebcc4..bfd99df 100644 --- a/tests/GroveGames.BehaviourTree.Tests/Nodes/Composites/SequenceTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/Nodes/Composites/SequenceTests.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Collections; +using GroveGames.BehaviourTree.Collections; using GroveGames.BehaviourTree.Nodes; using GroveGames.BehaviourTree.Nodes.Composites; diff --git a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/AbortTests.cs b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/AbortTests.cs index 74bc017..86c3c94 100644 --- a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/AbortTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/AbortTests.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Collections; +using GroveGames.BehaviourTree.Collections; using GroveGames.BehaviourTree.Nodes; using GroveGames.BehaviourTree.Nodes.Decorators; diff --git a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/ConditionalTests.cs b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/ConditionalTests.cs index aa24782..764021b 100644 --- a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/ConditionalTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/ConditionalTests.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Collections; +using GroveGames.BehaviourTree.Collections; using GroveGames.BehaviourTree.Nodes; using GroveGames.BehaviourTree.Nodes.Decorators; diff --git a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/CooldownTests.cs b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/CooldownTests.cs index 9895eb4..7aacd05 100644 --- a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/CooldownTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/CooldownTests.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Collections; +using GroveGames.BehaviourTree.Collections; using GroveGames.BehaviourTree.Nodes; using GroveGames.BehaviourTree.Nodes.Decorators; diff --git a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/DecoratorTests.cs b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/DecoratorTests.cs index e43a667..7677f1c 100644 --- a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/DecoratorTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/DecoratorTests.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Collections; +using GroveGames.BehaviourTree.Collections; using GroveGames.BehaviourTree.Nodes; using GroveGames.BehaviourTree.Nodes.Decorators; diff --git a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/DelayerTests.cs b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/DelayerTests.cs index 2bff2dd..19920ae 100644 --- a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/DelayerTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/DelayerTests.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Collections; +using GroveGames.BehaviourTree.Collections; using GroveGames.BehaviourTree.Nodes; using GroveGames.BehaviourTree.Nodes.Decorators; diff --git a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/FailerTests.cs b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/FailerTests.cs index 9fc4057..45c9570 100644 --- a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/FailerTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/FailerTests.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Collections; +using GroveGames.BehaviourTree.Collections; using GroveGames.BehaviourTree.Nodes; using GroveGames.BehaviourTree.Nodes.Decorators; diff --git a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/InverterTests.cs b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/InverterTests.cs index 081c306..6e2006e 100644 --- a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/InverterTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/InverterTests.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Collections; +using GroveGames.BehaviourTree.Collections; using GroveGames.BehaviourTree.Nodes; using GroveGames.BehaviourTree.Nodes.Decorators; diff --git a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/RepeaterTests.cs b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/RepeaterTests.cs index 826b355..edfcd8e 100644 --- a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/RepeaterTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/RepeaterTests.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Collections; +using GroveGames.BehaviourTree.Collections; using GroveGames.BehaviourTree.Nodes; using GroveGames.BehaviourTree.Nodes.Decorators; diff --git a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/ResetTests.cs b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/ResetTests.cs index cef5506..dd820b1 100644 --- a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/ResetTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/ResetTests.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Collections; +using GroveGames.BehaviourTree.Collections; using GroveGames.BehaviourTree.Nodes; using GroveGames.BehaviourTree.Nodes.Decorators; diff --git a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/SucceederTests.cs b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/SucceederTests.cs index 04cc439..5eb6f27 100644 --- a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/SucceederTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/SucceederTests.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Collections; +using GroveGames.BehaviourTree.Collections; using GroveGames.BehaviourTree.Nodes; using GroveGames.BehaviourTree.Nodes.Decorators; diff --git a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/SuccessOnceTests.cs b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/SuccessOnceTests.cs index fd6eef9..7b7c7de 100644 --- a/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/SuccessOnceTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/Nodes/Decorators/SuccessOnceTests.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Collections; +using GroveGames.BehaviourTree.Collections; using GroveGames.BehaviourTree.Nodes; using GroveGames.BehaviourTree.Nodes.Decorators; diff --git a/tests/GroveGames.BehaviourTree.Tests/Nodes/EmptyNodeTests.cs b/tests/GroveGames.BehaviourTree.Tests/Nodes/EmptyNodeTests.cs index 4f004a4..5e4f4fb 100644 --- a/tests/GroveGames.BehaviourTree.Tests/Nodes/EmptyNodeTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/Nodes/EmptyNodeTests.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Nodes; +using GroveGames.BehaviourTree.Nodes; namespace GroveGames.BehaviourTree.Tests.Nodes; diff --git a/tests/GroveGames.BehaviourTree.Tests/Nodes/NodeTests.cs b/tests/GroveGames.BehaviourTree.Tests/Nodes/NodeTests.cs index 12ea582..4d09192 100644 --- a/tests/GroveGames.BehaviourTree.Tests/Nodes/NodeTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/Nodes/NodeTests.cs @@ -1,4 +1,4 @@ -using System.Reflection; +using System.Reflection; using GroveGames.BehaviourTree.Collections; using GroveGames.BehaviourTree.Nodes; diff --git a/tests/GroveGames.BehaviourTree.Tests/Nodes/RootTests.cs b/tests/GroveGames.BehaviourTree.Tests/Nodes/RootTests.cs index 0c1d084..02571d4 100644 --- a/tests/GroveGames.BehaviourTree.Tests/Nodes/RootTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/Nodes/RootTests.cs @@ -1,4 +1,4 @@ -using GroveGames.BehaviourTree.Collections; +using GroveGames.BehaviourTree.Collections; using GroveGames.BehaviourTree.Nodes; namespace GroveGames.BehaviourTree.Tests.Nodes; diff --git a/tests/GroveGames.BehaviourTree.Tests/TreeTests.cs b/tests/GroveGames.BehaviourTree.Tests/TreeTests.cs index e0ef429..ee7a6be 100644 --- a/tests/GroveGames.BehaviourTree.Tests/TreeTests.cs +++ b/tests/GroveGames.BehaviourTree.Tests/TreeTests.cs @@ -1,4 +1,4 @@ -using System.Reflection; +using System.Reflection; using GroveGames.BehaviourTree.Collections; using GroveGames.BehaviourTree.Nodes;