This commit is contained in:
PC-20230316NUNE\Administrator 2024-02-02 15:38:13 +08:00
parent 877dca3b43
commit 00f56e11c7
228 changed files with 36944 additions and 20084 deletions

View File

@ -26,7 +26,7 @@
<DebugType>full</DebugType> <DebugType>full</DebugType>
<Optimize>false</Optimize> <Optimize>false</Optimize>
<OutputPath>Temp\Bin\Debug\App\</OutputPath> <OutputPath>Temp\Bin\Debug\App\</OutputPath>
<DefineConstants>UNITY_2022_3_16;UNITY_2022_3;UNITY_2022;UNITY_5_3_OR_NEWER;UNITY_5_4_OR_NEWER;UNITY_5_5_OR_NEWER;UNITY_5_6_OR_NEWER;UNITY_2017_1_OR_NEWER;UNITY_2017_2_OR_NEWER;UNITY_2017_3_OR_NEWER;UNITY_2017_4_OR_NEWER;UNITY_2018_1_OR_NEWER;UNITY_2018_2_OR_NEWER;UNITY_2018_3_OR_NEWER;UNITY_2018_4_OR_NEWER;UNITY_2019_1_OR_NEWER;UNITY_2019_2_OR_NEWER;UNITY_2019_3_OR_NEWER;UNITY_2019_4_OR_NEWER;UNITY_2020_1_OR_NEWER;UNITY_2020_2_OR_NEWER;UNITY_2020_3_OR_NEWER;UNITY_2021_1_OR_NEWER;UNITY_2021_2_OR_NEWER;UNITY_2021_3_OR_NEWER;UNITY_2022_1_OR_NEWER;UNITY_2022_2_OR_NEWER;UNITY_2022_3_OR_NEWER;UNITY_INCLUDE_TESTS;ENABLE_AR;ENABLE_AUDIO;ENABLE_CACHING;ENABLE_CLOTH;ENABLE_EVENT_QUEUE;ENABLE_MICROPHONE;ENABLE_MULTIPLE_DISPLAYS;ENABLE_PHYSICS;ENABLE_TEXTURE_STREAMING;ENABLE_LZMA;ENABLE_UNITYEVENTS;ENABLE_VR;ENABLE_WEBCAM;ENABLE_UNITYWEBREQUEST;ENABLE_WWW;ENABLE_CLOUD_SERVICES;ENABLE_CLOUD_SERVICES_ADS;ENABLE_CLOUD_SERVICES_USE_WEBREQUEST;ENABLE_CLOUD_SERVICES_CRASH_REPORTING;ENABLE_CLOUD_SERVICES_NATIVE_CRASH_REPORTING;ENABLE_CLOUD_SERVICES_PURCHASING;ENABLE_CLOUD_SERVICES_ANALYTICS;ENABLE_CLOUD_SERVICES_BUILD;ENABLE_EDITOR_GAME_SERVICES;ENABLE_UNITY_GAME_SERVICES_ANALYTICS_SUPPORT;ENABLE_CLOUD_LICENSE;ENABLE_EDITOR_HUB_LICENSE;ENABLE_WEBSOCKET_CLIENT;ENABLE_GENERATE_NATIVE_PLUGINS_FOR_ASSEMBLIES_API;ENABLE_DIRECTOR_AUDIO;ENABLE_DIRECTOR_TEXTURE;ENABLE_MANAGED_JOBS;ENABLE_MANAGED_TRANSFORM_JOBS;ENABLE_MANAGED_ANIMATION_JOBS;ENABLE_MANAGED_AUDIO_JOBS;ENABLE_RUNTIME_PERMISSIONS;ENABLE_ENGINE_CODE_STRIPPING;ENABLE_ONSCREEN_KEYBOARD;ENABLE_MANAGED_UNITYTLS;INCLUDE_DYNAMIC_GI;ENABLE_SCRIPTING_GC_WBARRIERS;PLATFORM_SUPPORTS_MONO;ENABLE_VIDEO;ENABLE_ACCELERATOR_CLIENT_DEBUGGING;ENABLE_NAVIGATION_PACKAGE_DEBUG_VISUALIZATION;ENABLE_NAVIGATION_HEIGHTMESH_RUNTIME_SUPPORT;ENABLE_NAVIGATION_UI_REQUIRES_PACKAGE;PLATFORM_ANDROID;TEXTCORE_1_0_OR_NEWER;UNITY_ANDROID;UNITY_ANDROID_API;ENABLE_EGL;ENABLE_NETWORK;ENABLE_RUNTIME_GI;ENABLE_CRUNCH_TEXTURE_COMPRESSION;UNITY_CAN_SHOW_SPLASH_SCREEN;UNITY_HAS_GOOGLEVR;UNITY_HAS_TANGO;ENABLE_SPATIALTRACKING;ENABLE_ETC_COMPRESSION;PLATFORM_EXTENDS_VULKAN_DEVICE;PLATFORM_HAS_MULTIPLE_SWAPCHAINS;UNITY_ANDROID_SUPPORTS_SHADOWFILES;PLATFORM_UPDATES_TIME_OUTSIDE_OF_PLAYER_LOOP;ENABLE_UNITYADS_RUNTIME;UNITY_UNITYADS_API;ENABLE_MONO;NET_STANDARD_2_0;NET_STANDARD;NET_STANDARD_2_1;NETSTANDARD;NETSTANDARD2_1;ENABLE_PROFILER;DEBUG;TRACE;UNITY_ASSERTIONS;UNITY_EDITOR;UNITY_EDITOR_64;UNITY_EDITOR_WIN;ENABLE_UNITY_COLLECTIONS_CHECKS;ENABLE_BURST_AOT;UNITY_TEAM_LICENSE;ENABLE_CUSTOM_RENDER_TEXTURE;ENABLE_DIRECTOR;ENABLE_LOCALIZATION;ENABLE_SPRITES;ENABLE_TERRAIN;ENABLE_TILEMAP;ENABLE_TIMELINE;ENABLE_LEGACY_INPUT_MANAGER;TEXTCORE_FONT_ENGINE_1_5_OR_NEWER;UNITY_PHYSICS_CUSTOM;CSHARP_7_OR_LATER;CSHARP_7_3_OR_NEWER</DefineConstants> <DefineConstants>UNITY_2022_3_16;UNITY_2022_3;UNITY_2022;UNITY_5_3_OR_NEWER;UNITY_5_4_OR_NEWER;UNITY_5_5_OR_NEWER;UNITY_5_6_OR_NEWER;UNITY_2017_1_OR_NEWER;UNITY_2017_2_OR_NEWER;UNITY_2017_3_OR_NEWER;UNITY_2017_4_OR_NEWER;UNITY_2018_1_OR_NEWER;UNITY_2018_2_OR_NEWER;UNITY_2018_3_OR_NEWER;UNITY_2018_4_OR_NEWER;UNITY_2019_1_OR_NEWER;UNITY_2019_2_OR_NEWER;UNITY_2019_3_OR_NEWER;UNITY_2019_4_OR_NEWER;UNITY_2020_1_OR_NEWER;UNITY_2020_2_OR_NEWER;UNITY_2020_3_OR_NEWER;UNITY_2021_1_OR_NEWER;UNITY_2021_2_OR_NEWER;UNITY_2021_3_OR_NEWER;UNITY_2022_1_OR_NEWER;UNITY_2022_2_OR_NEWER;UNITY_2022_3_OR_NEWER;PLATFORM_ARCH_64;UNITY_64;UNITY_INCLUDE_TESTS;ENABLE_AR;ENABLE_AUDIO;ENABLE_CACHING;ENABLE_CLOTH;ENABLE_EVENT_QUEUE;ENABLE_MICROPHONE;ENABLE_MULTIPLE_DISPLAYS;ENABLE_PHYSICS;ENABLE_TEXTURE_STREAMING;ENABLE_VIRTUALTEXTURING;ENABLE_LZMA;ENABLE_UNITYEVENTS;ENABLE_VR;ENABLE_WEBCAM;ENABLE_UNITYWEBREQUEST;ENABLE_WWW;ENABLE_CLOUD_SERVICES;ENABLE_CLOUD_SERVICES_ADS;ENABLE_CLOUD_SERVICES_USE_WEBREQUEST;ENABLE_CLOUD_SERVICES_CRASH_REPORTING;ENABLE_CLOUD_SERVICES_PURCHASING;ENABLE_CLOUD_SERVICES_ANALYTICS;ENABLE_CLOUD_SERVICES_BUILD;ENABLE_EDITOR_GAME_SERVICES;ENABLE_UNITY_GAME_SERVICES_ANALYTICS_SUPPORT;ENABLE_CLOUD_LICENSE;ENABLE_EDITOR_HUB_LICENSE;ENABLE_WEBSOCKET_CLIENT;ENABLE_GENERATE_NATIVE_PLUGINS_FOR_ASSEMBLIES_API;ENABLE_DIRECTOR_AUDIO;ENABLE_DIRECTOR_TEXTURE;ENABLE_MANAGED_JOBS;ENABLE_MANAGED_TRANSFORM_JOBS;ENABLE_MANAGED_ANIMATION_JOBS;ENABLE_MANAGED_AUDIO_JOBS;ENABLE_MANAGED_UNITYTLS;INCLUDE_DYNAMIC_GI;ENABLE_SCRIPTING_GC_WBARRIERS;PLATFORM_SUPPORTS_MONO;RENDER_SOFTWARE_CURSOR;ENABLE_VIDEO;ENABLE_ACCELERATOR_CLIENT_DEBUGGING;ENABLE_NAVIGATION_PACKAGE_DEBUG_VISUALIZATION;ENABLE_NAVIGATION_HEIGHTMESH_RUNTIME_SUPPORT;ENABLE_NAVIGATION_UI_REQUIRES_PACKAGE;PLATFORM_STANDALONE;TEXTCORE_1_0_OR_NEWER;PLATFORM_STANDALONE_WIN;UNITY_STANDALONE_WIN;UNITY_STANDALONE;UNITY_UGP_API;ENABLE_RUNTIME_GI;ENABLE_MOVIES;ENABLE_NETWORK;ENABLE_NVIDIA;ENABLE_CRUNCH_TEXTURE_COMPRESSION;ENABLE_OUT_OF_PROCESS_CRASH_HANDLER;ENABLE_CLUSTER_SYNC;ENABLE_CLUSTERINPUT;PLATFORM_UPDATES_TIME_OUTSIDE_OF_PLAYER_LOOP;GFXDEVICE_WAITFOREVENT_MESSAGEPUMP;PLATFORM_INITIALIZES_MEMORY_MANAGER_EXPLICITLY;ENABLE_MONO;NET_STANDARD_2_0;NET_STANDARD;NET_STANDARD_2_1;NETSTANDARD;NETSTANDARD2_1;ENABLE_PROFILER;DEBUG;TRACE;UNITY_ASSERTIONS;UNITY_EDITOR;UNITY_EDITOR_64;UNITY_EDITOR_WIN;ENABLE_UNITY_COLLECTIONS_CHECKS;ENABLE_BURST_AOT;UNITY_TEAM_LICENSE;ENABLE_CUSTOM_RENDER_TEXTURE;ENABLE_DIRECTOR;ENABLE_LOCALIZATION;ENABLE_SPRITES;ENABLE_TERRAIN;ENABLE_TILEMAP;ENABLE_TIMELINE;ENABLE_LEGACY_INPUT_MANAGER;TEXTCORE_FONT_ENGINE_1_5_OR_NEWER;UNITY_PHYSICS_CUSTOM;CSHARP_7_OR_LATER;CSHARP_7_3_OR_NEWER</DefineConstants>
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
<NoWarn>0169,0649</NoWarn> <NoWarn>0169,0649</NoWarn>
@ -47,6 +47,7 @@
<ItemGroup> <ItemGroup>
<Compile Include="Assets\Game\Plugins\App\App.cs" /> <Compile Include="Assets\Game\Plugins\App\App.cs" />
<Compile Include="Assets\Game\Plugins\App\Sync\JNGSyncFrame.cs" /> <Compile Include="Assets\Game\Plugins\App\Sync\JNGSyncFrame.cs" />
<Compile Include="Assets\Game\Plugins\App\Util\JNRandom.cs" />
<Compile Include="Assets\Game\Plugins\App\JNGSyncFrame.cs" /> <Compile Include="Assets\Game\Plugins\App\JNGSyncFrame.cs" />
<Compile Include="Assets\Game\Plugins\App\JNGSocket.cs" /> <Compile Include="Assets\Game\Plugins\App\JNGSocket.cs" />
<Compile Include="Assets\Game\Plugins\App\Sync\JNGSyncFrameDefault.cs" /> <Compile Include="Assets\Game\Plugins\App\Sync\JNGSyncFrameDefault.cs" />
@ -79,6 +80,12 @@
<Reference Include="UnityEngine.ClothModule"> <Reference Include="UnityEngine.ClothModule">
<HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.ClothModule.dll</HintPath> <HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.ClothModule.dll</HintPath>
</Reference> </Reference>
<Reference Include="UnityEngine.ClusterInputModule">
<HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.ClusterInputModule.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.ClusterRendererModule">
<HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.ClusterRendererModule.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.ContentLoadModule"> <Reference Include="UnityEngine.ContentLoadModule">
<HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.ContentLoadModule.dll</HintPath> <HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.ContentLoadModule.dll</HintPath>
</Reference> </Reference>
@ -238,6 +245,9 @@
<Reference Include="UnityEngine.VideoModule"> <Reference Include="UnityEngine.VideoModule">
<HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.VideoModule.dll</HintPath> <HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.VideoModule.dll</HintPath>
</Reference> </Reference>
<Reference Include="UnityEngine.VirtualTexturingModule">
<HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.VirtualTexturingModule.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.WindModule"> <Reference Include="UnityEngine.WindModule">
<HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.WindModule.dll</HintPath> <HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.WindModule.dll</HintPath>
</Reference> </Reference>

View File

@ -26,7 +26,7 @@
<DebugType>full</DebugType> <DebugType>full</DebugType>
<Optimize>false</Optimize> <Optimize>false</Optimize>
<OutputPath>Temp\Bin\Debug\Assembly-CSharp-Editor\</OutputPath> <OutputPath>Temp\Bin\Debug\Assembly-CSharp-Editor\</OutputPath>
<DefineConstants>UNITY_2022_3_16;UNITY_2022_3;UNITY_2022;UNITY_5_3_OR_NEWER;UNITY_5_4_OR_NEWER;UNITY_5_5_OR_NEWER;UNITY_5_6_OR_NEWER;UNITY_2017_1_OR_NEWER;UNITY_2017_2_OR_NEWER;UNITY_2017_3_OR_NEWER;UNITY_2017_4_OR_NEWER;UNITY_2018_1_OR_NEWER;UNITY_2018_2_OR_NEWER;UNITY_2018_3_OR_NEWER;UNITY_2018_4_OR_NEWER;UNITY_2019_1_OR_NEWER;UNITY_2019_2_OR_NEWER;UNITY_2019_3_OR_NEWER;UNITY_2019_4_OR_NEWER;UNITY_2020_1_OR_NEWER;UNITY_2020_2_OR_NEWER;UNITY_2020_3_OR_NEWER;UNITY_2021_1_OR_NEWER;UNITY_2021_2_OR_NEWER;UNITY_2021_3_OR_NEWER;UNITY_2022_1_OR_NEWER;UNITY_2022_2_OR_NEWER;UNITY_2022_3_OR_NEWER;UNITY_INCLUDE_TESTS;ENABLE_AR;ENABLE_AUDIO;ENABLE_CACHING;ENABLE_CLOTH;ENABLE_EVENT_QUEUE;ENABLE_MICROPHONE;ENABLE_MULTIPLE_DISPLAYS;ENABLE_PHYSICS;ENABLE_TEXTURE_STREAMING;ENABLE_LZMA;ENABLE_UNITYEVENTS;ENABLE_VR;ENABLE_WEBCAM;ENABLE_UNITYWEBREQUEST;ENABLE_WWW;ENABLE_CLOUD_SERVICES;ENABLE_CLOUD_SERVICES_ADS;ENABLE_CLOUD_SERVICES_USE_WEBREQUEST;ENABLE_CLOUD_SERVICES_CRASH_REPORTING;ENABLE_CLOUD_SERVICES_NATIVE_CRASH_REPORTING;ENABLE_CLOUD_SERVICES_PURCHASING;ENABLE_CLOUD_SERVICES_ANALYTICS;ENABLE_CLOUD_SERVICES_BUILD;ENABLE_EDITOR_GAME_SERVICES;ENABLE_UNITY_GAME_SERVICES_ANALYTICS_SUPPORT;ENABLE_CLOUD_LICENSE;ENABLE_EDITOR_HUB_LICENSE;ENABLE_WEBSOCKET_CLIENT;ENABLE_GENERATE_NATIVE_PLUGINS_FOR_ASSEMBLIES_API;ENABLE_DIRECTOR_AUDIO;ENABLE_DIRECTOR_TEXTURE;ENABLE_MANAGED_JOBS;ENABLE_MANAGED_TRANSFORM_JOBS;ENABLE_MANAGED_ANIMATION_JOBS;ENABLE_MANAGED_AUDIO_JOBS;ENABLE_RUNTIME_PERMISSIONS;ENABLE_ENGINE_CODE_STRIPPING;ENABLE_ONSCREEN_KEYBOARD;ENABLE_MANAGED_UNITYTLS;INCLUDE_DYNAMIC_GI;ENABLE_SCRIPTING_GC_WBARRIERS;PLATFORM_SUPPORTS_MONO;ENABLE_VIDEO;ENABLE_ACCELERATOR_CLIENT_DEBUGGING;ENABLE_NAVIGATION_PACKAGE_DEBUG_VISUALIZATION;ENABLE_NAVIGATION_HEIGHTMESH_RUNTIME_SUPPORT;ENABLE_NAVIGATION_UI_REQUIRES_PACKAGE;PLATFORM_ANDROID;TEXTCORE_1_0_OR_NEWER;UNITY_ANDROID;UNITY_ANDROID_API;ENABLE_EGL;ENABLE_NETWORK;ENABLE_RUNTIME_GI;ENABLE_CRUNCH_TEXTURE_COMPRESSION;UNITY_CAN_SHOW_SPLASH_SCREEN;UNITY_HAS_GOOGLEVR;UNITY_HAS_TANGO;ENABLE_SPATIALTRACKING;ENABLE_ETC_COMPRESSION;PLATFORM_EXTENDS_VULKAN_DEVICE;PLATFORM_HAS_MULTIPLE_SWAPCHAINS;UNITY_ANDROID_SUPPORTS_SHADOWFILES;PLATFORM_UPDATES_TIME_OUTSIDE_OF_PLAYER_LOOP;ENABLE_UNITYADS_RUNTIME;UNITY_UNITYADS_API;ENABLE_MONO;NET_4_6;NET_UNITY_4_8;ENABLE_PROFILER;DEBUG;TRACE;UNITY_ASSERTIONS;UNITY_EDITOR;UNITY_EDITOR_64;UNITY_EDITOR_WIN;ENABLE_UNITY_COLLECTIONS_CHECKS;ENABLE_BURST_AOT;UNITY_TEAM_LICENSE;ENABLE_CUSTOM_RENDER_TEXTURE;ENABLE_DIRECTOR;ENABLE_LOCALIZATION;ENABLE_SPRITES;ENABLE_TERRAIN;ENABLE_TILEMAP;ENABLE_TIMELINE;ENABLE_LEGACY_INPUT_MANAGER;TEXTCORE_FONT_ENGINE_1_5_OR_NEWER;UNITY_PHYSICS_CUSTOM;CSHARP_7_OR_LATER;CSHARP_7_3_OR_NEWER;UNITY_EDITOR_ONLY_COMPILATION</DefineConstants> <DefineConstants>UNITY_2022_3_16;UNITY_2022_3;UNITY_2022;UNITY_5_3_OR_NEWER;UNITY_5_4_OR_NEWER;UNITY_5_5_OR_NEWER;UNITY_5_6_OR_NEWER;UNITY_2017_1_OR_NEWER;UNITY_2017_2_OR_NEWER;UNITY_2017_3_OR_NEWER;UNITY_2017_4_OR_NEWER;UNITY_2018_1_OR_NEWER;UNITY_2018_2_OR_NEWER;UNITY_2018_3_OR_NEWER;UNITY_2018_4_OR_NEWER;UNITY_2019_1_OR_NEWER;UNITY_2019_2_OR_NEWER;UNITY_2019_3_OR_NEWER;UNITY_2019_4_OR_NEWER;UNITY_2020_1_OR_NEWER;UNITY_2020_2_OR_NEWER;UNITY_2020_3_OR_NEWER;UNITY_2021_1_OR_NEWER;UNITY_2021_2_OR_NEWER;UNITY_2021_3_OR_NEWER;UNITY_2022_1_OR_NEWER;UNITY_2022_2_OR_NEWER;UNITY_2022_3_OR_NEWER;PLATFORM_ARCH_64;UNITY_64;UNITY_INCLUDE_TESTS;ENABLE_AR;ENABLE_AUDIO;ENABLE_CACHING;ENABLE_CLOTH;ENABLE_EVENT_QUEUE;ENABLE_MICROPHONE;ENABLE_MULTIPLE_DISPLAYS;ENABLE_PHYSICS;ENABLE_TEXTURE_STREAMING;ENABLE_VIRTUALTEXTURING;ENABLE_LZMA;ENABLE_UNITYEVENTS;ENABLE_VR;ENABLE_WEBCAM;ENABLE_UNITYWEBREQUEST;ENABLE_WWW;ENABLE_CLOUD_SERVICES;ENABLE_CLOUD_SERVICES_ADS;ENABLE_CLOUD_SERVICES_USE_WEBREQUEST;ENABLE_CLOUD_SERVICES_CRASH_REPORTING;ENABLE_CLOUD_SERVICES_PURCHASING;ENABLE_CLOUD_SERVICES_ANALYTICS;ENABLE_CLOUD_SERVICES_BUILD;ENABLE_EDITOR_GAME_SERVICES;ENABLE_UNITY_GAME_SERVICES_ANALYTICS_SUPPORT;ENABLE_CLOUD_LICENSE;ENABLE_EDITOR_HUB_LICENSE;ENABLE_WEBSOCKET_CLIENT;ENABLE_GENERATE_NATIVE_PLUGINS_FOR_ASSEMBLIES_API;ENABLE_DIRECTOR_AUDIO;ENABLE_DIRECTOR_TEXTURE;ENABLE_MANAGED_JOBS;ENABLE_MANAGED_TRANSFORM_JOBS;ENABLE_MANAGED_ANIMATION_JOBS;ENABLE_MANAGED_AUDIO_JOBS;ENABLE_MANAGED_UNITYTLS;INCLUDE_DYNAMIC_GI;ENABLE_SCRIPTING_GC_WBARRIERS;PLATFORM_SUPPORTS_MONO;RENDER_SOFTWARE_CURSOR;ENABLE_VIDEO;ENABLE_ACCELERATOR_CLIENT_DEBUGGING;ENABLE_NAVIGATION_PACKAGE_DEBUG_VISUALIZATION;ENABLE_NAVIGATION_HEIGHTMESH_RUNTIME_SUPPORT;ENABLE_NAVIGATION_UI_REQUIRES_PACKAGE;PLATFORM_STANDALONE;TEXTCORE_1_0_OR_NEWER;PLATFORM_STANDALONE_WIN;UNITY_STANDALONE_WIN;UNITY_STANDALONE;UNITY_UGP_API;ENABLE_RUNTIME_GI;ENABLE_MOVIES;ENABLE_NETWORK;ENABLE_NVIDIA;ENABLE_CRUNCH_TEXTURE_COMPRESSION;ENABLE_OUT_OF_PROCESS_CRASH_HANDLER;ENABLE_CLUSTER_SYNC;ENABLE_CLUSTERINPUT;PLATFORM_UPDATES_TIME_OUTSIDE_OF_PLAYER_LOOP;GFXDEVICE_WAITFOREVENT_MESSAGEPUMP;PLATFORM_INITIALIZES_MEMORY_MANAGER_EXPLICITLY;ENABLE_MONO;NET_4_6;NET_UNITY_4_8;ENABLE_PROFILER;DEBUG;TRACE;UNITY_ASSERTIONS;UNITY_EDITOR;UNITY_EDITOR_64;UNITY_EDITOR_WIN;ENABLE_UNITY_COLLECTIONS_CHECKS;ENABLE_BURST_AOT;UNITY_TEAM_LICENSE;ENABLE_CUSTOM_RENDER_TEXTURE;ENABLE_DIRECTOR;ENABLE_LOCALIZATION;ENABLE_SPRITES;ENABLE_TERRAIN;ENABLE_TILEMAP;ENABLE_TIMELINE;ENABLE_LEGACY_INPUT_MANAGER;TEXTCORE_FONT_ENGINE_1_5_OR_NEWER;UNITY_PHYSICS_CUSTOM;CSHARP_7_OR_LATER;CSHARP_7_3_OR_NEWER;UNITY_EDITOR_ONLY_COMPILATION</DefineConstants>
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
<NoWarn>0169,0649</NoWarn> <NoWarn>0169,0649</NoWarn>
@ -45,10 +45,7 @@
<Analyzer Include="D:\Unity\2022.3.16f1c1\Editor\Data\Tools\Unity.SourceGenerators\Unity.Properties.SourceGenerator.dll" /> <Analyzer Include="D:\Unity\2022.3.16f1c1\Editor\Data\Tools\Unity.SourceGenerators\Unity.Properties.SourceGenerator.dll" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<Compile Include="Assets\Game\Plugins\AstarPathfindingProject\Legacy\Editor\LegacyAIPathEditor.cs" /> <Compile Include="Assets\Game\Plugins\Unity-Logs-Viewer\Reporter\Editor\ReporterEditor.cs" />
<Compile Include="Assets\Game\Plugins\AstarPathfindingProject\Legacy\Editor\LegacyEditorHelper.cs" />
<Compile Include="Assets\Game\Plugins\AstarPathfindingProject\Legacy\Editor\LegacyRVOControllerEditor.cs" />
<Compile Include="Assets\Game\Plugins\AstarPathfindingProject\Legacy\Editor\LegacyRichAIEditor.cs" />
<Reference Include="UnityEngine"> <Reference Include="UnityEngine">
<HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.dll</HintPath> <HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.dll</HintPath>
</Reference> </Reference>
@ -872,9 +869,9 @@
<Project>{6d8bd378-3e5b-6997-5e5e-288243f0f72b}</Project> <Project>{6d8bd378-3e5b-6997-5e5e-288243f0f72b}</Project>
<Name>UniTask.Addressables</Name> <Name>UniTask.Addressables</Name>
</ProjectReference> </ProjectReference>
<ProjectReference Include="NewAssembly.csproj"> <ProjectReference Include="App.csproj">
<Project>{99ac6bed-aaad-5209-33d3-6f459696a074}</Project> <Project>{86f5a836-c92e-bcf7-bc96-4683fb573cb1}</Project>
<Name>NewAssembly</Name> <Name>App</Name>
</ProjectReference> </ProjectReference>
<ProjectReference Include="UniTask.DOTween.csproj"> <ProjectReference Include="UniTask.DOTween.csproj">
<Project>{99c4c7d2-ca96-1038-95e0-77e225df2b06}</Project> <Project>{99c4c7d2-ca96-1038-95e0-77e225df2b06}</Project>
@ -884,6 +881,10 @@
<Project>{7f60f694-1f75-f2f0-5fde-36ccb7fd82d1}</Project> <Project>{7f60f694-1f75-f2f0-5fde-36ccb7fd82d1}</Project>
<Name>UniTask.Linq</Name> <Name>UniTask.Linq</Name>
</ProjectReference> </ProjectReference>
<ProjectReference Include="AstarPathfindingProject.csproj">
<Project>{01d387ea-c776-81ef-4b5e-bf013e2cd20f}</Project>
<Name>AstarPathfindingProject</Name>
</ProjectReference>
</ItemGroup> </ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it. <!-- To modify your build process, add your task inside one of the targets below and uncomment it.

View File

@ -26,7 +26,7 @@
<DebugType>full</DebugType> <DebugType>full</DebugType>
<Optimize>false</Optimize> <Optimize>false</Optimize>
<OutputPath>Temp\Bin\Debug\Assembly-CSharp\</OutputPath> <OutputPath>Temp\Bin\Debug\Assembly-CSharp\</OutputPath>
<DefineConstants>UNITY_2022_3_16;UNITY_2022_3;UNITY_2022;UNITY_5_3_OR_NEWER;UNITY_5_4_OR_NEWER;UNITY_5_5_OR_NEWER;UNITY_5_6_OR_NEWER;UNITY_2017_1_OR_NEWER;UNITY_2017_2_OR_NEWER;UNITY_2017_3_OR_NEWER;UNITY_2017_4_OR_NEWER;UNITY_2018_1_OR_NEWER;UNITY_2018_2_OR_NEWER;UNITY_2018_3_OR_NEWER;UNITY_2018_4_OR_NEWER;UNITY_2019_1_OR_NEWER;UNITY_2019_2_OR_NEWER;UNITY_2019_3_OR_NEWER;UNITY_2019_4_OR_NEWER;UNITY_2020_1_OR_NEWER;UNITY_2020_2_OR_NEWER;UNITY_2020_3_OR_NEWER;UNITY_2021_1_OR_NEWER;UNITY_2021_2_OR_NEWER;UNITY_2021_3_OR_NEWER;UNITY_2022_1_OR_NEWER;UNITY_2022_2_OR_NEWER;UNITY_2022_3_OR_NEWER;UNITY_INCLUDE_TESTS;ENABLE_AR;ENABLE_AUDIO;ENABLE_CACHING;ENABLE_CLOTH;ENABLE_EVENT_QUEUE;ENABLE_MICROPHONE;ENABLE_MULTIPLE_DISPLAYS;ENABLE_PHYSICS;ENABLE_TEXTURE_STREAMING;ENABLE_LZMA;ENABLE_UNITYEVENTS;ENABLE_VR;ENABLE_WEBCAM;ENABLE_UNITYWEBREQUEST;ENABLE_WWW;ENABLE_CLOUD_SERVICES;ENABLE_CLOUD_SERVICES_ADS;ENABLE_CLOUD_SERVICES_USE_WEBREQUEST;ENABLE_CLOUD_SERVICES_CRASH_REPORTING;ENABLE_CLOUD_SERVICES_NATIVE_CRASH_REPORTING;ENABLE_CLOUD_SERVICES_PURCHASING;ENABLE_CLOUD_SERVICES_ANALYTICS;ENABLE_CLOUD_SERVICES_BUILD;ENABLE_EDITOR_GAME_SERVICES;ENABLE_UNITY_GAME_SERVICES_ANALYTICS_SUPPORT;ENABLE_CLOUD_LICENSE;ENABLE_EDITOR_HUB_LICENSE;ENABLE_WEBSOCKET_CLIENT;ENABLE_GENERATE_NATIVE_PLUGINS_FOR_ASSEMBLIES_API;ENABLE_DIRECTOR_AUDIO;ENABLE_DIRECTOR_TEXTURE;ENABLE_MANAGED_JOBS;ENABLE_MANAGED_TRANSFORM_JOBS;ENABLE_MANAGED_ANIMATION_JOBS;ENABLE_MANAGED_AUDIO_JOBS;ENABLE_RUNTIME_PERMISSIONS;ENABLE_ENGINE_CODE_STRIPPING;ENABLE_ONSCREEN_KEYBOARD;ENABLE_MANAGED_UNITYTLS;INCLUDE_DYNAMIC_GI;ENABLE_SCRIPTING_GC_WBARRIERS;PLATFORM_SUPPORTS_MONO;ENABLE_VIDEO;ENABLE_ACCELERATOR_CLIENT_DEBUGGING;ENABLE_NAVIGATION_PACKAGE_DEBUG_VISUALIZATION;ENABLE_NAVIGATION_HEIGHTMESH_RUNTIME_SUPPORT;ENABLE_NAVIGATION_UI_REQUIRES_PACKAGE;PLATFORM_ANDROID;TEXTCORE_1_0_OR_NEWER;UNITY_ANDROID;UNITY_ANDROID_API;ENABLE_EGL;ENABLE_NETWORK;ENABLE_RUNTIME_GI;ENABLE_CRUNCH_TEXTURE_COMPRESSION;UNITY_CAN_SHOW_SPLASH_SCREEN;UNITY_HAS_GOOGLEVR;UNITY_HAS_TANGO;ENABLE_SPATIALTRACKING;ENABLE_ETC_COMPRESSION;PLATFORM_EXTENDS_VULKAN_DEVICE;PLATFORM_HAS_MULTIPLE_SWAPCHAINS;UNITY_ANDROID_SUPPORTS_SHADOWFILES;PLATFORM_UPDATES_TIME_OUTSIDE_OF_PLAYER_LOOP;ENABLE_UNITYADS_RUNTIME;UNITY_UNITYADS_API;ENABLE_MONO;NET_STANDARD_2_0;NET_STANDARD;NET_STANDARD_2_1;NETSTANDARD;NETSTANDARD2_1;ENABLE_PROFILER;DEBUG;TRACE;UNITY_ASSERTIONS;UNITY_EDITOR;UNITY_EDITOR_64;UNITY_EDITOR_WIN;ENABLE_UNITY_COLLECTIONS_CHECKS;ENABLE_BURST_AOT;UNITY_TEAM_LICENSE;ENABLE_CUSTOM_RENDER_TEXTURE;ENABLE_DIRECTOR;ENABLE_LOCALIZATION;ENABLE_SPRITES;ENABLE_TERRAIN;ENABLE_TILEMAP;ENABLE_TIMELINE;ENABLE_LEGACY_INPUT_MANAGER;TEXTCORE_FONT_ENGINE_1_5_OR_NEWER;UNITY_PHYSICS_CUSTOM;CSHARP_7_OR_LATER;CSHARP_7_3_OR_NEWER</DefineConstants> <DefineConstants>UNITY_2022_3_16;UNITY_2022_3;UNITY_2022;UNITY_5_3_OR_NEWER;UNITY_5_4_OR_NEWER;UNITY_5_5_OR_NEWER;UNITY_5_6_OR_NEWER;UNITY_2017_1_OR_NEWER;UNITY_2017_2_OR_NEWER;UNITY_2017_3_OR_NEWER;UNITY_2017_4_OR_NEWER;UNITY_2018_1_OR_NEWER;UNITY_2018_2_OR_NEWER;UNITY_2018_3_OR_NEWER;UNITY_2018_4_OR_NEWER;UNITY_2019_1_OR_NEWER;UNITY_2019_2_OR_NEWER;UNITY_2019_3_OR_NEWER;UNITY_2019_4_OR_NEWER;UNITY_2020_1_OR_NEWER;UNITY_2020_2_OR_NEWER;UNITY_2020_3_OR_NEWER;UNITY_2021_1_OR_NEWER;UNITY_2021_2_OR_NEWER;UNITY_2021_3_OR_NEWER;UNITY_2022_1_OR_NEWER;UNITY_2022_2_OR_NEWER;UNITY_2022_3_OR_NEWER;PLATFORM_ARCH_64;UNITY_64;UNITY_INCLUDE_TESTS;ENABLE_AR;ENABLE_AUDIO;ENABLE_CACHING;ENABLE_CLOTH;ENABLE_EVENT_QUEUE;ENABLE_MICROPHONE;ENABLE_MULTIPLE_DISPLAYS;ENABLE_PHYSICS;ENABLE_TEXTURE_STREAMING;ENABLE_VIRTUALTEXTURING;ENABLE_LZMA;ENABLE_UNITYEVENTS;ENABLE_VR;ENABLE_WEBCAM;ENABLE_UNITYWEBREQUEST;ENABLE_WWW;ENABLE_CLOUD_SERVICES;ENABLE_CLOUD_SERVICES_ADS;ENABLE_CLOUD_SERVICES_USE_WEBREQUEST;ENABLE_CLOUD_SERVICES_CRASH_REPORTING;ENABLE_CLOUD_SERVICES_PURCHASING;ENABLE_CLOUD_SERVICES_ANALYTICS;ENABLE_CLOUD_SERVICES_BUILD;ENABLE_EDITOR_GAME_SERVICES;ENABLE_UNITY_GAME_SERVICES_ANALYTICS_SUPPORT;ENABLE_CLOUD_LICENSE;ENABLE_EDITOR_HUB_LICENSE;ENABLE_WEBSOCKET_CLIENT;ENABLE_GENERATE_NATIVE_PLUGINS_FOR_ASSEMBLIES_API;ENABLE_DIRECTOR_AUDIO;ENABLE_DIRECTOR_TEXTURE;ENABLE_MANAGED_JOBS;ENABLE_MANAGED_TRANSFORM_JOBS;ENABLE_MANAGED_ANIMATION_JOBS;ENABLE_MANAGED_AUDIO_JOBS;ENABLE_MANAGED_UNITYTLS;INCLUDE_DYNAMIC_GI;ENABLE_SCRIPTING_GC_WBARRIERS;PLATFORM_SUPPORTS_MONO;RENDER_SOFTWARE_CURSOR;ENABLE_VIDEO;ENABLE_ACCELERATOR_CLIENT_DEBUGGING;ENABLE_NAVIGATION_PACKAGE_DEBUG_VISUALIZATION;ENABLE_NAVIGATION_HEIGHTMESH_RUNTIME_SUPPORT;ENABLE_NAVIGATION_UI_REQUIRES_PACKAGE;PLATFORM_STANDALONE;TEXTCORE_1_0_OR_NEWER;PLATFORM_STANDALONE_WIN;UNITY_STANDALONE_WIN;UNITY_STANDALONE;UNITY_UGP_API;ENABLE_RUNTIME_GI;ENABLE_MOVIES;ENABLE_NETWORK;ENABLE_NVIDIA;ENABLE_CRUNCH_TEXTURE_COMPRESSION;ENABLE_OUT_OF_PROCESS_CRASH_HANDLER;ENABLE_CLUSTER_SYNC;ENABLE_CLUSTERINPUT;PLATFORM_UPDATES_TIME_OUTSIDE_OF_PLAYER_LOOP;GFXDEVICE_WAITFOREVENT_MESSAGEPUMP;PLATFORM_INITIALIZES_MEMORY_MANAGER_EXPLICITLY;ENABLE_MONO;NET_STANDARD_2_0;NET_STANDARD;NET_STANDARD_2_1;NETSTANDARD;NETSTANDARD2_1;ENABLE_PROFILER;DEBUG;TRACE;UNITY_ASSERTIONS;UNITY_EDITOR;UNITY_EDITOR_64;UNITY_EDITOR_WIN;ENABLE_UNITY_COLLECTIONS_CHECKS;ENABLE_BURST_AOT;UNITY_TEAM_LICENSE;ENABLE_CUSTOM_RENDER_TEXTURE;ENABLE_DIRECTOR;ENABLE_LOCALIZATION;ENABLE_SPRITES;ENABLE_TERRAIN;ENABLE_TILEMAP;ENABLE_TIMELINE;ENABLE_LEGACY_INPUT_MANAGER;TEXTCORE_FONT_ENGINE_1_5_OR_NEWER;UNITY_PHYSICS_CUSTOM;CSHARP_7_OR_LATER;CSHARP_7_3_OR_NEWER</DefineConstants>
<ErrorReport>prompt</ErrorReport> <ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel> <WarningLevel>4</WarningLevel>
<NoWarn>0169,0649</NoWarn> <NoWarn>0169,0649</NoWarn>
@ -45,9 +45,18 @@
<Analyzer Include="D:\Unity\2022.3.16f1c1\Editor\Data\Tools\Unity.SourceGenerators\Unity.Properties.SourceGenerator.dll" /> <Analyzer Include="D:\Unity\2022.3.16f1c1\Editor\Data\Tools\Unity.SourceGenerators\Unity.Properties.SourceGenerator.dll" />
</ItemGroup> </ItemGroup>
<ItemGroup> <ItemGroup>
<Compile Include="Assets\Game\Plugins\Unity-Logs-Viewer\Reporter\Test\TestReporter.cs" />
<Compile Include="Assets\Game\Plugins\Unity-Logs-Viewer\Reporter\MultiKeyDictionary.cs" />
<Compile Include="Assets\Game\Script\battle\GBaseMode.cs" /> <Compile Include="Assets\Game\Script\battle\GBaseMode.cs" />
<Compile Include="Assets\Game\Script\battle\mode\GWorldSync01ModeScript\PlayerBot.cs" />
<Compile Include="Assets\Game\Plugins\Unity-Logs-Viewer\Reporter\Reporter.cs" />
<Compile Include="Assets\Game\Script\demo\DemoMain.cs" /> <Compile Include="Assets\Game\Script\demo\DemoMain.cs" />
<Compile Include="Assets\Game\Plugins\Unity-Logs-Viewer\Reporter\ReporterMessageReceiver.cs" />
<Compile Include="Assets\Game\Script\battle\mode\GWorldSync01Mode.cs" />
<Compile Include="Assets\Game\Plugins\Unity-Logs-Viewer\Reporter\Test\Rotate.cs" />
<Compile Include="Assets\Game\Script\battle\mode\GWorldSceneMode.cs" /> <Compile Include="Assets\Game\Script\battle\mode\GWorldSceneMode.cs" />
<Compile Include="Assets\Game\Script\battle\mode\GWorldSync01ModeScript\GWorldSync01UI.cs" />
<Compile Include="Assets\Game\Plugins\Unity-Logs-Viewer\Reporter\ReporterGUI.cs" />
<Compile Include="Assets\Game\Script\UIMain.cs" /> <Compile Include="Assets\Game\Script\UIMain.cs" />
<Compile Include="Assets\Game\Script\battle\GBattleModeManager.cs" /> <Compile Include="Assets\Game\Script\battle\GBattleModeManager.cs" />
<Compile Include="Assets\Game\Script\Main.cs" /> <Compile Include="Assets\Game\Script\Main.cs" />
@ -87,6 +96,12 @@
<Reference Include="UnityEngine.ClothModule"> <Reference Include="UnityEngine.ClothModule">
<HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.ClothModule.dll</HintPath> <HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.ClothModule.dll</HintPath>
</Reference> </Reference>
<Reference Include="UnityEngine.ClusterInputModule">
<HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.ClusterInputModule.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.ClusterRendererModule">
<HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.ClusterRendererModule.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.ContentLoadModule"> <Reference Include="UnityEngine.ContentLoadModule">
<HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.ContentLoadModule.dll</HintPath> <HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.ContentLoadModule.dll</HintPath>
</Reference> </Reference>
@ -246,6 +261,9 @@
<Reference Include="UnityEngine.VideoModule"> <Reference Include="UnityEngine.VideoModule">
<HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.VideoModule.dll</HintPath> <HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.VideoModule.dll</HintPath>
</Reference> </Reference>
<Reference Include="UnityEngine.VirtualTexturingModule">
<HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.VirtualTexturingModule.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.WindModule"> <Reference Include="UnityEngine.WindModule">
<HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.WindModule.dll</HintPath> <HintPath>D:\Unity\2022.3.16f1c1\Editor\Data\Managed\UnityEngine\UnityEngine.WindModule.dll</HintPath>
</Reference> </Reference>

View File

@ -1,4 +1,5 @@
using Cysharp.Threading.Tasks; using Cysharp.Threading.Tasks;
using Plugins.JNGame.Network.Action;
using Plugins.JNGame.Sync.Frame; using Plugins.JNGame.Sync.Frame;
using UnityEngine; using UnityEngine;
@ -8,7 +9,8 @@ namespace Game.Plugins.App
{ {
protected override void OnSendInput(JNFrameInputs inputs) protected override void OnSendInput(JNFrameInputs inputs)
{ {
throw new System.NotImplementedException(); //发送帧数据给服务端
App.Socket.Send((int)NActionEnum.NSyncFrameInput,inputs);
} }
protected override async UniTask<JNFrameInfos> OnServerData(int start, int end) protected override async UniTask<JNFrameInfos> OnServerData(int start, int end)

View File

@ -11,6 +11,14 @@ namespace Game.Plugins.App.Sync
} }
public override void OnSyncLoad(){} public override void OnSyncLoad(){}
public override void OnSyncUpdate(int dt, JNFrameInfo frame, T input)
{
}
public override void OnLateSyncUpdate(int dt, JNFrameInfo frame, T input)
{
}
} }
} }

View File

@ -4,8 +4,12 @@ namespace Game.Plugins.App.Sync
{ {
public class JNGSyncFrameDefault : JNGSyncFrame<Object> public class JNGSyncFrameDefault : JNGSyncFrame<Object>
{ {
public override void OnSyncUpdate(int dt, JNFrameInfo frame, Object input) public override void OnSyncUpdate(int dt, JNFrameInfo frame, Object input)
{ {
} }
public override void OnLateSyncUpdate(int dt, JNFrameInfo frame, Object input)
{
}
} }
} }

View File

@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: 5ede0c35f3d54e828355e4f165c228ac
timeCreated: 1706842217

View File

@ -0,0 +1,18 @@
using UnityEngine;
namespace Game.Plugins.App.Util
{
//临时的随机数 因为帧同步不允许随机数 所以临时用固定值代替
public class JNRandom
{
public static float value => 0.5f;
public static float Range(float min,float max)
{
return min + ((max - min) / 2);
}
public static Vector3 onUnitSphere => new Vector3(-0.577844f, 0.327635f, 0.177893f);
}
}

View File

@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: db0a4b2b86334e07a21aa0911a349612
timeCreated: 1706842240

View File

@ -18,22 +18,38 @@ namespace Pathfinding {
public Transform target; public Transform target;
IAstarAI ai; IAstarAI ai;
void OnEnable () { public Vector3 pos;
void OnEnable ()
{
this.pos = this.transform.position;
ai = GetComponent<IAstarAI>(); ai = GetComponent<IAstarAI>();
// Update the destination right before searching for a path as well. // Update the destination right before searching for a path as well.
// This is enough in theory, but this script will also update the destination every // This is enough in theory, but this script will also update the destination every
// frame as the destination is used for debugging and may be used for other things by other // frame as the destination is used for debugging and may be used for other things by other
// scripts as well. So it makes sense that it is up to date every frame. // scripts as well. So it makes sense that it is up to date every frame.
if (ai != null) ai.onSearchPath += Update; if (ai != null) ai.onSearchPath += OnUpdate;
} }
void OnDisable () { void OnDisable () {
if (ai != null) ai.onSearchPath -= Update; if (ai != null) ai.onSearchPath -= OnUpdate;
} }
/// <summary>Updates the AI's destination every frame</summary> /// <summary>Updates the AI's destination every frame</summary>
void Update () { public override void OnSyncUpdate(int dt, JNFrameInfo frame, Object input)
if (target != null && ai != null) ai.destination = target.position; {
base.OnSyncUpdate(dt, frame, input);
this.OnUpdate();
}
public void SetTarget(Vector3 pos)
{
this.pos = pos;
}
public void OnUpdate()
{
if (ai != null) ai.destination = pos;
} }
} }
} }

View File

@ -1,3 +1,4 @@
using Game.Plugins.App.Util;
using Plugins.JNGame.Sync.Frame.Entity; using Plugins.JNGame.Sync.Frame.Entity;
using UnityEngine; using UnityEngine;
@ -110,7 +111,7 @@ namespace Pathfinding {
// Randomize the repath time slightly so that all agents don't request a path at the same time // Randomize the repath time slightly so that all agents don't request a path at the same time
// in the future. This is useful when there are a lot of agents instantiated at exactly the same time. // in the future. This is useful when there are a lot of agents instantiated at exactly the same time.
const float JITTER_AMOUNT = 0.3f; const float JITTER_AMOUNT = 0.3f;
lastRepathTime -= (UnityEngine.Random.value - 0.5f) * JITTER_AMOUNT * (mode == Mode.Dynamic ? maximumPeriod : period); lastRepathTime -= (JNRandom.value - 0.5f) * JITTER_AMOUNT * (mode == Mode.Dynamic ? maximumPeriod : period);
} }
public void DrawGizmos (Vector3 position, float radius) { public void DrawGizmos (Vector3 position, float radius) {

View File

@ -1,5 +1,6 @@
using UnityEngine; using UnityEngine;
using System.Collections.Generic; using System.Collections.Generic;
using Game.Plugins.App.Util;
namespace Pathfinding { namespace Pathfinding {
/// <summary> /// <summary>
@ -195,8 +196,8 @@ namespace Pathfinding {
protected override void Reset () { protected override void Reset () {
base.Reset(); base.Reset();
// Create a new random 64 bit value (62 bit actually because we skip negative numbers, but that's still enough by a huge margin) // Create a new random 64 bit value (62 bit actually because we skip negative numbers, but that's still enough by a huge margin)
var rnd1 = (ulong)Random.Range(0, int.MaxValue); var rnd1 = (ulong)JNRandom.Range(0, int.MaxValue);
var rnd2 = ((ulong)Random.Range(0, int.MaxValue) << 32); var rnd2 = ((ulong)JNRandom.Range(0, int.MaxValue) << 32);
uniqueID = rnd1 | rnd2; uniqueID = rnd1 | rnd2;
usedIDs[uniqueID] = this; usedIDs[uniqueID] = this;

View File

@ -1,5 +1,7 @@
using UnityEngine; using UnityEngine;
using System.Collections.Generic; using System.Collections.Generic;
using Game.Plugins.App.Sync;
using Game.Plugins.App.Util;
using Pathfinding.RVO; using Pathfinding.RVO;
namespace Pathfinding.Examples { namespace Pathfinding.Examples {
@ -19,7 +21,7 @@ namespace Pathfinding.Examples {
/// [Open online documentation to see images] /// [Open online documentation to see images]
/// </summary> /// </summary>
[HelpURL("https://arongranberg.com/astar/documentation/stable/class_pathfinding_1_1_examples_1_1_lightweight_r_v_o.php")] [HelpURL("https://arongranberg.com/astar/documentation/stable/class_pathfinding_1_1_examples_1_1_lightweight_r_v_o.php")]
public class LightweightRVO : MonoBehaviour { public class LightweightRVO : JNGSyncFrameDefault {
/// <summary>Number of agents created at start</summary> /// <summary>Number of agents created at start</summary>
public int agentCount = 100; public int agentCount = 100;
@ -137,7 +139,7 @@ namespace Pathfinding.Examples {
} }
private float uniformDistance (float radius) { private float uniformDistance (float radius) {
float v = Random.value + Random.value; float v = JNRandom.value + JNRandom.value;
if (v > 1) return radius * (2-v); if (v > 1) return radius * (2-v);
else return radius * v; else return radius * v;
@ -157,7 +159,7 @@ namespace Pathfinding.Examples {
float circleRad = Mathf.Sqrt(agentCount * radius * radius * 4 / Mathf.PI) * exampleScale * 0.05f; float circleRad = Mathf.Sqrt(agentCount * radius * radius * 4 / Mathf.PI) * exampleScale * 0.05f;
for (int i = 0; i < agentCount; i++) { for (int i = 0; i < agentCount; i++) {
Vector3 pos = new Vector3(Mathf.Cos(i * Mathf.PI * 2.0f / agentCount), 0, Mathf.Sin(i * Mathf.PI * 2.0f / agentCount)) * circleRad * (1 + Random.value * 0.01f); Vector3 pos = new Vector3(Mathf.Cos(i * Mathf.PI * 2.0f / agentCount), 0, Mathf.Sin(i * Mathf.PI * 2.0f / agentCount)) * circleRad * (1 + JNRandom.value * 0.01f);
IAgent agent = sim.AddAgent(new Vector2(pos.x, pos.z), pos.y); IAgent agent = sim.AddAgent(new Vector2(pos.x, pos.z), pos.y);
agents.Add(agent); agents.Add(agent);
goals.Add(-pos); goals.Add(-pos);
@ -183,8 +185,8 @@ namespace Pathfinding.Examples {
float circleRad = Mathf.Sqrt(agentCount * radius * radius * 4 / Mathf.PI) * exampleScale * 0.05f; float circleRad = Mathf.Sqrt(agentCount * radius * radius * 4 / Mathf.PI) * exampleScale * 0.05f;
for (int i = 0; i < agentCount; i++) { for (int i = 0; i < agentCount; i++) {
float angle = Random.value * Mathf.PI * 2.0f; float angle = JNRandom.value * Mathf.PI * 2.0f;
float targetAngle = Random.value * Mathf.PI * 2.0f; float targetAngle = JNRandom.value * Mathf.PI * 2.0f;
Vector3 pos = new Vector3(Mathf.Cos(angle), 0, Mathf.Sin(angle)) * uniformDistance(circleRad); Vector3 pos = new Vector3(Mathf.Cos(angle), 0, Mathf.Sin(angle)) * uniformDistance(circleRad);
IAgent agent = sim.AddAgent(new Vector2(pos.x, pos.z), pos.y); IAgent agent = sim.AddAgent(new Vector2(pos.x, pos.z), pos.y);
agents.Add(agent); agents.Add(agent);
@ -199,7 +201,7 @@ namespace Pathfinding.Examples {
const int AgentsPerDistance = 10; const int AgentsPerDistance = 10;
for (int i = 0; i < agentCount; i++) { for (int i = 0; i < agentCount; i++) {
float angle = ((i % directions)/(float)directions) * Mathf.PI * 2.0f; float angle = ((i % directions)/(float)directions) * Mathf.PI * 2.0f;
var dist = distanceBetweenGroups * ((i/(directions*AgentsPerDistance) + 1) + 0.3f*Random.value); var dist = distanceBetweenGroups * ((i/(directions*AgentsPerDistance) + 1) + 0.3f*JNRandom.value);
Vector3 pos = new Vector3(Mathf.Cos(angle), 0, Mathf.Sin(angle)) * dist; Vector3 pos = new Vector3(Mathf.Cos(angle), 0, Mathf.Sin(angle)) * dist;
IAgent agent = sim.AddAgent(new Vector2(pos.x, pos.z), pos.y); IAgent agent = sim.AddAgent(new Vector2(pos.x, pos.z), pos.y);
agent.Priority = (i % directions) == 0 ? 1 : 0.01f; agent.Priority = (i % directions) == 0 ? 1 : 0.01f;
@ -255,7 +257,7 @@ namespace Pathfinding.Examples {
// Move agent // Move agent
// This is the responsibility of this script, not the RVO system // This is the responsibility of this script, not the RVO system
Vector2 pos = agent.Position; Vector2 pos = agent.Position;
var deltaPosition = Vector2.ClampMagnitude(agent.CalculatedTargetPoint - pos, agent.CalculatedSpeed * Time.deltaTime); var deltaPosition = Vector2.ClampMagnitude(agent.CalculatedTargetPoint - pos, agent.CalculatedSpeed * GetSync().Time.deltaTime);
pos += deltaPosition; pos += deltaPosition;
agent.Position = pos; agent.Position = pos;
@ -270,7 +272,7 @@ namespace Pathfinding.Examples {
interpolatedVelocities[i] += deltaPosition; interpolatedVelocities[i] += deltaPosition;
if (interpolatedVelocities[i].magnitude > maxSpeed*0.1f) { if (interpolatedVelocities[i].magnitude > maxSpeed*0.1f) {
interpolatedVelocities[i] = Vector2.ClampMagnitude(interpolatedVelocities[i], maxSpeed*0.1f); interpolatedVelocities[i] = Vector2.ClampMagnitude(interpolatedVelocities[i], maxSpeed*0.1f);
interpolatedRotations[i] = Vector2.Lerp(interpolatedRotations[i], interpolatedVelocities[i], agent.CalculatedSpeed * Time.deltaTime*4f); interpolatedRotations[i] = Vector2.Lerp(interpolatedRotations[i], interpolatedVelocities[i], agent.CalculatedSpeed * GetSync().Time.deltaTime*4f);
} }
//Debug.DrawRay(new Vector3(pos.x, 0, pos.y), new Vector3(interpolatedVelocities[i].x, 0, interpolatedVelocities[i].y) * 10); //Debug.DrawRay(new Vector3(pos.x, 0, pos.y), new Vector3(interpolatedVelocities[i].x, 0, interpolatedVelocities[i].y) * 10);

View File

@ -1,5 +1,7 @@
using UnityEngine; using UnityEngine;
using System.Collections.Generic; using System.Collections.Generic;
using Game.Plugins.App.Sync;
using Game.Plugins.App.Util;
using Pathfinding.RVO; using Pathfinding.RVO;
namespace Pathfinding.Examples { namespace Pathfinding.Examples {
@ -16,7 +18,7 @@ namespace Pathfinding.Examples {
[RequireComponent(typeof(RVOController))] [RequireComponent(typeof(RVOController))]
[RequireComponent(typeof(Seeker))] [RequireComponent(typeof(Seeker))]
[HelpURL("https://arongranberg.com/astar/documentation/stable/class_pathfinding_1_1_examples_1_1_r_v_o_example_agent.php")] [HelpURL("https://arongranberg.com/astar/documentation/stable/class_pathfinding_1_1_examples_1_1_r_v_o_example_agent.php")]
public class RVOExampleAgent : MonoBehaviour { public class RVOExampleAgent : JNGSyncFrameDefault {
public float repathRate = 1; public float repathRate = 1;
private float nextRepath = 0; private float nextRepath = 0;
@ -81,7 +83,7 @@ namespace Pathfinding.Examples {
public void RecalculatePath () { public void RecalculatePath () {
canSearchAgain = false; canSearchAgain = false;
nextRepath = Time.time+repathRate*(Random.value+0.5f); nextRepath = GetSync().Time.time+repathRate*(JNRandom.value+0.5f);
seeker.StartPath(transform.position, target, OnPathComplete); seeker.StartPath(transform.position, target, OnPathComplete);
} }
@ -124,7 +126,7 @@ namespace Pathfinding.Examples {
} }
public void Update () { public void Update () {
if (Time.time >= nextRepath && canSearchAgain) { if (GetSync().Time.time >= nextRepath && canSearchAgain) {
RecalculatePath(); RecalculatePath();
} }
@ -169,18 +171,18 @@ namespace Pathfinding.Examples {
// Get a processed movement delta from the rvo controller and move the character. // Get a processed movement delta from the rvo controller and move the character.
// This is based on information from earlier frames. // This is based on information from earlier frames.
var movementDelta = controller.CalculateMovementDelta(Time.deltaTime); var movementDelta = controller.CalculateMovementDelta(GetSync().Time.deltaTime);
pos += movementDelta; pos += movementDelta;
// Rotate the character if the velocity is not extremely small // Rotate the character if the velocity is not extremely small
if (Time.deltaTime > 0 && movementDelta.magnitude / Time.deltaTime > 0.01f) { if (GetSync().Time.deltaTime > 0 && movementDelta.magnitude / GetSync().Time.deltaTime > 0.01f) {
var rot = transform.rotation; var rot = transform.rotation;
var targetRot = Quaternion.LookRotation(movementDelta, controller.To3D(Vector2.zero, 1)); var targetRot = Quaternion.LookRotation(movementDelta, controller.To3D(Vector2.zero, 1));
const float RotationSpeed = 5; const float RotationSpeed = 5;
if (controller.movementPlane == MovementPlane.XY) { if (controller.movementPlane == MovementPlane.XY) {
targetRot = targetRot * Quaternion.Euler(-90, 180, 0); targetRot = targetRot * Quaternion.Euler(-90, 180, 0);
} }
transform.rotation = Quaternion.Slerp(rot, targetRot, Time.deltaTime * RotationSpeed); transform.rotation = Quaternion.Slerp(rot, targetRot, GetSync().Time.deltaTime * RotationSpeed);
} }
if (controller.movementPlane == MovementPlane.XZ) { if (controller.movementPlane == MovementPlane.XZ) {

View File

@ -1,3 +1,4 @@
using Game.Plugins.App.Sync;
using UnityEngine; using UnityEngine;
namespace Pathfinding.Examples { namespace Pathfinding.Examples {
@ -6,7 +7,7 @@ namespace Pathfinding.Examples {
/// Helper script in the example scene called 'Moving'. /// Helper script in the example scene called 'Moving'.
/// </summary> /// </summary>
[HelpURL("https://arongranberg.com/astar/documentation/stable/class_pathfinding_1_1_examples_1_1_bezier_mover.php")] [HelpURL("https://arongranberg.com/astar/documentation/stable/class_pathfinding_1_1_examples_1_1_bezier_mover.php")]
public class BezierMover : MonoBehaviour { public class BezierMover : JNGSyncFrameDefault {
public Transform[] points; public Transform[] points;
public float speed = 1; public float speed = 1;
@ -57,7 +58,7 @@ namespace Pathfinding.Examples {
float mid = (mn+mx)/2; float mid = (mn+mx)/2;
Vector3 p = Evaluate(mid, out var dummy1, out var dummy2, out var dummy3); Vector3 p = Evaluate(mid, out var dummy1, out var dummy2, out var dummy3);
if ((p-transform.position).sqrMagnitude > (speed*Time.deltaTime)*(speed*Time.deltaTime)) { if ((p-transform.position).sqrMagnitude > (speed*GetSync().Time.deltaTime)*(speed*GetSync().Time.deltaTime)) {
mx = mid; mx = mid;
} else { } else {
mn = mid; mn = mid;
@ -68,7 +69,7 @@ namespace Pathfinding.Examples {
transform.position = Evaluate(time, out var derivative, out var dummy, out var curvature); transform.position = Evaluate(time, out var derivative, out var dummy, out var curvature);
averageCurvature = Vector3.Lerp(averageCurvature, curvature, Time.deltaTime); averageCurvature = Vector3.Lerp(averageCurvature, curvature, GetSync().Time.deltaTime);
// Estimate the acceleration at the current point and use it to tilt the object inwards on the curve // Estimate the acceleration at the current point and use it to tilt the object inwards on the curve
var centripetalAcceleration = -Vector3.Cross(derivative.normalized, averageCurvature); var centripetalAcceleration = -Vector3.Cross(derivative.normalized, averageCurvature);

View File

@ -1,13 +1,15 @@
using UnityEngine; using UnityEngine;
using System.Collections; using System.Collections;
using System.Collections.Generic; using System.Collections.Generic;
using Game.Plugins.App.Sync;
using Pathfinding; using Pathfinding;
using Plugins.JNGame.Sync.Frame.Entity;
using UnityEngine.EventSystems; using UnityEngine.EventSystems;
namespace Pathfinding.Examples { namespace Pathfinding.Examples {
/// <summary>Helper script in the example scene 'Turn Based'</summary> /// <summary>Helper script in the example scene 'Turn Based'</summary>
[HelpURL("https://arongranberg.com/astar/documentation/stable/class_pathfinding_1_1_examples_1_1_turn_based_manager.php")] [HelpURL("https://arongranberg.com/astar/documentation/stable/class_pathfinding_1_1_examples_1_1_turn_based_manager.php")]
public class TurnBasedManager : MonoBehaviour { public class TurnBasedManager : JNGSyncFrameDefault {
TurnBasedAI selected; TurnBasedAI selected;
public float movementSpeed; public float movementSpeed;
@ -136,7 +138,7 @@ namespace Pathfinding.Examples {
var interpolatedPoint = AstarSplines.CatmullRom(p0, p1, p2, p3, distanceAlongSegment / segmentLength); var interpolatedPoint = AstarSplines.CatmullRom(p0, p1, p2, p3, distanceAlongSegment / segmentLength);
unit.transform.position = interpolatedPoint; unit.transform.position = interpolatedPoint;
yield return null; yield return null;
distanceAlongSegment += Time.deltaTime * speed; distanceAlongSegment += JNTime.Time.deltaTime * speed;
} }
distanceAlongSegment -= segmentLength; distanceAlongSegment -= segmentLength;

View File

@ -53,7 +53,9 @@ namespace Pathfinding.Examples {
} }
/// <summary>Update is called once per frame</summary> /// <summary>Update is called once per frame</summary>
void Update () { public override void OnSyncUpdate(int dt, JNFrameInfo frame, Object input)
{
base.OnSyncUpdate(dt, frame, input);
var aiBase = ai as AIBase; var aiBase = ai as AIBase;
aiBase.canMove = false; aiBase.canMove = false;
@ -72,8 +74,8 @@ namespace Pathfinding.Examples {
// This is the same calculation that Unity uses for // This is the same calculation that Unity uses for
// Animator.pivotWeight and Animator.pivotPosition // Animator.pivotWeight and Animator.pivotPosition
// but those properties do not work for all animations apparently. // but those properties do not work for all animations apparently.
var footVelocity1 = (leftFootPos - prevFootPos[0]) / Time.deltaTime; var footVelocity1 = (leftFootPos - prevFootPos[0]) / GetSync().Time.deltaTime;
var footVelocity2 = (rightFootPos - prevFootPos[1]) / Time.deltaTime; var footVelocity2 = (rightFootPos - prevFootPos[1]) / GetSync().Time.deltaTime;
float denominator = footVelocity1.magnitude + footVelocity2.magnitude; float denominator = footVelocity1.magnitude + footVelocity2.magnitude;
var pivotWeight = denominator > 0 ? footVelocity1.magnitude / denominator : 0.5f; var pivotWeight = denominator > 0 ? footVelocity1.magnitude / denominator : 0.5f;
prevFootPos[0] = leftFootPos; prevFootPos[0] = leftFootPos;
@ -86,7 +88,7 @@ namespace Pathfinding.Examples {
Vector3 nextPosition; Vector3 nextPosition;
Quaternion nextRotation; Quaternion nextRotation;
ai.MovementUpdate(Time.deltaTime, out nextPosition, out nextRotation); ai.MovementUpdate(GetSync().Time.deltaTime, out nextPosition, out nextRotation);
//var desiredVelocity = (ai.steeringTarget - tr.position).normalized * 2;//ai.desiredVelocity; //var desiredVelocity = (ai.steeringTarget - tr.position).normalized * 2;//ai.desiredVelocity;
var desiredVelocity = ai.desiredVelocity; var desiredVelocity = ai.desiredVelocity;
@ -98,7 +100,7 @@ namespace Pathfinding.Examples {
// Calculate the desired velocity relative to the character (+Z = forward, +X = right) // Calculate the desired velocity relative to the character (+Z = forward, +X = right)
var localDesiredVelocity = tr.InverseTransformDirection(desiredVelocityWithoutGrav); var localDesiredVelocity = tr.InverseTransformDirection(desiredVelocityWithoutGrav);
smoothedVelocity = Vector3.Lerp(smoothedVelocity, localDesiredVelocity, velocitySmoothing > 0 ? Time.deltaTime / velocitySmoothing : 1); smoothedVelocity = Vector3.Lerp(smoothedVelocity, localDesiredVelocity, velocitySmoothing > 0 ? GetSync().Time.deltaTime / velocitySmoothing : 1);
if (smoothedVelocity.magnitude < 0.4f) { if (smoothedVelocity.magnitude < 0.4f) {
smoothedVelocity = smoothedVelocity.normalized * 0.4f; smoothedVelocity = smoothedVelocity.normalized * 0.4f;
} }
@ -116,7 +118,7 @@ namespace Pathfinding.Examples {
} }
// Calculate how much the agent should rotate during this frame // Calculate how much the agent should rotate during this frame
var newRot = RotateTowards(desiredVelocityWithoutGrav, Time.deltaTime * rotationSpeed); var newRot = RotateTowards(desiredVelocityWithoutGrav, GetSync().Time.deltaTime * rotationSpeed);
// Rotate the character around the currently grounded foot to prevent foot sliding // Rotate the character around the currently grounded foot to prevent foot sliding
nextPosition = ai.position; nextPosition = ai.position;
nextRotation = ai.rotation; nextRotation = ai.rotation;
@ -129,7 +131,7 @@ namespace Pathfinding.Examples {
// Use gravity from the movement script, not from animation // Use gravity from the movement script, not from animation
var deltaPos = anim.deltaPosition; var deltaPos = anim.deltaPosition;
deltaPos.y = desiredVelocity.y * Time.deltaTime; deltaPos.y = desiredVelocity.y * GetSync().Time.deltaTime;
nextPosition += deltaPos; nextPosition += deltaPos;
// Call the movement script to perform the final movement // Call the movement script to perform the final movement

View File

@ -1,5 +1,6 @@
using UnityEngine; using UnityEngine;
using System.Collections; using System.Collections;
using Game.Plugins.App.Sync;
namespace Pathfinding.Examples { namespace Pathfinding.Examples {
using Pathfinding.RVO; using Pathfinding.RVO;
@ -13,7 +14,7 @@ namespace Pathfinding.Examples {
/// </summary> /// </summary>
[RequireComponent(typeof(RVOController))] [RequireComponent(typeof(RVOController))]
[HelpURL("https://arongranberg.com/astar/documentation/stable/class_pathfinding_1_1_examples_1_1_manual_r_v_o_agent.php")] [HelpURL("https://arongranberg.com/astar/documentation/stable/class_pathfinding_1_1_examples_1_1_manual_r_v_o_agent.php")]
public class ManualRVOAgent : MonoBehaviour { public class ManualRVOAgent : JNGSyncFrameDefault {
RVOController rvo; RVOController rvo;
public float speed = 1; public float speed = 1;
@ -22,7 +23,9 @@ namespace Pathfinding.Examples {
rvo = GetComponent<RVOController>(); rvo = GetComponent<RVOController>();
} }
void Update () { public override void OnSyncUpdate(int dt, JNFrameInfo frame, Object input)
{
base.OnSyncUpdate(dt, frame, input);
var x = Input.GetAxis("Horizontal"); var x = Input.GetAxis("Horizontal");
var y = Input.GetAxis("Vertical"); var y = Input.GetAxis("Vertical");
@ -30,7 +33,7 @@ namespace Pathfinding.Examples {
// Override the RVOController's velocity. This will disable local avoidance calculations for one simulation step. // Override the RVOController's velocity. This will disable local avoidance calculations for one simulation step.
rvo.velocity = v; rvo.velocity = v;
transform.position += v * Time.deltaTime; transform.position += v * GetSync().Time.deltaTime;
} }
} }
} }

View File

@ -57,7 +57,9 @@ namespace Pathfinding.Examples {
} }
} }
protected void Update () { public override void OnSyncUpdate(int dt, JNFrameInfo frame, Object input)
{
base.OnSyncUpdate(dt, frame, input);
if (ai.reachedEndOfPath) { if (ai.reachedEndOfPath) {
if (!isAtDestination) OnTargetReached(); if (!isAtDestination) OnTargetReached();
isAtDestination = true; isAtDestination = true;

View File

@ -1,10 +1,11 @@
using UnityEngine; using UnityEngine;
using System.Collections; using System.Collections;
using Game.Plugins.App.Sync;
namespace Pathfinding.Examples { namespace Pathfinding.Examples {
/// <summary>Small sample script for placing obstacles</summary> /// <summary>Small sample script for placing obstacles</summary>
[HelpURL("https://arongranberg.com/astar/documentation/stable/class_pathfinding_1_1_examples_1_1_object_placer.php")] [HelpURL("https://arongranberg.com/astar/documentation/stable/class_pathfinding_1_1_examples_1_1_object_placer.php")]
public class ObjectPlacer : MonoBehaviour { public class ObjectPlacer : JNGSyncFrameDefault {
/// <summary> /// <summary>
/// GameObject to place. /// GameObject to place.
/// When using a Grid Graph you need to make sure the object's layer is included in the collision mask in the GridGraph settings. /// When using a Grid Graph you need to make sure the object's layer is included in the collision mask in the GridGraph settings.
@ -19,11 +20,12 @@ namespace Pathfinding.Examples {
float lastPlacedTime; float lastPlacedTime;
/// <summary>Update is called once per frame</summary> public override void OnSyncUpdate(int dt, JNFrameInfo frame, Object input)
void Update () { {
base.OnSyncUpdate(dt, frame, input);
// Check if P is being pressed. // Check if P is being pressed.
// Don't place objects if ctrl is pressed to avoid conflicts with the pause shortcut (ctrl+shift+P) // Don't place objects if ctrl is pressed to avoid conflicts with the pause shortcut (ctrl+shift+P)
if (!Input.GetKey(KeyCode.LeftControl) && (Input.GetKeyDown("p") || (Input.GetKey("p") && Time.time - lastPlacedTime > 0.3f))) { if (!Input.GetKey(KeyCode.LeftControl) && (Input.GetKeyDown("p") || (Input.GetKey("p") && GetSync().Time.time - lastPlacedTime > 0.3f))) {
PlaceObject(); PlaceObject();
} }
@ -33,7 +35,7 @@ namespace Pathfinding.Examples {
} }
public void PlaceObject () { public void PlaceObject () {
lastPlacedTime = Time.time; lastPlacedTime = GetSync().Time.time;
Ray ray = Camera.main.ScreenPointToRay(Input.mousePosition); Ray ray = Camera.main.ScreenPointToRay(Input.mousePosition);
RaycastHit hit; RaycastHit hit;

View File

@ -1,3 +1,4 @@
using Game.Plugins.App.Sync;
using UnityEngine; using UnityEngine;
namespace Pathfinding { namespace Pathfinding {
@ -43,7 +44,7 @@ namespace Pathfinding {
/// </summary> /// </summary>
[AddComponentMenu("Pathfinding/Navmesh/RecastTileUpdateHandler")] [AddComponentMenu("Pathfinding/Navmesh/RecastTileUpdateHandler")]
[HelpURL("https://arongranberg.com/astar/documentation/stable/class_pathfinding_1_1_recast_tile_update_handler.php")] [HelpURL("https://arongranberg.com/astar/documentation/stable/class_pathfinding_1_1_recast_tile_update_handler.php")]
public class RecastTileUpdateHandler : MonoBehaviour { public class RecastTileUpdateHandler : JNGSyncFrameDefault {
/// <summary>Graph that handles the updates</summary> /// <summary>Graph that handles the updates</summary>
RecastGraph graph; RecastGraph graph;
@ -96,7 +97,7 @@ namespace Pathfinding {
if (touching.Width * touching.Height > 0) { if (touching.Width * touching.Height > 0) {
if (!anyDirtyTiles) { if (!anyDirtyTiles) {
earliestDirty = Time.time; earliestDirty = GetSync().Time.time;
anyDirtyTiles = true; anyDirtyTiles = true;
} }
@ -116,8 +117,10 @@ namespace Pathfinding {
RecastTileUpdate.OnNeedUpdates -= ScheduleUpdate; RecastTileUpdate.OnNeedUpdates -= ScheduleUpdate;
} }
void Update () { public override void OnSyncUpdate(int dt, JNFrameInfo frame, Object input)
if (anyDirtyTiles && Time.time - earliestDirty >= maxThrottlingDelay && graph != null) { {
base.OnSyncUpdate(dt, frame, input);
if (anyDirtyTiles && GetSync().Time.time - earliestDirty >= maxThrottlingDelay && graph != null) {
UpdateDirtyTiles(); UpdateDirtyTiles();
} }
} }

View File

@ -15,7 +15,9 @@ namespace Pathfinding.Examples {
public float rotationDamping = 10.0f; public float rotationDamping = 10.0f;
public bool staticOffset = false; public bool staticOffset = false;
void LateUpdate () { public override void OnLateSyncUpdate(int dt, JNFrameInfo frame, Object input)
{
base.OnLateSyncUpdate(dt, frame, input);
Vector3 wantedPosition; Vector3 wantedPosition;
if (staticOffset) { if (staticOffset) {
@ -23,12 +25,12 @@ namespace Pathfinding.Examples {
} else { } else {
wantedPosition = target.TransformPoint(0, height, -distance); wantedPosition = target.TransformPoint(0, height, -distance);
} }
transform.position = Vector3.Lerp(transform.position, wantedPosition, Time.deltaTime * damping); transform.position = Vector3.Lerp(transform.position, wantedPosition, GetSync().Time.deltaTime * damping);
if (enableRotation) { if (enableRotation) {
if (smoothRotation) { if (smoothRotation) {
Quaternion wantedRotation = Quaternion.LookRotation(target.position - transform.position, target.up); Quaternion wantedRotation = Quaternion.LookRotation(target.position - transform.position, target.up);
transform.rotation = Quaternion.Slerp(transform.rotation, wantedRotation, Time.deltaTime * rotationDamping); transform.rotation = Quaternion.Slerp(transform.rotation, wantedRotation, GetSync().Time.deltaTime * rotationDamping);
} else transform.LookAt(target, target.up); } else transform.LookAt(target, target.up);
} }
} }

View File

@ -1,5 +1,6 @@
using UnityEngine; using UnityEngine;
using System.Linq; using System.Linq;
using Game.Plugins.App.Sync;
namespace Pathfinding { namespace Pathfinding {
/// <summary> /// <summary>
@ -11,7 +12,7 @@ namespace Pathfinding {
/// It is not meant to be pretty, but it does the job. /// It is not meant to be pretty, but it does the job.
/// </summary> /// </summary>
[HelpURL("https://arongranberg.com/astar/documentation/stable/class_pathfinding_1_1_target_mover.php")] [HelpURL("https://arongranberg.com/astar/documentation/stable/class_pathfinding_1_1_target_mover.php")]
public class TargetMover : MonoBehaviour { public class TargetMover : JNGSyncFrameDefault {
/// <summary>Mask for the raycast placement</summary> /// <summary>Mask for the raycast placement</summary>
public LayerMask mask; public LayerMask mask;

View File

@ -1,4 +1,5 @@
using Game.Plugins.App.Util;
using UnityEngine; using UnityEngine;
using Pathfinding.Serialization; using Pathfinding.Serialization;
@ -189,7 +190,7 @@ namespace Pathfinding {
var graphSpacePosition = gg.transform.InverseTransform((Vector3)position); var graphSpacePosition = gg.transform.InverseTransform((Vector3)position);
return gg.transform.Transform(graphSpacePosition + new Vector3(Random.value - 0.5f, 0, Random.value - 0.5f)); return gg.transform.Transform(graphSpacePosition + new Vector3(JNRandom.value - 0.5f, 0, JNRandom.value - 0.5f));
} }
/// <summary> /// <summary>

View File

@ -1,3 +1,4 @@
using Game.Plugins.App.Util;
using UnityEngine; using UnityEngine;
using Pathfinding.Serialization; using Pathfinding.Serialization;
@ -451,8 +452,8 @@ namespace Pathfinding {
float r2; float r2;
do { do {
r1 = Random.value; r1 = JNRandom.value;
r2 = Random.value; r2 = JNRandom.value;
} while (r1+r2 > 1); } while (r1+r2 > 1);
var holder = GetNavmeshHolder(GraphIndex); var holder = GetNavmeshHolder(GraphIndex);

View File

@ -1,5 +1,7 @@
using UnityEngine; using UnityEngine;
using System.Collections.Generic; using System.Collections.Generic;
using Game.Plugins.App.Sync;
using Plugins.JNGame.Sync.Frame.Entity;
namespace Pathfinding { namespace Pathfinding {
/// <summary> /// <summary>
@ -24,7 +26,7 @@ namespace Pathfinding {
/// </summary> /// </summary>
[AddComponentMenu("Pathfinding/Navmesh/RecastMeshObj")] [AddComponentMenu("Pathfinding/Navmesh/RecastMeshObj")]
[HelpURL("https://arongranberg.com/astar/documentation/stable/class_pathfinding_1_1_recast_mesh_obj.php")] [HelpURL("https://arongranberg.com/astar/documentation/stable/class_pathfinding_1_1_recast_mesh_obj.php")]
public class RecastMeshObj : VersionedMonoBehaviour { public class RecastMeshObj : JNGSyncFrameDefault {
/// <summary>Static objects are stored in a tree for fast bounds lookups</summary> /// <summary>Static objects are stored in a tree for fast bounds lookups</summary>
protected static RecastBBTree tree = new RecastBBTree(); protected static RecastBBTree tree = new RecastBBTree();
@ -42,7 +44,7 @@ namespace Pathfinding {
} }
} }
return; return;
} else if (Time.timeSinceLevelLoad == 0) { } else if (JNTime.Time.timeSinceLevelLoad == 0) {
// Is is not guaranteed that all RecastMeshObj OnEnable functions have been called, so if it is the first frame since loading a new level // Is is not guaranteed that all RecastMeshObj OnEnable functions have been called, so if it is the first frame since loading a new level
// try to initialize all RecastMeshObj objects. // try to initialize all RecastMeshObj objects.
var objs = FindObjectsOfType(typeof(RecastMeshObj)) as RecastMeshObj[]; var objs = FindObjectsOfType(typeof(RecastMeshObj)) as RecastMeshObj[];

View File

@ -721,7 +721,7 @@ namespace Pathfinding.Voxels {
} }
#if ASTARDEBUG #if ASTARDEBUG
Color col = new Color(Random.value, Random.value, Random.value); Color col = new Color(JNRandom.value, JNRandom.value, JNRandom.value);
for (int q = 0, j = (verts.Count/4)-1; q < (verts.Count/4); j = q, q++) { for (int q = 0, j = (verts.Count/4)-1; q < (verts.Count/4); j = q, q++) {
int i4 = q*4; int i4 = q*4;

View File

@ -118,7 +118,7 @@ namespace Pathfinding.Legacy {
// gets confused because the first point in the path is far away // gets confused because the first point in the path is far away
// from the current position (possibly behind it which could cause // from the current position (possibly behind it which could cause
// the agent to turn around, and that looks pretty bad). // the agent to turn around, and that looks pretty bad).
Vector3 p1 = Time.time - lastFoundWaypointTime < 0.3f ? lastFoundWaypointPosition : p.originalStartPoint; Vector3 p1 = GetSync().Time.time - lastFoundWaypointTime < 0.3f ? lastFoundWaypointPosition : p.originalStartPoint;
Vector3 p2 = GetFeetPosition(); Vector3 p2 = GetFeetPosition();
Vector3 dir = p2-p1; Vector3 dir = p2-p1;
float magn = dir.magnitude; float magn = dir.magnitude;
@ -154,7 +154,7 @@ namespace Pathfinding.Legacy {
} else if (rigid != null) { } else if (rigid != null) {
rigid.AddForce(dir); rigid.AddForce(dir);
} else { } else {
tr.Translate(dir*Time.deltaTime, Space.World); tr.Translate(dir*GetSync().Time.deltaTime, Space.World);
} }
} }
@ -204,7 +204,7 @@ namespace Pathfinding.Legacy {
//Mathfx.DistancePointSegmentStrict (vPath[currentWaypointIndex+1],vPath[currentWaypointIndex+2],currentPosition); //Mathfx.DistancePointSegmentStrict (vPath[currentWaypointIndex+1],vPath[currentWaypointIndex+2],currentPosition);
if (dist < pickNextWaypointDist*pickNextWaypointDist) { if (dist < pickNextWaypointDist*pickNextWaypointDist) {
lastFoundWaypointPosition = currentPosition; lastFoundWaypointPosition = currentPosition;
lastFoundWaypointTime = Time.time; lastFoundWaypointTime = GetSync().Time.time;
currentWaypointIndex++; currentWaypointIndex++;
} else { } else {
break; break;
@ -245,8 +245,8 @@ namespace Pathfinding.Legacy {
Debug.DrawRay(GetFeetPosition(), forward*sp, Color.cyan); Debug.DrawRay(GetFeetPosition(), forward*sp, Color.cyan);
#endif #endif
if (Time.deltaTime > 0) { if (GetSync().Time.deltaTime > 0) {
sp = Mathf.Clamp(sp, 0, targetDist/(Time.deltaTime*2)); sp = Mathf.Clamp(sp, 0, targetDist/(GetSync().Time.deltaTime*2));
} }
return forward*sp; return forward*sp;
@ -263,7 +263,7 @@ namespace Pathfinding.Legacy {
Quaternion rot = tr.rotation; Quaternion rot = tr.rotation;
Quaternion toTarget = Quaternion.LookRotation(dir); Quaternion toTarget = Quaternion.LookRotation(dir);
rot = Quaternion.Slerp(rot, toTarget, turningSpeed*Time.deltaTime); rot = Quaternion.Slerp(rot, toTarget, turningSpeed*GetSync().Time.deltaTime);
Vector3 euler = rot.eulerAngles; Vector3 euler = rot.eulerAngles;
euler.z = 0; euler.z = 0;
euler.x = 0; euler.x = 0;

View File

@ -34,12 +34,14 @@ namespace Pathfinding.Legacy {
public new bool enableRotation = true; public new bool enableRotation = true;
public new float rotationSpeed = 30; public new float rotationSpeed = 30;
public void Update () { public override void OnSyncUpdate(int dt, JNFrameInfo frame, Object input)
{
base.OnSyncUpdate(dt, frame, input);
if (rvoAgent == null) return; if (rvoAgent == null) return;
RaycastHit hit; RaycastHit hit;
Vector3 pos = tr.position + CalculateMovementDelta(Time.deltaTime); Vector3 pos = tr.position + CalculateMovementDelta(GetSync().Time.deltaTime);
if (mask != 0 && Physics.Raycast(pos + Vector3.up*height*0.5f, Vector3.down, out hit, float.PositiveInfinity, mask)) { if (mask != 0 && Physics.Raycast(pos + Vector3.up*height*0.5f, Vector3.down, out hit, float.PositiveInfinity, mask)) {
pos.y = hit.point.y; pos.y = hit.point.y;
@ -49,7 +51,9 @@ namespace Pathfinding.Legacy {
tr.position = pos + Vector3.up*(height*0.5f - center); tr.position = pos + Vector3.up*(height*0.5f - center);
if (enableRotation && velocity != Vector3.zero) transform.rotation = Quaternion.Lerp(transform.rotation, Quaternion.LookRotation(velocity), Time.deltaTime * rotationSpeed * Mathf.Min(velocity.magnitude, 0.2f)); if (enableRotation && velocity != Vector3.zero) transform.rotation = Quaternion.Lerp(transform.rotation, Quaternion.LookRotation(velocity), GetSync().Time.deltaTime * rotationSpeed * Mathf.Min(velocity.magnitude, 0.2f));
} }
} }
} }

View File

@ -47,7 +47,7 @@ namespace Pathfinding.Legacy {
public override void OnSyncUpdate(int dt, JNFrameInfo frame, Object input) public override void OnSyncUpdate(int dt, JNFrameInfo frame, Object input)
{ {
base.OnSyncUpdate(dt, frame, input); base.OnSyncUpdate(dt, frame, input);
deltaTime = Mathf.Min(Time.smoothDeltaTime*2, Time.deltaTime); deltaTime = Mathf.Min(GetSync().Time.smoothDeltaTime*2, GetSync().Time.deltaTime);
if (richPath != null) { if (richPath != null) {
//System.Diagnostics.Stopwatch w = new System.Diagnostics.Stopwatch(); //System.Diagnostics.Stopwatch w = new System.Diagnostics.Stopwatch();
@ -61,7 +61,7 @@ namespace Pathfinding.Legacy {
//tr.position = ps; //tr.position = ps;
//Only get walls every 5th frame to save on performance //Only get walls every 5th frame to save on performance
if (Time.frameCount % 5 == 0 && wallForce > 0 && wallDist > 0) { if (GetSync().Time.frameCount % 5 == 0 && wallForce > 0 && wallDist > 0) {
wallBuffer.Clear(); wallBuffer.Clear();
fn.FindWalls(wallBuffer, wallDist); fn.FindWalls(wallBuffer, wallDist);
} }
@ -255,7 +255,7 @@ namespace Pathfinding.Legacy {
} }
UpdateVelocity(); UpdateVelocity();
lastDeltaTime = Time.deltaTime; lastDeltaTime = GetSync().Time.deltaTime;
} }
/// <summary>Update is called once per frame</summary> /// <summary>Update is called once per frame</summary>

View File

@ -2,6 +2,7 @@ using UnityEngine;
using System.Collections.Generic; using System.Collections.Generic;
using Pathfinding.Util; using Pathfinding.Util;
using Pathfinding.Serialization; using Pathfinding.Serialization;
using Plugins.JNGame.Sync.Frame.Entity;
using UnityEngine.Profiling; using UnityEngine.Profiling;
namespace Pathfinding { namespace Pathfinding {
@ -176,7 +177,7 @@ namespace Pathfinding {
} }
} }
if ((updateInterval >= 0 && Time.realtimeSinceStartup - lastUpdateTime > updateInterval) || anyInvalidHandlers) { if ((updateInterval >= 0 && JNTime.Time.realtimeSinceStartup - lastUpdateTime > updateInterval) || anyInvalidHandlers) {
ForceUpdate(); ForceUpdate();
} }
Profiler.EndSample(); Profiler.EndSample();
@ -200,7 +201,7 @@ namespace Pathfinding {
/// </code> /// </code>
/// </summary> /// </summary>
public void ForceUpdate () { public void ForceUpdate () {
lastUpdateTime = Time.realtimeSinceStartup; lastUpdateTime = JNTime.Time.realtimeSinceStartup;
List<NavmeshClipper> hasBeenUpdated = null; List<NavmeshClipper> hasBeenUpdated = null;

View File

@ -1,5 +1,6 @@
using UnityEngine; using UnityEngine;
using System.Collections.Generic; using System.Collections.Generic;
using Plugins.JNGame.Sync.Frame.Entity;
using UnityEditor; using UnityEditor;
namespace Pathfinding { namespace Pathfinding {
@ -55,7 +56,7 @@ namespace Pathfinding {
void Tick () { void Tick () {
if (Event.current.type == EventType.Repaint) { if (Event.current.type == EventType.Repaint) {
float deltaTime = Time.realtimeSinceStartup-lastUpdate; float deltaTime = JNTime.Time.realtimeSinceStartup-lastUpdate;
// Right at the start of a transition the deltaTime will // Right at the start of a transition the deltaTime will
// not be reliable, so use a very small value instead // not be reliable, so use a very small value instead
@ -66,7 +67,7 @@ namespace Pathfinding {
// Larger regions fade slightly slower // Larger regions fade slightly slower
deltaTime /= Mathf.Sqrt(Mathf.Max(lastRect.height, 100)); deltaTime /= Mathf.Sqrt(Mathf.Max(lastRect.height, 100));
lastUpdate = Time.realtimeSinceStartup; lastUpdate = JNTime.Time.realtimeSinceStartup;
float targetValue = open ? 1F : 0F; float targetValue = open ? 1F : 0F;

View File

@ -23,7 +23,7 @@ namespace Pathfinding.RVO {
/// // Calculate how much to move during this frame /// // Calculate how much to move during this frame
/// // This information is based on movement commands from earlier frames /// // This information is based on movement commands from earlier frames
/// // as local avoidance is calculated globally at regular intervals by the RVOSimulator component /// // as local avoidance is calculated globally at regular intervals by the RVOSimulator component
/// var delta = controller.CalculateMovementDelta(transform.position, Time.deltaTime); /// var delta = controller.CalculateMovementDelta(transform.position, GetSync().Time.deltaTime);
/// transform.position = transform.position + delta; /// transform.position = transform.position + delta;
/// } /// }
/// </code> /// </code>
@ -264,10 +264,10 @@ namespace Pathfinding.RVO {
/// </summary> /// </summary>
public Vector3 velocity { public Vector3 velocity {
get { get {
// For best accuracy and to allow other code to do things like Move(agent.velocity * Time.deltaTime) // For best accuracy and to allow other code to do things like Move(agent.velocity * GetSync().Time.deltaTime)
// the code bases the velocity on how far the agent should move during this frame. // the code bases the velocity on how far the agent should move during this frame.
// Unless the game is paused (timescale is zero) then just use a very small dt. // Unless the game is paused (timescale is zero) then just use a very small dt.
var dt = Time.deltaTime > 0.0001f ? Time.deltaTime : 0.02f; var dt = GetSync().Time.deltaTime > 0.0001f ? GetSync().Time.deltaTime : 0.02f;
return CalculateMovementDelta(dt) / dt; return CalculateMovementDelta(dt) / dt;
} }
set { set {
@ -281,7 +281,7 @@ namespace Pathfinding.RVO {
/// The position of the agent is taken from the attached movement script's position (see <see cref="Pathfinding.IAstarAI.position)"/> or if none is attached then transform.position. /// The position of the agent is taken from the attached movement script's position (see <see cref="Pathfinding.IAstarAI.position)"/> or if none is attached then transform.position.
/// </summary> /// </summary>
/// <param name="deltaTime">How far to move [seconds]. /// <param name="deltaTime">How far to move [seconds].
/// Usually set to Time.deltaTime.</param> /// Usually set to GetSync().Time.deltaTime.</param>
public Vector3 CalculateMovementDelta (float deltaTime) { public Vector3 CalculateMovementDelta (float deltaTime) {
if (rvoAgent == null) return Vector3.zero; if (rvoAgent == null) return Vector3.zero;
return To3D(Vector2.ClampMagnitude(rvoAgent.CalculatedTargetPoint - To2D(ai != null ? ai.position : tr.position), rvoAgent.CalculatedSpeed * deltaTime), 0); return To3D(Vector2.ClampMagnitude(rvoAgent.CalculatedTargetPoint - To2D(ai != null ? ai.position : tr.position), rvoAgent.CalculatedSpeed * deltaTime), 0);
@ -308,7 +308,7 @@ namespace Pathfinding.RVO {
/// </summary> /// </summary>
/// <param name="position">Position of the agent.</param> /// <param name="position">Position of the agent.</param>
/// <param name="deltaTime">How far to move [seconds]. /// <param name="deltaTime">How far to move [seconds].
/// Usually set to Time.deltaTime.</param> /// Usually set to GetSync().Time.deltaTime.</param>
public Vector3 CalculateMovementDelta (Vector3 position, float deltaTime) { public Vector3 CalculateMovementDelta (Vector3 position, float deltaTime) {
return To3D(Vector2.ClampMagnitude(rvoAgent.CalculatedTargetPoint - To2D(position), rvoAgent.CalculatedSpeed * deltaTime), 0); return To3D(Vector2.ClampMagnitude(rvoAgent.CalculatedTargetPoint - To2D(position), rvoAgent.CalculatedSpeed * deltaTime), 0);
} }

View File

@ -38,7 +38,7 @@ namespace Pathfinding.Examples {
// Rotate character to face the correct direction // Rotate character to face the correct direction
while (true) { while (true) {
var origRotation = ai.rotation; var origRotation = ai.rotation;
var finalRotation = ai.SimulateRotationTowards(rs.first.forward, ai.rotationSpeed * Time.deltaTime); var finalRotation = ai.SimulateRotationTowards(rs.first.forward, ai.rotationSpeed * GetSync().Time.deltaTime);
// Rotate until the rotation does not change anymore // Rotate until the rotation does not change anymore
if (origRotation == finalRotation) break; if (origRotation == finalRotation) break;
ai.FinalizeMovement(ai.position, finalRotation); ai.FinalizeMovement(ai.position, finalRotation);

View File

@ -42,7 +42,7 @@ namespace Pathfinding {
/// If AstarPath.batchGraphUpdates is enabled, it is not beneficial to have a checkTime much lower /// If AstarPath.batchGraphUpdates is enabled, it is not beneficial to have a checkTime much lower
/// than AstarPath.graphUpdateBatchingInterval because that will just add extra unnecessary graph updates. /// than AstarPath.graphUpdateBatchingInterval because that will just add extra unnecessary graph updates.
/// ///
/// In real time seconds (based on Time.realtimeSinceStartup). /// In real time seconds (based on GetSync().Time.realtimeSinceStartup).
/// </summary> /// </summary>
public float checkTime = 0.2F; public float checkTime = 0.2F;
@ -105,7 +105,9 @@ namespace Pathfinding {
if (coll != null) prevEnabled = colliderEnabled; if (coll != null) prevEnabled = colliderEnabled;
} }
void Update () { public override void OnSyncUpdate(int dt, JNFrameInfo frame, Object input)
{
base.OnSyncUpdate(dt, frame, input);
if (!Application.isPlaying) return; if (!Application.isPlaying) return;
if (coll == null && coll2D == null) { if (coll == null && coll2D == null) {
@ -121,11 +123,11 @@ namespace Pathfinding {
pendingGraphUpdates.Dequeue(); pendingGraphUpdates.Dequeue();
} }
if (AstarPath.active == null || AstarPath.active.isScanning || Time.realtimeSinceStartup - lastCheckTime < checkTime || !Application.isPlaying || pendingGraphUpdates.Count > 0) { if (AstarPath.active == null || AstarPath.active.isScanning || GetSync().Time.realtimeSinceStartup - lastCheckTime < checkTime || !Application.isPlaying || pendingGraphUpdates.Count > 0) {
return; return;
} }
lastCheckTime = Time.realtimeSinceStartup; lastCheckTime = GetSync().Time.realtimeSinceStartup;
if (colliderEnabled) { if (colliderEnabled) {
// The current bounds of the collider // The current bounds of the collider
Bounds newBounds = bounds; Bounds newBounds = bounds;
@ -141,7 +143,7 @@ namespace Pathfinding {
// If the difference between the previous bounds and the new bounds is greater than some value, update the graphs // If the difference between the previous bounds and the new bounds is greater than some value, update the graphs
if (minDiff.sqrMagnitude > updateError*updateError || maxDiff.sqrMagnitude > updateError*updateError || if (minDiff.sqrMagnitude > updateError*updateError || maxDiff.sqrMagnitude > updateError*updateError ||
errorFromRotation > updateError || !prevEnabled) { errorFromRotation > updateError || !prevEnabled) {
// Update the graphs as soon as possible // Update the graphs as soon as possible
DoUpdateGraphs(); DoUpdateGraphs();
} }
@ -225,7 +227,7 @@ namespace Pathfinding {
prevRotation = tr.rotation; prevRotation = tr.rotation;
// Set this here as well since the DoUpdateGraphs method can be called from other scripts // Set this here as well since the DoUpdateGraphs method can be called from other scripts
lastCheckTime = Time.realtimeSinceStartup; lastCheckTime = GetSync().Time.realtimeSinceStartup;
} }
/// <summary>Volume of a Bounds object. X*Y*Z</summary> /// <summary>Volume of a Bounds object. X*Y*Z</summary>

View File

@ -1,5 +1,6 @@
using Pathfinding.Util; using Pathfinding.Util;
using System.Collections.Generic; using System.Collections.Generic;
using Game.Plugins.App.Util;
using UnityEngine; using UnityEngine;
namespace Pathfinding { namespace Pathfinding {
@ -434,7 +435,7 @@ namespace Pathfinding {
// the chances next time // the chances next time
clearanceRadius *= 0.9f; clearanceRadius *= 0.9f;
// This will pick points in 2D closer to the edge of the circle with a higher probability // This will pick points in 2D closer to the edge of the circle with a higher probability
dir = Random.onUnitSphere * Mathf.Lerp(newMagn, radius, tests / 5); dir = JNRandom.onUnitSphere * Mathf.Lerp(newMagn, radius, tests / 5);
dir.y = 0; dir.y = 0;
tests++; tests++;
} }
@ -500,7 +501,7 @@ namespace Pathfinding {
} }
// Pick a random node among the ones in the list weighted by their area // Pick a random node among the ones in the list weighted by their area
float tg = Random.value*tot; float tg = JNRandom.value*tot;
int v = accs.BinarySearch(tg); int v = accs.BinarySearch(tg);
if (v < 0) v = ~v; if (v < 0) v = ~v;

View File

@ -1,5 +1,6 @@
using UnityEngine; using UnityEngine;
using System.Collections.Generic; using System.Collections.Generic;
using Plugins.JNGame.Sync.Frame.Entity;
#if UNITY_5_5_OR_NEWER #if UNITY_5_5_OR_NEWER
using UnityEngine.Profiling; using UnityEngine.Profiling;
#endif #endif
@ -244,7 +245,7 @@ namespace Pathfinding.Util {
public GraphGizmoHelper GetSingleFrameGizmoHelper (AstarPath active) { public GraphGizmoHelper GetSingleFrameGizmoHelper (AstarPath active) {
var uniqHash = new RetainedGizmos.Hasher(); var uniqHash = new RetainedGizmos.Hasher();
uniqHash.AddHash(Time.realtimeSinceStartup.GetHashCode()); uniqHash.AddHash(JNTime.Time.realtimeSinceStartup.GetHashCode());
Draw(uniqHash); Draw(uniqHash);
return GetGizmoHelper(active, uniqHash); return GetGizmoHelper(active, uniqHash);
} }

View File

@ -5,6 +5,7 @@ using System.Threading.Tasks;
using BestHTTP.WebSocket; using BestHTTP.WebSocket;
using Cysharp.Threading.Tasks; using Cysharp.Threading.Tasks;
using Google.Protobuf; using Google.Protobuf;
using Plugins.JNGame.Network.Action;
using Plugins.JNGame.Network.Entity; using Plugins.JNGame.Network.Entity;
using Plugins.JNGame.Network.Util; using Plugins.JNGame.Network.Util;
using Plugins.JNGame.System; using Plugins.JNGame.System;

View File

@ -6,40 +6,45 @@ namespace Plugins.JNGame.Sync.Frame.Entity
private JNSyncFrame _sync; private JNSyncFrame _sync;
public static JNTime Time; public static JNTime Time = new JNTime();
/// <summary> /// <summary>
/// 在Unity中Time.time是一个非常有用的属性它表示从游戏开始运行到现在的时间单位是秒。它常常被用来作为游戏内时间或者帧时间的参考。 /// 在Unity中Time.time是一个非常有用的属性它表示从游戏开始运行到现在的时间单位是秒。它常常被用来作为游戏内时间或者帧时间的参考。
/// </summary> /// </summary>
public float time => (this.deltaTime * _sync.NLocalRunFrame); public float time => _sync == null ? UnityEngine.Time.time : (this.deltaTime * _sync.NLocalRunFrame);
/// <summary> /// <summary>
/// 在Unity中Time.deltaTime是一个表示上一帧所花费时间的属性单位是秒。它用于在游戏运行时提供稳定的时间测量不受帧率变化的影响 /// 在Unity中Time.deltaTime是一个表示上一帧所花费时间的属性单位是秒。它用于在游戏运行时提供稳定的时间测量不受帧率变化的影响
/// </summary> /// </summary>
public float deltaTime => ((float)_sync.NSyncTime / _sync.NDivideFrame) / 1000; public float deltaTime => _sync == null ? UnityEngine.Time.deltaTime : ((float)_sync.NSyncTime / _sync.NDivideFrame) / 1000;
/// <summary> /// <summary>
/// Time.fixedDeltaTime是一个在Unity中表示以秒为单位的固定时间间隔的属性通常用于物理计算和其他需要固定帧率更新的场景。它与Time.deltaTime不同因为Time.fixedDeltaTime可以自行赋值并且用于固定帧率更新如FixedUpdate()函数)。 /// Time.fixedDeltaTime是一个在Unity中表示以秒为单位的固定时间间隔的属性通常用于物理计算和其他需要固定帧率更新的场景。它与Time.deltaTime不同因为Time.fixedDeltaTime可以自行赋值并且用于固定帧率更新如FixedUpdate()函数)。
/// </summary> /// </summary>
public float fixedDeltaTime => ((float)_sync.NSyncTime / _sync.NDivideFrame) / 1000; public float fixedDeltaTime => _sync == null ? UnityEngine.Time.fixedDeltaTime : ((float)_sync.NSyncTime / _sync.NDivideFrame) / 1000;
/// <summary> /// <summary>
/// Time.frameCount 表示已经渲染的总帧数。这个属性通常用于性能测试,例如,你可以使用它来检查游戏是否在每一帧都进行了必要的渲染工作,或者是否在某些帧上出现了渲染瓶颈。 /// Time.frameCount 表示已经渲染的总帧数。这个属性通常用于性能测试,例如,你可以使用它来检查游戏是否在每一帧都进行了必要的渲染工作,或者是否在某些帧上出现了渲染瓶颈。
/// </summary> /// </summary>
public int frameCount => _sync.NLocalRunFrame; public int frameCount => _sync == null ? UnityEngine.Time.frameCount : _sync.NLocalRunFrame;
/// <summary> /// <summary>
/// Time.realtimeSinceStartup是Unity中表示自游戏启动以来经过的实时时间以秒为单位的属性。这个时间不受Time.timeScale的影响即使游戏暂停或慢动作它的值也会持续增加因为它是独立于游戏时间的。 /// Time.realtimeSinceStartup是Unity中表示自游戏启动以来经过的实时时间以秒为单位的属性。这个时间不受Time.timeScale的影响即使游戏暂停或慢动作它的值也会持续增加因为它是独立于游戏时间的。
/// </summary> /// </summary>
public float realtimeSinceStartup => (this.time); public float realtimeSinceStartup => _sync == null ? UnityEngine.Time.realtimeSinceStartup : (this.time);
/// <summary> /// <summary>
/// Time.unscaledDeltaTime 是 Unity 中的一个属性,表示上一帧所花费的时间,单位是秒。与 Time.deltaTime 不同Time.unscaledDeltaTime 是未经过时间缩放的,也就是说它不受 Time.timeScale 的影响。 /// Time.unscaledDeltaTime 是 Unity 中的一个属性,表示上一帧所花费的时间,单位是秒。与 Time.deltaTime 不同Time.unscaledDeltaTime 是未经过时间缩放的,也就是说它不受 Time.timeScale 的影响。
/// </summary> /// </summary>
public float unscaledDeltaTime => ((float)_sync.NSyncTime / _sync.NDivideFrame) / 1000; public float unscaledDeltaTime => _sync == null ? UnityEngine.Time.unscaledDeltaTime : ((float)_sync.NSyncTime / _sync.NDivideFrame) / 1000;
public float smoothDeltaTime => ((float)_sync.NSyncTime / _sync.NDivideFrame) / 1000; public float smoothDeltaTime => _sync == null ? UnityEngine.Time.smoothDeltaTime : ((float)_sync.NSyncTime / _sync.NDivideFrame) / 1000;
/// <summary>
/// Time.timeSinceLevelLoad是一个表示从当前场景开始到现在所经过的时间的属性单位是秒。这个属性通常用于计算从加载关卡开始到当前帧的时间并且会随着游戏的暂停而停止计算
/// </summary>
public float timeSinceLevelLoad => _sync == null ? UnityEngine.Time.timeSinceLevelLoad : ((float)_sync.NSyncTime / _sync.NDivideFrame) / 1000;
public JNTime(JNSyncFrame sync) public JNTime(JNSyncFrame sync)
@ -47,6 +52,10 @@ namespace Plugins.JNGame.Sync.Frame.Entity
Time = this; Time = this;
this._sync = sync; this._sync = sync;
} }
public JNTime()
{
Time = this;
}
} }
} }

View File

@ -1,4 +1,5 @@
using UnityEngine; using System;
using UnityEngine;
namespace Plugins.JNGame.Sync.Frame.game namespace Plugins.JNGame.Sync.Frame.game
{ {
@ -10,8 +11,15 @@ namespace Plugins.JNGame.Sync.Frame.game
[HideInInspector] [HideInInspector]
public int NID => _nId; public int NID => _nId;
public abstract Boolean IsInput();
//清空输入
public abstract void ClearInput();
//获取同步类 //获取同步类
protected abstract JNSyncFrame GetSync(); protected abstract JNSyncFrame GetSync();
public abstract byte[] Encoder();
} }
} }

View File

@ -12,16 +12,28 @@ namespace Plugins.JNGame.Sync.Frame.game
//当前输入 //当前输入
private T _input; private T _input;
public T NInput
{
get
{
if (this._input == null)
this._input = Activator.CreateInstance<T>();
return this._input;
}
}
//是否有输入 //是否有输入
public Boolean isInput => this._input == null; public override bool IsInput()
{
return this._input != null;
}
//是否初始化完成 //是否初始化完成
[HideInInspector] [HideInInspector]
public Boolean isSyncInitSuccess = false; public Boolean isSyncInitSuccess = false;
//清空输入 //清空输入
public void ClearInput(){ public override void ClearInput(){
this._input = default(T); this._input = default(T);
} }
@ -50,7 +62,13 @@ namespace Plugins.JNGame.Sync.Frame.game
return Encoding.UTF8.GetBytes(JsonConvert.SerializeObject(input)); return Encoding.UTF8.GetBytes(JsonConvert.SerializeObject(input));
} }
public override byte[] Encoder()
{
return this.Encoder(this.NInput);
}
//帧同步 //帧同步
public abstract void OnLateSyncUpdate(int dt,JNFrameInfo frame,T input);
public abstract void OnSyncUpdate(int dt,JNFrameInfo frame,T input); public abstract void OnSyncUpdate(int dt,JNFrameInfo frame,T input);

View File

@ -1,8 +1,10 @@
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Linq;
using System.Reflection; using System.Reflection;
using System.Threading.Tasks; using System.Threading.Tasks;
using Cysharp.Threading.Tasks; using Cysharp.Threading.Tasks;
using Google.Protobuf;
using Plugins.JNGame.Sync.Frame.Entity; using Plugins.JNGame.Sync.Frame.Entity;
using Plugins.JNGame.Sync.Frame.game; using Plugins.JNGame.Sync.Frame.game;
using Plugins.JNGame.System; using Plugins.JNGame.System;
@ -138,7 +140,7 @@ namespace Plugins.JNGame.Sync.Frame
if(nSyncTime > 0){ if(nSyncTime > 0){
while(nSyncTime != 0 && this.dtTotal > nSyncTime){ while(nSyncTime != 0 && this.dtTotal > nSyncTime){
this.onUpdate(); this.OnUpdate();
this.dtTotal -= nSyncTime; this.dtTotal -= nSyncTime;
nSyncTime = this.DyTime(); nSyncTime = this.DyTime();
} }
@ -146,15 +148,53 @@ namespace Plugins.JNGame.Sync.Frame
//追帧运行 保持前端 15 帧 刷新 //追帧运行 保持前端 15 帧 刷新
long endTime = (new DateTimeOffset(DateTime.UtcNow).ToUnixTimeMilliseconds()) + 66; long endTime = (new DateTimeOffset(DateTime.UtcNow).ToUnixTimeMilliseconds()) + 66;
while(this.DyTime() == 0 && (new DateTimeOffset(DateTime.UtcNow).ToUnixTimeMilliseconds()) < endTime){ while(this.DyTime() == 0 && (new DateTimeOffset(DateTime.UtcNow).ToUnixTimeMilliseconds()) < endTime){
this.onUpdate(); this.OnUpdate();
} }
dtTotal = 0; dtTotal = 0;
} }
//更新输入
if(this.dtInputTotal > (this._nSyncTime / this._nDivideFrame)){
this.dtInputTotal = 0;
this.OnInput();
}
}
//运行操作
private void OnInput()
{
//输入数据
JNFrameInputs inputs = new JNFrameInputs();
//收集帧数据
this._nSyncActors.ForEach(action =>
{
if (action.IsInput())
{
//如果输入了 则添加到输入数据
var input = new JNFrameInput();
input.NId = action.NID;
var data = action.Encoder();
input.Input = ByteString.CopyFrom(data);
inputs.Inputs.Add(input);
}
action.ClearInput();
});
//发送帧操作
if (inputs.Inputs.Count > 0)
{
this.OnSendInput(inputs);
}
} }
//运行帧 //运行帧
public void onUpdate() private void OnUpdate()
{ {
if(!(_nFrameQueue.TryDequeue(out var frame))) return; if(!(_nFrameQueue.TryDequeue(out var frame))) return;
@ -163,15 +203,33 @@ namespace Plugins.JNGame.Sync.Frame
int dt = this._nSyncTime / this._nDivideFrame; int dt = this._nSyncTime / this._nDivideFrame;
//拆出输入 //拆出输入
Dictionary<int, JNFrameInput> inputs = new(); Dictionary<int, JNFrameInput> inputs = new();
foreach (var message in frame.Messages) foreach (var message in frame.Messages)
{ {
inputs.Add(message.NId,message); inputs[message.NId] = message;
} }
Debug.Log(inputs.Count);
//运行之前帧
this._nSyncActors.ToList().ForEach(child =>
{
MethodInfo OnSyncUpdate = child.GetType().GetMethod("OnLateSyncUpdate");
MethodInfo Decoder = child.GetType().GetMethod("Decoder");
if (inputs.ContainsKey(child.NID))
{
OnSyncUpdate.Invoke(child,new []{dt,frame,Decoder.Invoke(child,new object[]{ inputs[child.NID].Input.ToByteArray() })});
}
else
{
OnSyncUpdate.Invoke(child,new []{ dt,frame,(object)null });
}
});
//更新帧 //更新帧
this._nSyncActors.ForEach(child => this._nSyncActors.ToList().ForEach(child =>
{ {
MethodInfo OnSyncUpdate = child.GetType().GetMethod("OnSyncUpdate"); MethodInfo OnSyncUpdate = child.GetType().GetMethod("OnSyncUpdate");
MethodInfo Decoder = child.GetType().GetMethod("Decoder"); MethodInfo Decoder = child.GetType().GetMethod("Decoder");

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 5fd88164c6dc14644b6c6a49a59d103a
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -0,0 +1,40 @@
# Unity-Logs-Viewer
Please note with new unity you can view device logs on editor console window, check the new attach menu in editor console window.
Using this tool you can easily check your editor console logs inside the game itself!
All what you have to do is to make a circle gesture using your mouse (click and drag) or your finger (touch and drag) on the mobile screen to show all these logs!
You can download also from unity asset store
https://www.assetstore.unity3d.com/en/#!/content/12047
#### To setup log viewer do the following
1 - create reporter from menu (Reporter->Create) at first scene your game start.
2 - then set the ” Scrip execution order ” in (Edit -> Project Settings ) of Reporter.cs to be the highest.
### Version 1.8
- Add Copy to clipboard.
- Merge Fix for Unity 2019.
- Fix ReporterModificationProcessor is annoying.
- Fix waste ram.
### Version 1.7
- Add Save logs button( thanks for Ahmed Shbli ).
- Fix deprecated code for new unity.
- Fix Warnings.
- Fix loading scene from asset bundle error.
<a href="https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=J9MX5C6Q7B2NY">
<img src="https://www.paypalobjects.com/webstatic/en_US/btn/btn_donate_cc_147x47.png">
</img>
</a>

View File

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 7970120b28b7fc040bcf888bbe4e0062
TextScriptImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 0264958cc64273c46a257dd5bc018605
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@ -0,0 +1,5 @@
fileFormatVersion: 2
guid: 15d89de0102fd6743afd4d727f43d481
folderAsset: yes
DefaultImporter:
userData:

View File

@ -0,0 +1,94 @@
using UnityEngine;
using UnityEditor;
using UnityEditor.Callbacks;
using System.IO;
using System.Collections;
public class ReporterEditor : Editor
{
[MenuItem("Reporter/Create")]
public static void CreateReporter()
{
const int ReporterExecOrder = -12000;
GameObject reporterObj = new GameObject();
reporterObj.name = "Reporter";
Reporter reporter = reporterObj.AddComponent<Reporter>();
reporterObj.AddComponent<ReporterMessageReceiver>();
//reporterObj.AddComponent<TestReporter>();
// Register root object for undo.
Undo.RegisterCreatedObjectUndo(reporterObj, "Create Reporter Object");
MonoScript reporterScript = MonoScript.FromMonoBehaviour(reporter);
string reporterPath = Path.GetDirectoryName(AssetDatabase.GetAssetPath(reporterScript));
if (MonoImporter.GetExecutionOrder(reporterScript) != ReporterExecOrder) {
MonoImporter.SetExecutionOrder(reporterScript, ReporterExecOrder);
//Debug.Log("Fixing exec order for " + reporterScript.name);
}
reporter.images = new Images();
reporter.images.clearImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/clear.png"), typeof(Texture2D));
reporter.images.collapseImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/collapse.png"), typeof(Texture2D));
reporter.images.clearOnNewSceneImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/clearOnSceneLoaded.png"), typeof(Texture2D));
reporter.images.showTimeImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/timer_1.png"), typeof(Texture2D));
reporter.images.showSceneImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/UnityIcon.png"), typeof(Texture2D));
reporter.images.userImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/user.png"), typeof(Texture2D));
reporter.images.showMemoryImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/memory.png"), typeof(Texture2D));
reporter.images.softwareImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/software.png"), typeof(Texture2D));
reporter.images.dateImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/date.png"), typeof(Texture2D));
reporter.images.showFpsImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/fps.png"), typeof(Texture2D));
//reporter.images.graphImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/chart.png"), typeof(Texture2D));
reporter.images.infoImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/info.png"), typeof(Texture2D));
reporter.images.saveLogsImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/Save.png"), typeof(Texture2D));
reporter.images.searchImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/search.png"), typeof(Texture2D));
reporter.images.copyImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/copy.png"), typeof(Texture2D));
reporter.images.closeImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/close.png"), typeof(Texture2D));
reporter.images.buildFromImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/buildFrom.png"), typeof(Texture2D));
reporter.images.systemInfoImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/ComputerIcon.png"), typeof(Texture2D));
reporter.images.graphicsInfoImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/graphicCard.png"), typeof(Texture2D));
reporter.images.backImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/back.png"), typeof(Texture2D));
reporter.images.logImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/log_icon.png"), typeof(Texture2D));
reporter.images.warningImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/warning_icon.png"), typeof(Texture2D));
reporter.images.errorImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/error_icon.png"), typeof(Texture2D));
reporter.images.barImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/bar.png"), typeof(Texture2D));
reporter.images.button_activeImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/button_active.png"), typeof(Texture2D));
reporter.images.even_logImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/even_log.png"), typeof(Texture2D));
reporter.images.odd_logImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/odd_log.png"), typeof(Texture2D));
reporter.images.selectedImage = (Texture2D)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/selected.png"), typeof(Texture2D));
reporter.images.reporterScrollerSkin = (GUISkin)AssetDatabase.LoadAssetAtPath(Path.Combine(reporterPath, "Images/reporterScrollerSkin.guiskin"), typeof(GUISkin));
}
}
public class ReporterModificationProcessor : UnityEditor.AssetModificationProcessor
{
[InitializeOnLoad]
public class BuildInfo
{
static BuildInfo()
{
EditorApplication.update += Update;
}
static bool isCompiling = true;
static void Update()
{
if (!EditorApplication.isCompiling && isCompiling) {
//Debug.Log("Finish Compile");
if (!Directory.Exists(Application.dataPath + "/StreamingAssets")) {
Directory.CreateDirectory(Application.dataPath + "/StreamingAssets");
}
string info_path = Application.dataPath + "/StreamingAssets/build_info";
StreamWriter build_info = new StreamWriter(info_path);
build_info.Write("Build from " + SystemInfo.deviceName + " at " + System.DateTime.Now.ToString());
build_info.Close();
}
isCompiling = EditorApplication.isCompiling;
}
}
}

View File

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 639e2d9db58377f4997f7678b50e7e7a
MonoImporter:
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:

View File

@ -0,0 +1,5 @@
fileFormatVersion: 2
guid: 7482c424dbd8a48489e4b2091f858a69
folderAsset: yes
DefaultImporter:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.8 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: e9011b1dc9256ad4d9c19a31c595f95f
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -1
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB

View File

@ -0,0 +1,101 @@
fileFormatVersion: 2
guid: 4a4821d80a1fc774fb76eac6213544e7
TextureImporter:
internalIDToNameTable: []
externalObjects: {}
serializedVersion: 10
mipmaps:
mipMapMode: 0
enableMipMap: 0
sRGBTexture: 1
linearTexture: 0
fadeOut: 0
borderMipMap: 0
mipMapsPreserveCoverage: 0
alphaTestReferenceValue: 0.5
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: 0.25
normalMapFilter: 0
isReadable: 0
streamingMipmaps: 0
streamingMipmapsPriority: 0
grayScaleToAlpha: 0
generateCubemap: 6
cubemapConvolution: 0
seamlessCubemap: 0
textureFormat: 1
maxTextureSize: 2048
textureSettings:
serializedVersion: 2
filterMode: -1
aniso: 1
mipBias: -100
wrapU: 1
wrapV: 1
wrapW: -1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: 0.5, y: 0.5}
spritePixelsToUnits: 100
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spriteGenerateFallbackPhysicsShape: 1
alphaUsage: 1
alphaIsTransparency: 1
spriteTessellationDetail: -1
textureType: 2
textureShape: 1
singleChannelComponent: 0
maxTextureSizeSet: 0
compressionQualitySet: 0
textureFormatSet: 0
platformSettings:
- serializedVersion: 2
buildTarget: DefaultTexturePlatform
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
- serializedVersion: 2
buildTarget: Standalone
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
spriteSheet:
serializedVersion: 2
sprites: []
outline: []
physicsShape: []
bones: []
spriteID:
internalID: 0
vertices: []
indices:
edges: []
weights: []
secondaryTextures: []
spritePackingTag:
pSDRemoveMatte: 0
pSDShowRemoveMatteOption: 0
userData:
assetBundleName:
assetBundleVariant:

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.0 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: ff4dfb29f203a174ab8e4c498afe908a
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -1
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.7 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: a0632a18e7c665641b94fea66506ab50
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -1
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.0 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: 8128d4f4c0193e34586f9631ef7d4787
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -3
maxTextureSize: 32
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.6 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: 8702be598dd9f504ca33be2afee2ca33
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -1
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.0 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: 2580a2e903691e44282e56ed6e0ff37a
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -3
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.0 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: 903d664043815ca4a9cc1f548bdd4b21
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -1
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.9 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: 112c6fcf56e349449ab2e6ad76b67816
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -1
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: 3a6bc61a8319b1949ab9f1f2db1302b4
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -1
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.6 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: b65e9be99974bc94eab5d6698811d0b8
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -1
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.8 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: 4623f326a884a2546ab39078bf7822c3
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -1
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.1 KiB

View File

@ -0,0 +1,112 @@
fileFormatVersion: 2
guid: 7f36d71624c630046b855909c497be17
TextureImporter:
internalIDToNameTable: []
externalObjects: {}
serializedVersion: 10
mipmaps:
mipMapMode: 0
enableMipMap: 0
sRGBTexture: 1
linearTexture: 0
fadeOut: 0
borderMipMap: 0
mipMapsPreserveCoverage: 0
alphaTestReferenceValue: 0.5
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: 0.25
normalMapFilter: 0
isReadable: 0
streamingMipmaps: 0
streamingMipmapsPriority: 0
grayScaleToAlpha: 0
generateCubemap: 6
cubemapConvolution: 0
seamlessCubemap: 0
textureFormat: 1
maxTextureSize: 2048
textureSettings:
serializedVersion: 2
filterMode: -1
aniso: 1
mipBias: -100
wrapU: 1
wrapV: 1
wrapW: -1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: 0.5, y: 0.5}
spritePixelsToUnits: 100
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spriteGenerateFallbackPhysicsShape: 1
alphaUsage: 1
alphaIsTransparency: 1
spriteTessellationDetail: -1
textureType: 2
textureShape: 1
singleChannelComponent: 0
maxTextureSizeSet: 0
compressionQualitySet: 0
textureFormatSet: 0
platformSettings:
- serializedVersion: 2
buildTarget: DefaultTexturePlatform
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
- serializedVersion: 2
buildTarget: Standalone
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
- serializedVersion: 2
buildTarget: Android
maxTextureSize: 2048
resizeAlgorithm: 0
textureFormat: -1
textureCompression: 1
compressionQuality: 50
crunchedCompression: 0
allowsAlphaSplitting: 0
overridden: 0
androidETC2FallbackOverride: 0
spriteSheet:
serializedVersion: 2
sprites: []
outline: []
physicsShape: []
bones: []
spriteID:
internalID: 0
vertices: []
indices:
edges: []
weights: []
secondaryTextures: []
spritePackingTag:
pSDRemoveMatte: 0
pSDShowRemoveMatteOption: 0
userData:
assetBundleName:
assetBundleVariant:

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.0 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: a7561cd0a9f62a84e99bff1abce2a222
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 1
linearTexture: 0
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -1
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: -1
mipBias: -1
wrapMode: -1
nPOTScale: 1
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 0
textureType: -1
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.2 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: 7640ebf8b3a92124d821d3b4b8b3fd7e
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -3
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: d27aad55b568c6544b0b95a95da44bc7
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -3
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.0 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: 90b2f48155dc0e74f8e428561ac79da5
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -1
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: 999d31716332cc04eb4abc9c9270b0ca
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -1
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.9 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: 2954bef266e6d794aba08ceacc887a0f
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -1
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.8 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: e876b803a4dd5c5488078071d15aa9c0
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -3
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.2 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: f447d62f2dacf9843be7cbf168a3a9d0
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -1
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: 8ffbb44a2c3adae45913474e4fd487f5
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -3
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

View File

@ -0,0 +1,4 @@
fileFormatVersion: 2
guid: 1cc68832d00d3284a9324a4dc05be753
NativeFormatImporter:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.4 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: 564b866f40be55d40bb624f85197535c
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -3
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.8 KiB

View File

@ -0,0 +1,47 @@
fileFormatVersion: 2
guid: 65382a9375963d842a164495d6431d6d
TextureImporter:
fileIDToRecycleName: {}
serializedVersion: 2
mipmaps:
mipMapMode: 0
enableMipMap: 0
linearTexture: 1
correctGamma: 0
fadeOut: 0
borderMipMap: 0
mipMapFadeDistanceStart: 1
mipMapFadeDistanceEnd: 3
bumpmap:
convertToNormalMap: 0
externalNormalMap: 0
heightScale: .25
normalMapFilter: 0
isReadable: 0
grayScaleToAlpha: 0
generateCubemap: 0
seamlessCubemap: 0
textureFormat: -3
maxTextureSize: 1024
textureSettings:
filterMode: -1
aniso: 1
mipBias: -1
wrapMode: 1
nPOTScale: 0
lightmap: 0
compressionQuality: 50
spriteMode: 0
spriteExtrude: 1
spriteMeshType: 1
alignment: 0
spritePivot: {x: .5, y: .5}
spriteBorder: {x: 0, y: 0, z: 0, w: 0}
spritePixelsToUnits: 100
alphaIsTransparency: 1
textureType: 2
buildTargetSettings: []
spriteSheet:
sprites: []
spritePackingTag:
userData:

Some files were not shown because too many files have changed in this diff Show More