Second commit

This commit is contained in:
ThomasCharester committed 2026-09-20 15:26:03 +03:00
commit 36840f3ad4
999 files changed
+61364

No files matched your search

@@ -0,0 +1,54 @@
//
// This file is part of the Tremble package by Tiny Goose.
// Copyright (c) 2024-2026 TinyGoose Ltd., All Rights Reserved.
//
namespace TinyGoose.Tremble.Editor
{
[ManualPage("Entities/Prefabs/Prefab Entities")]
public class PrefabEntitiesPage : ManualPageBase
{
protected override void OnGUI()
{
Text(
"Prefab Entities are 1:1 representations of your Unity prefabs, which can be dropped into a map.",
$"All you have to do is mark up your scripts with '[{FormatAttributeName(typeof(PrefabEntityAttribute))}]' to synchronise properties and more!");
Image("T_Manual_PrefabEntity");
Text("The following properties are available:");
PropertyDescription("category",
"The menu category to show the entity under, for example 'player'.",
$"If omitted, we use the default prefix, '{FgdConsts.PREFAB_PREFIX}'."
);
PropertyDescription("excludePrefab(s)",
"Exclude prefabs with the given name. For example, if your",
"script appears on multiple prefabs 'P_Coin' and 'P_CoinSpecial', and you only",
" want to show 'P_Coin' in TrenchBroom, you can pass 'P_CoinSpecial' in here."
);
PropertyDescription("includePrefab(s)",
"Only include prefabs with the given name. For example, if your",
"script appears on multiple prefabs 'P_Coin' and 'P_CoinSpecial', and you only",
" want to show 'P_Coin' in TrenchBroom, you can pass 'P_Coin' in here."
);
PropertyDescription("onlyVariants",
"Only include variants of this prefab, not the base prefab itself.",
"For example, imagine your game has a 'P_Sign' prefab, which is an empty signpost,",
"but also has Prefab Variants 'P_Sign_Info' and 'P_Sign_QuestionMark' - ticking",
"this box will export those variants but not the base 'P_Sign'."
);
H1("Prefab Entity Wizard");
Text(
"Tremble can guide you through creating the correct attribute code for your entity,",
"to help you get up and running quickly."
);
ActionBar_SingleAction("Build Prefab Entity", () => GoToPage(typeof(PrefabBuilderPage)));
}
}
}
@@ -0,0 +1,10 @@
fileFormatVersion: 2
guid: fdcea6d257154068a23f70d1bdb72b0a
timeCreated: 1723201724
AssetOrigin:
serializedVersion: 1
productId: 277805
packageName: Tremble - Map Importer
packageVersion: 1.11.1
assetPath: Assets/Tremble/Editor/Manual/Pages/Entities/Prefabs/PrefabEntitiesPage.cs
uploadId: 939664
@@ -0,0 +1,40 @@
//
// This file is part of the Tremble package by Tiny Goose.
// Copyright (c) 2024-2026 TinyGoose Ltd., All Rights Reserved.
//
namespace TinyGoose.Tremble.Editor
{
[ManualPage("Entities/Prefabs/Spawnable Prefabs")]
public class SpawnablePrefabEntitiesPage : ManualPageBase
{
protected override void OnGUI()
{
Text(
"Spawnable Prefabs are a quick way to add a single script to ANY prefab in editor, to",
"allow your prefab to be instantiated from TrenchBroom without any code changes.",
"Note that this method does not allow you to set variables on those prefabs!"
);
Image("T_Manual_SpawnablePrefab");
Text(
$"Add a '{nameof(TrembleSpawnablePrefab)}' component to your prefab. This gives you the following",
"options:"
);
PropertyDescription("Category",
"You can supply the 'Category' of prefab here, too - the menu category to",
"show the entity under, for example 'player'. If omitted, we use the prefix defined in",
"the settings (default: 'p')"
);
PropertyDescription("Only Variants",
"Only Variants: Tremble will ignore the base prefab and only export Prefab Variants of",
"the prefab. See the above explanation about 'onlyVariants' for more information."
);
ActionBar_SingleAction("Build Prefab Entity", () => GoToPage(typeof(PrefabBuilderPage)));
}
}
}
@@ -0,0 +1,10 @@
fileFormatVersion: 2
guid: 7a0a012f06324a7e962feefd29e85628
timeCreated: 1723206473
AssetOrigin:
serializedVersion: 1
productId: 277805
packageName: Tremble - Map Importer
packageVersion: 1.11.1
assetPath: Assets/Tremble/Editor/Manual/Pages/Entities/Prefabs/SpawnablePrefabsPage.cs
uploadId: 939664