Browse Source

场景整理导出AB包

develop
杨栋梁 5 months ago
parent
commit
b65683822f
  1. 162
      .gitignore
  2. 6
      .vsconfig
  3. 8
      Assets/Editor.meta
  4. 544
      Assets/Editor/SceneTool.cs
  5. 11
      Assets/Editor/SceneTool.cs.meta
  6. 61082
      Assets/HePingFanDian/HePingFanDian.prefab
  7. 2
      Assets/HePingFanDian/HePingFanDian.prefab.meta
  8. 2
      Assets/HePingFanDian/Scene/Rectangle001.FBX.meta
  9. 8
      Assets/HePingFanDian/Scenes/BuildingScene.meta
  10. 66128
      Assets/HePingFanDian/Scenes/BuildingScene.unity
  11. 2
      Assets/HePingFanDian/Scenes/BuildingScene.unity.meta
  12. BIN
      Assets/HePingFanDian/Scenes/BuildingScene/NavMesh-Car.asset
  13. 8
      Assets/HePingFanDian/Scenes/BuildingScene/NavMesh-Car.asset.meta
  14. BIN
      Assets/HePingFanDian/Scenes/BuildingScene/NavMesh-Man.asset
  15. 8
      Assets/HePingFanDian/Scenes/BuildingScene/NavMesh-Man.asset.meta
  16. 2
      Assets/HePingFanDian/ShiNei/SNXHS.FBX.meta
  17. 2
      Assets/HePingFanDian/ShiNei/ShiNei.FBX.meta
  18. 64540
      Assets/HePingFanDian/hpfd.prefab
  19. 7
      Assets/HePingFanDian/hpfd.prefab.meta
  20. 2
      Assets/MscPublicShangHai
  21. 8
      Assets/MscPublicShangHai.meta
  22. 8
      Assets/StreamingAssets.meta
  23. 41
      Packages/manifest.json
  24. 15
      ProjectSettings/EditorBuildSettings.asset
  25. 32
      ProjectSettings/InputManager.asset
  26. 30
      ProjectSettings/ProjectSettings.asset
  27. 2
      ProjectSettings/QualitySettings.asset

162
.gitignore vendored

@ -1,38 +1,10 @@
# ---> Unity
# This .gitignore file should be placed at the root of your Unity project directory
#
# Get latest from https://github.com/github/gitignore/blob/master/Unity.gitignore
#
/[Ll]ibrary/
/[Tt]emp/
/[Oo]bj/
/[Bb]uild/
/[Bb]uilds/
/[Ll]ogs/
/[Uu]ser[Ss]ettings/
# MemoryCaptures can get excessive in size.
# They also could contain extremely sensitive data
/[Mm]emoryCaptures/
# Asset meta data should only be ignored when the corresponding asset is also ignored
!/[Aa]ssets/**/*.meta
# Uncomment this line if you wish to ignore the asset store tools plugin
# /[Aa]ssets/AssetStoreTools*
# Autogenerated Jetbrains Rider plugin
/[Aa]ssets/Plugins/Editor/JetBrains*
# Visual Studio cache directory
.vs/
# Gradle cache directory
.gradle/
# Autogenerated VS/MD/Consulo solution and project files
ExportedObj/
.consulo/
/Assets/StreamingAssets/AssetBundles/
# Autogenerated VS/MD solution and project files
*.csproj
*.unityproj
*.sln
@ -42,32 +14,122 @@ ExportedObj/
*.userprefs
*.pidb
*.booproj
*.svd
*.pdb
*.mdb
*.opendb
*.VC.db
# Unity3D generated meta files
*.pidb.meta
*.pdb.meta
*.mdb.meta
# Unity3D generated file on crash reports
# Unity3D Generated File On Crash Reports
sysinfo.txt
# Builds
*.apk
*.aab
*.unitypackage
# ---> C Sharp
# Build Folders (you can keep bin if you'd like, to store dlls and pdbs)
[Bb]in/
[Oo]bj/
# mstest test results
TestResults
## Ignore Visual Studio temporary files, build results, and
## files generated by popular Visual Studio add-ons.
# User-specific files
*.suo
*.user
*.sln.docstates
# Build results
[Dd]ebug/
[Rr]elease/
x64/
*_i.c
*_p.c
*.ilk
*.obj
*.pch
*.pdb
*.pgc
*.pgd
*.rsp
*.sbr
*.tlb
*.tli
*.tlh
*.tmp
*.log
*.vspscc
*.vssscc
.builds
# Visual C++ cache files
ipch/
*.aps
*.ncb
*.opensdf
*.sdf
# Visual Studio profiler
*.psess
*.vsp
*.vspx
# Guidance Automation Toolkit
*.gpState
# ReSharper is a .NET coding add-in
_ReSharper*
# NCrunch
*.ncrunch*
.*crunch*.local.xml
# Installshield output folder
[Ee]xpress
# DocProject is a documentation generator add-in
DocProject/buildhelp/
DocProject/Help/*.HxT
DocProject/Help/*.HxC
DocProject/Help/*.hhc
DocProject/Help/*.hhk
DocProject/Help/*.hhp
DocProject/Help/Html2
DocProject/Help/html
# Click-Once directory
publish
# Publish Web Output
*.Publish.xml
# NuGet Packages Directory
packages
# Windows Azure Build Output
csx
*.build.csdef
# Crashlytics generated file
crashlytics-build.properties
# Windows Store app package directory
AppPackages/
# Packed Addressables
/[Aa]ssets/[Aa]ddressable[Aa]ssets[Dd]ata/*/*.bin*
# Others
[Bb]in
[Oo]bj
sql
TestResults
[Tt]est[Rr]esult*
*.Cache
ClientBin
[Ss]tyle[Cc]op.*
~$*
*.dbmdl
Generated_Code #added for RIA/Silverlight projects
# Temporary auto-generated Android Assets
/[Aa]ssets/[Ss]treamingAssets/aa.meta
/[Aa]ssets/[Ss]treamingAssets/aa/*
# Backup & report files from converting an old project file to a newer
# Visual Studio version. Backup files are not needed, because we have git ;-)
_UpgradeReport_Files/
Backup*/
UpgradeLog*.XML
/Logs
/.vs
/Assets/StreamingAssets/AssetBundles.meta
/Assets/StreamingAssets/ScenePics

6
.vsconfig

@ -0,0 +1,6 @@
{
"version": "1.0",
"components": [
"Microsoft.VisualStudio.Workload.ManagedGame"
]
}

8
Assets/Editor.meta

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

544
Assets/Editor/SceneTool.cs

@ -0,0 +1,544 @@
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEditor;
using UnityEngine.AI;
using System.IO;
using System.Text;
using System;
public class SceneTool
{
[MenuItem("SceneTool/SetFloorMessage")]//添加FloorMessage脚本绑定楼层信息
public static void SetFloorMessage()
{
Transform neiParent = GameObject.Find("shinei").transform.GetChild(0);
for (int i = 0; i < neiParent.childCount; i++)
{
//Debug.Log(neiParent.GetChild(i).name);
if (!neiParent.GetChild(i).GetComponent<FloorMessage>())
{
neiParent.GetChild(i).gameObject.AddComponent<FloorMessage>();
}
FloorMessage msg = neiParent.GetChild(i).GetComponent<FloorMessage>();
msg.targetTrans = GetTarget(neiParent.GetChild(i));
msg.buildNum = neiParent.name;
if (!neiParent.GetChild(i).name.ToLower().Contains("m"))
{
string floornum = neiParent.GetChild(i).name.Substring
(neiParent.GetChild(i).name.ToLower().IndexOf("nei") + 3, neiParent.GetChild(i).name.Length - 3);
msg.floorNum = int.Parse(floornum);
msg.interlayerNum = 0;
}
else
{
msg.floorNum = int.Parse(neiParent.GetChild(i).name.Substring
(neiParent.GetChild(i).name.ToLower().IndexOf("nei") + 3, neiParent.GetChild(i).name.ToLower().IndexOf("m")
- neiParent.GetChild(i).name.ToLower().IndexOf("nei") - 3));
msg.interlayerNum = int.Parse(neiParent.GetChild(i).name.Substring
(neiParent.GetChild(i).name.ToLower().IndexOf("m") + 1, neiParent.GetChild(i).name.Length -
neiParent.GetChild(i).name.ToLower().IndexOf("m") - 1));
}
}
Transform waiParent = GameObject.Find("shiwai").transform.GetChild(0);
for (int i = 0; i < waiParent.childCount; i++)
{
//Debug.Log(waiParent.GetChild(i).name);
if (!waiParent.GetChild(i).GetComponent<FloorMessage>())
{
waiParent.GetChild(i).gameObject.AddComponent<FloorMessage>();
}
FloorMessage msg = waiParent.GetChild(i).GetComponent<FloorMessage>();
msg.buildNum = waiParent.name;
if (!waiParent.GetChild(i).name.ToLower().Contains("m"))
{
string floornum = waiParent.GetChild(i).name.Substring
(waiParent.GetChild(i).name.ToLower().IndexOf("wai") + 3, waiParent.GetChild(i).name.Length - 3);
msg.floorNum = int.Parse(floornum);
msg.interlayerNum = 0;
}
else
{
msg.floorNum = int.Parse(waiParent.GetChild(i).name.Substring
(waiParent.GetChild(i).name.ToLower().IndexOf("wai") + 3, waiParent.GetChild(i).name.ToLower().IndexOf("m")
- waiParent.GetChild(i).name.ToLower().IndexOf("wai") - 3));
msg.interlayerNum = int.Parse(waiParent.GetChild(i).name.Substring
(waiParent.GetChild(i).name.ToLower().IndexOf("m") + 1, waiParent.GetChild(i).name.Length -
waiParent.GetChild(i).name.ToLower().IndexOf("m") - 1));
}
}
}
static Transform GetTarget(Transform parent)
{
for (int i = 0; i < parent.childCount; i++)
{
if (parent.GetChild(i).name.ToLower().Contains("_floor")
|| parent.GetChild(i).name.ToLower().Contains("-floor")
)
{
return parent.GetChild(i);
}
}
return parent;
}
[MenuItem("SceneTool/Setshinei")]//添加寻路层(选中shinei对象设置,注:扶梯情况特殊没有包含)
public static void SetShiNei()
{
Transform[] obj = Selection.GetTransforms(SelectionMode.Deep);
for (int i = 0; i < obj.Length; i++)
{
if (obj[i].GetComponent<MeshRenderer>())
{
if ((obj[i].name.ToLower().Contains("floor") ||//地面
obj[i].name.ToLower().Contains("lt") ||
obj[i].name.ToLower().Contains("chedao") ||
obj[i].name.ToLower().Contains("ft")) && !obj[i].name.ToLower().Contains("ltcs"))
{
obj[i].gameObject.layer = LayerMask.NameToLayer("SoldierRoad");
if (!obj[i].gameObject.GetComponent<MeshCollider>())
{
obj[i].gameObject.AddComponent<MeshCollider>();
}
if (!obj[i].gameObject.GetComponent<PathFindable>())
{
obj[i].gameObject.AddComponent<PathFindable>();
}
if (!obj[i].gameObject.GetComponent<CloneGameObjInfo>())
{
obj[i].gameObject.AddComponent<CloneGameObjInfo>();
}
if (!obj[i].gameObject.GetComponent<CloneableEnums>())
{
obj[i].gameObject.AddComponent<CloneableEnums>();
}
if (!obj[i].gameObject.GetComponent<CloneEnumsHelp>())
{
obj[i].gameObject.AddComponent<CloneEnumsHelp>();
}
CloneEnumsHelp cloneEnumsHelp = obj[i].gameObject.GetComponent<CloneEnumsHelp>();
cloneEnumsHelp.cloneOnFloorType = CloneOnFloorType.ShiNeiMan;
if (obj[i].GetComponentInParent<FloorMessage>())
{
FloorMessage fmg = obj[i].GetComponentInParent<FloorMessage>();
obj[i].gameObject.GetComponent<CloneGameObjInfo>().gameObjType = CloneObjType.StaticGameObject;
obj[i].gameObject.GetComponent<CloneGameObjInfo>().buildNum = fmg.buildNum;
obj[i].gameObject.GetComponent<CloneGameObjInfo>().floorNum = fmg.floorNum;
obj[i].gameObject.GetComponent<CloneGameObjInfo>().interlayerNum = fmg.interlayerNum;
}
}
if (obj[i].name.ToLower().Contains("wall") ||//墙面
obj[i].name.ToLower().Contains("zhuzi"))
{
obj[i].gameObject.layer = LayerMask.NameToLayer("SoldierRoad");
if (!obj[i].gameObject.GetComponent<NavMeshModifier>())
{
obj[i].gameObject.AddComponent<NavMeshModifier>();
}
NavMeshModifier mod = obj[i].gameObject.GetComponent<NavMeshModifier>();
mod.overrideArea = true;
mod.area = 1;
if (!obj[i].gameObject.GetComponent<MeshCollider>())
{
obj[i].gameObject.AddComponent<MeshCollider>();
}
}
}
}
}
[MenuItem("SceneTool/SetshineiXHS")]//设置室内消火栓属性
public static void SetSNXHS()
{
Transform[] obj = Selection.GetTransforms(SelectionMode.Deep);
for (int i = 0; i < obj.Length; i++)
{
if (obj[i].name.ToLower().Contains("xhs") &&
obj[i].GetComponent<MeshRenderer>())
{
if (!obj[i].gameObject.GetComponent<BoxCollider>())
{
obj[i].gameObject.AddComponent<BoxCollider>();
}
if (!obj[i].gameObject.GetComponent<CloneGameObjInfo>())
{
obj[i].gameObject.AddComponent<CloneGameObjInfo>();
}
obj[i].gameObject.GetComponent<CloneGameObjInfo>().gameObjType = CloneObjType.IndoorFireHydrant;
if (!obj[i].gameObject.GetComponent<InDoorHydrantMessage>())
{
obj[i].gameObject.AddComponent<InDoorHydrantMessage>();
}
if (!obj[i].gameObject.GetComponent<WaterSource>())
{
obj[i].gameObject.AddComponent<WaterSource>();
}
if (obj[i].gameObject.GetComponent<CloneGameObjInfo>().gameObjID == 0)
{
long staticGameObjId = (long)GUID.NewGuid(1, 1);
obj[i].gameObject.GetComponent<CloneGameObjInfo>().SetGameObjID(staticGameObjId);
}
if (!obj[i].gameObject.GetComponent<CloneableEnums>())
{
obj[i].gameObject.AddComponent<CloneableEnums>();
}
if (!obj[i].gameObject.GetComponent<CloneEnumsHelp>())
{
obj[i].gameObject.AddComponent<CloneEnumsHelp>();
}
CloneEnumsHelp cloneEnumsHelp = obj[i].gameObject.GetComponent<CloneEnumsHelp>();
cloneEnumsHelp.cloneOnFloorType = CloneOnFloorType.ShiNeiXHS;
if (obj[i].GetComponentInParent<FloorMessage>())
{
FloorMessage fmg = obj[i].GetComponentInParent<FloorMessage>();
obj[i].gameObject.GetComponent<CloneGameObjInfo>().buildNum = fmg.buildNum;
obj[i].gameObject.GetComponent<CloneGameObjInfo>().floorNum = fmg.floorNum;
obj[i].gameObject.GetComponent<CloneGameObjInfo>().interlayerNum = fmg.interlayerNum;
}
}
}
}
[MenuItem("SceneTool/DiXiaLouDing/CheNengZou")]//地面的楼顶(车能走),常见为地下建筑上的公路
public static void DiXiaLouDingCheNengZou()
{
Transform[] obj = Selection.GetTransforms(SelectionMode.Unfiltered);
{
for (int i = 0; i < obj.Length; i++)
{
if (obj[i].GetComponent<MeshRenderer>())
{
obj[i].gameObject.layer = LayerMask.NameToLayer("CarRoad");
if (!obj[i].gameObject.GetComponent<MeshCollider>())
{
obj[i].gameObject.AddComponent<MeshCollider>();
}
if (!obj[i].gameObject.GetComponent<PathFindable>())
{
obj[i].gameObject.AddComponent<PathFindable>();
}
if (!obj[i].gameObject.GetComponent<CloneGameObjInfo>())
{
obj[i].gameObject.AddComponent<CloneGameObjInfo>();
}
if (!obj[i].gameObject.GetComponent<CloneableEnums>())
{
obj[i].gameObject.AddComponent<CloneableEnums>();
}
if (!obj[i].gameObject.GetComponent<CloneEnumsHelp>())
{
obj[i].gameObject.AddComponent<CloneEnumsHelp>();
}
CloneEnumsHelp cloneEnumsHelp = obj[i].gameObject.GetComponent<CloneEnumsHelp>();
cloneEnumsHelp.cloneOnFloorType = CloneOnFloorType.ShiWaiCar;
if (obj[i].GetComponentInParent<FloorMessage>())
{
FloorMessage fmg = obj[i].GetComponentInParent<FloorMessage>();
obj[i].gameObject.GetComponent<CloneGameObjInfo>().gameObjType = CloneObjType.StaticGameObject;
obj[i].gameObject.GetComponent<CloneGameObjInfo>().buildNum = fmg.buildNum;
obj[i].gameObject.GetComponent<CloneGameObjInfo>().floorNum = fmg.floorNum;
obj[i].gameObject.GetComponent<CloneGameObjInfo>().interlayerNum = fmg.interlayerNum;
obj[i].gameObject.GetComponent<CloneGameObjInfo>().SpecialTag = "楼顶";
}
}
}
}
}
[MenuItem("SceneTool/DiXiaLouDing/RenNengZou")]//地面的楼顶(人能走),常见为地下建筑上的小路
public static void DiXiaLouDingRenNengZou()
{
Transform[] obj = Selection.GetTransforms(SelectionMode.Unfiltered);
{
for (int i = 0; i < obj.Length; i++)
{
if (obj[i].GetComponent<MeshRenderer>())
{
obj[i].gameObject.layer = LayerMask.NameToLayer("SoldierRoad");
if (!obj[i].gameObject.GetComponent<MeshCollider>())
{
obj[i].gameObject.AddComponent<MeshCollider>();
}
if (!obj[i].gameObject.GetComponent<PathFindable>())
{
obj[i].gameObject.AddComponent<PathFindable>();
}
if (!obj[i].gameObject.GetComponent<CloneGameObjInfo>())
{
obj[i].gameObject.AddComponent<CloneGameObjInfo>();
}
if (!obj[i].gameObject.GetComponent<CloneableEnums>())
{
obj[i].gameObject.AddComponent<CloneableEnums>();
}
if (!obj[i].gameObject.GetComponent<CloneEnumsHelp>())
{
obj[i].gameObject.AddComponent<CloneEnumsHelp>();
}
CloneEnumsHelp cloneEnumsHelp = obj[i].gameObject.GetComponent<CloneEnumsHelp>();
cloneEnumsHelp.cloneOnFloorType = CloneOnFloorType.ShiWaiMan;
if (obj[i].GetComponentInParent<FloorMessage>())
{
FloorMessage fmg = obj[i].GetComponentInParent<FloorMessage>();
obj[i].gameObject.GetComponent<CloneGameObjInfo>().gameObjType = CloneObjType.StaticGameObject;
obj[i].gameObject.GetComponent<CloneGameObjInfo>().buildNum = fmg.buildNum;
obj[i].gameObject.GetComponent<CloneGameObjInfo>().floorNum = fmg.floorNum;
obj[i].gameObject.GetComponent<CloneGameObjInfo>().interlayerNum = fmg.interlayerNum;
obj[i].gameObject.GetComponent<CloneGameObjInfo>().SpecialTag = "楼顶";
}
}
}
}
}
[MenuItem("SceneTool/DiXiaLouDing/DouBuZou")]//地面的楼顶(都不能走),常见为地下建筑上的花坛
public static void DiXiaLouDingDouBuZou()
{
Transform[] obj = Selection.GetTransforms(SelectionMode.Unfiltered);
{
for (int i = 0; i < obj.Length; i++)
{
if (obj[i].GetComponent<MeshRenderer>())
{
obj[i].gameObject.layer = LayerMask.NameToLayer("CarRoad");
if (!obj[i].gameObject.GetComponent<NavMeshModifier>())
{
obj[i].gameObject.AddComponent<NavMeshModifier>();
}
NavMeshModifier mod = obj[i].gameObject.GetComponent<NavMeshModifier>();
mod.overrideArea = true;
mod.area = 1;
}
}
}
}
[MenuItem("SceneTool/PuTongLouDing/RenNengZou")]//普通的楼顶(人能走),常见为地上建筑的楼顶地板
public static void PuTongLouDingRenNengZou()
{
Transform[] obj = Selection.GetTransforms(SelectionMode.Unfiltered);
{
for (int i = 0; i < obj.Length; i++)
{
if (obj[i].GetComponent<MeshRenderer>())
{
obj[i].gameObject.layer = LayerMask.NameToLayer("SoldierRoad");
if (!obj[i].gameObject.GetComponent<MeshCollider>())
{
obj[i].gameObject.AddComponent<MeshCollider>();
}
if (!obj[i].gameObject.GetComponent<PathFindable>())
{
obj[i].gameObject.AddComponent<PathFindable>();
}
if (!obj[i].gameObject.GetComponent<CloneGameObjInfo>())
{
obj[i].gameObject.AddComponent<CloneGameObjInfo>();
}
if (!obj[i].gameObject.GetComponent<CloneableEnums>())
{
obj[i].gameObject.AddComponent<CloneableEnums>();
}
if (!obj[i].gameObject.GetComponent<CloneEnumsHelp>())
{
obj[i].gameObject.AddComponent<CloneEnumsHelp>();
}
CloneEnumsHelp cloneEnumsHelp = obj[i].gameObject.GetComponent<CloneEnumsHelp>();
cloneEnumsHelp.cloneOnFloorType = CloneOnFloorType.LouDing;
if (obj[i].GetComponentInParent<FloorMessage>())
{
FloorMessage fmg = obj[i].GetComponentInParent<FloorMessage>();
obj[i].gameObject.GetComponent<CloneGameObjInfo>().gameObjType = CloneObjType.StaticGameObject;
obj[i].gameObject.GetComponent<CloneGameObjInfo>().buildNum = fmg.buildNum;
obj[i].gameObject.GetComponent<CloneGameObjInfo>().floorNum = fmg.floorNum;
obj[i].gameObject.GetComponent<CloneGameObjInfo>().interlayerNum = fmg.interlayerNum;
obj[i].gameObject.GetComponent<CloneGameObjInfo>().SpecialTag = "楼顶";
}
}
}
}
}
[MenuItem("SceneTool/PuTongLouDing/DouBuZou")]//普通的楼顶(都不能走)
public static void PuTongLouDingDouBuZou()
{
Transform[] obj = Selection.GetTransforms(SelectionMode.Unfiltered);
{
for (int i = 0; i < obj.Length; i++)
{
if (obj[i].GetComponent<MeshRenderer>())
{
obj[i].gameObject.layer = LayerMask.NameToLayer("SoldierRoad");
if (!obj[i].gameObject.GetComponent<NavMeshModifier>())
{
obj[i].gameObject.AddComponent<NavMeshModifier>();
}
NavMeshModifier mod = obj[i].gameObject.GetComponent<NavMeshModifier>();
mod.overrideArea = true;
mod.area = 1;
}
}
}
}
[MenuItem("SceneTool/ShiWai/CheNengZou")]//地面(车能走),常见为公路
public static void ShiWaiCheNengZou()
{
Transform[] obj = Selection.GetTransforms(SelectionMode.Unfiltered);
{
for (int i = 0; i < obj.Length; i++)
{
if (obj[i].GetComponent<MeshRenderer>())
{
obj[i].gameObject.layer = LayerMask.NameToLayer("CarRoad");
if (!obj[i].gameObject.GetComponent<MeshCollider>())
{
obj[i].gameObject.AddComponent<MeshCollider>();
}
if (!obj[i].gameObject.GetComponent<PathFindable>())
{
obj[i].gameObject.AddComponent<PathFindable>();
}
if (!obj[i].gameObject.GetComponent<CloneableEnums>())
{
obj[i].gameObject.AddComponent<CloneableEnums>();
}
if (!obj[i].gameObject.GetComponent<CloneEnumsHelp>())
{
obj[i].gameObject.AddComponent<CloneEnumsHelp>();
}
CloneEnumsHelp cloneEnumsHelp = obj[i].gameObject.GetComponent<CloneEnumsHelp>();
cloneEnumsHelp.cloneOnFloorType = CloneOnFloorType.ShiWaiCar;
}
}
}
}
[MenuItem("SceneTool/ShiWai/RenNengZou")]//地面(人能走),常见为小路
public static void ShiWaiRenNengZou()
{
Transform[] obj = Selection.GetTransforms(SelectionMode.Unfiltered);
{
for (int i = 0; i < obj.Length; i++)
{
if (obj[i].GetComponent<MeshRenderer>())
{
obj[i].gameObject.layer = LayerMask.NameToLayer("SoldierRoad");
if (!obj[i].gameObject.GetComponent<MeshCollider>())
{
obj[i].gameObject.AddComponent<MeshCollider>();
}
if (!obj[i].gameObject.GetComponent<PathFindable>())
{
obj[i].gameObject.AddComponent<PathFindable>();
}
if (!obj[i].gameObject.GetComponent<CloneableEnums>())
{
obj[i].gameObject.AddComponent<CloneableEnums>();
}
if (!obj[i].gameObject.GetComponent<CloneEnumsHelp>())
{
obj[i].gameObject.AddComponent<CloneEnumsHelp>();
}
CloneEnumsHelp cloneEnumsHelp = obj[i].gameObject.GetComponent<CloneEnumsHelp>();
cloneEnumsHelp.cloneOnFloorType = CloneOnFloorType.ShiWaiMan;
}
}
}
}
[MenuItem("SceneTool/ShiWai/DouBuZou")]//地面(都不能走),常见为花坛
public static void ShiWaiDouBuZou()
{
Transform[] obj = Selection.GetTransforms(SelectionMode.Unfiltered);
{
for (int i = 0; i < obj.Length; i++)
{
if (obj[i].GetComponent<MeshRenderer>())
{
obj[i].gameObject.layer = LayerMask.NameToLayer("CarRoad");
if (!obj[i].gameObject.GetComponent<NavMeshModifier>())
{
obj[i].gameObject.AddComponent<NavMeshModifier>();
}
NavMeshModifier mod = obj[i].gameObject.GetComponent<NavMeshModifier>();
mod.overrideArea = true;
mod.area = 1;
}
}
}
}
[MenuItem("SceneTool/TeShu/YouGuanDing")]//油罐顶
public static void YouGuanDing()
{
Transform[] obj = Selection.GetTransforms(SelectionMode.Unfiltered);
{
for (int i = 0; i < obj.Length; i++)
{
if (obj[i].GetComponent<MeshRenderer>())
{
if (!obj[i].gameObject.GetComponent<MeshCollider>())
{
obj[i].gameObject.AddComponent<MeshCollider>();
}
if (!obj[i].gameObject.GetComponent<CloneableEnums>())
{
obj[i].gameObject.AddComponent<CloneableEnums>();
}
if (!obj[i].gameObject.GetComponent<CloneEnumsHelp>())
{
obj[i].gameObject.AddComponent<CloneEnumsHelp>();
}
CloneEnumsHelp cloneEnumsHelp = obj[i].gameObject.GetComponent<CloneEnumsHelp>();
cloneEnumsHelp.cloneOnFloorType = CloneOnFloorType.YouGuanDing;
}
}
}
}
[MenuItem("SceneTool/TeShu/YouGuanBi")]//油罐壁
public static void YouGuanBi()
{
Transform[] obj = Selection.GetTransforms(SelectionMode.Unfiltered);
{
for (int i = 0; i < obj.Length; i++)
{
if (obj[i].GetComponent<MeshRenderer>())
{
if (!obj[i].gameObject.GetComponent<MeshCollider>())
{
obj[i].gameObject.AddComponent<MeshCollider>();
}
if (!obj[i].gameObject.GetComponent<CloneableEnums>())
{
obj[i].gameObject.AddComponent<CloneableEnums>();
}
if (!obj[i].gameObject.GetComponent<CloneEnumsHelp>())
{
obj[i].gameObject.AddComponent<CloneEnumsHelp>();
}
CloneEnumsHelp cloneEnumsHelp = obj[i].gameObject.GetComponent<CloneEnumsHelp>();
cloneEnumsHelp.cloneOnFloorType = CloneOnFloorType.YouGuanBi;
}
}
}
}
[MenuItem("SceneTool/TeShu/WeiXianPinYunShuChe")]//危险运输车
public static void WeiXianPinYunShuChe()
{
Transform[] obj = Selection.GetTransforms(SelectionMode.Unfiltered);
{
for (int i = 0; i < obj.Length; i++)
{
if (obj[i].GetComponent<MeshRenderer>())
{
if (!obj[i].gameObject.GetComponent<MeshCollider>())
{
obj[i].gameObject.AddComponent<MeshCollider>();
}
if (!obj[i].gameObject.GetComponent<CloneableEnums>())
{
obj[i].gameObject.AddComponent<CloneableEnums>();
}
if (!obj[i].gameObject.GetComponent<CloneEnumsHelp>())
{
obj[i].gameObject.AddComponent<CloneEnumsHelp>();
}
CloneEnumsHelp cloneEnumsHelp = obj[i].gameObject.GetComponent<CloneEnumsHelp>();
cloneEnumsHelp.cloneOnFloorType = CloneOnFloorType.WeiXianPinYunShuChe;
}
}
}
}
}

11
Assets/Editor/SceneTool.cs.meta

@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: fb694aca67be94b448fefb1cff8ea1ea
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

61082
Assets/HePingFanDian/HePingFanDian.prefab

File diff suppressed because it is too large Load Diff

2
Assets/HePingFanDian/HePingFanDian.prefab.meta

@ -1,5 +1,5 @@
fileFormatVersion: 2
guid: 895e7d1d41193b74aa9970b6399b9cf7
guid: f222af24dd98ee64cb4146987c60fa4d
PrefabImporter:
externalObjects: {}
userData:

2
Assets/HePingFanDian/Scene/Rectangle001.FBX.meta

@ -37,7 +37,7 @@ ModelImporter:
extraExposedTransformPaths: []
extraUserProperties: []
clipAnimations: []
isReadable: 0
isReadable: 1
meshes:
lODScreenPercentages: []
globalScale: 1

8
Assets/HePingFanDian/Scenes/BuildingScene.meta

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

66128
Assets/HePingFanDian/Scenes/BuildingScene.unity

File diff suppressed because it is too large Load Diff

2
Assets/HePingFanDian/Scenes/BuildingScene.unity.meta

@ -3,5 +3,5 @@ guid: 4b1db40500df2284992b9cf3a84f4638
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleName: buildingscene
assetBundleVariant:

BIN
Assets/HePingFanDian/Scenes/BuildingScene/NavMesh-Car.asset

Binary file not shown.

8
Assets/HePingFanDian/Scenes/BuildingScene/NavMesh-Car.asset.meta

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 7cea3a5eeec518f4b86134ce387a3b68
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 23800000
userData:
assetBundleName:
assetBundleVariant:

BIN
Assets/HePingFanDian/Scenes/BuildingScene/NavMesh-Man.asset

Binary file not shown.

8
Assets/HePingFanDian/Scenes/BuildingScene/NavMesh-Man.asset.meta

@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: afc50e18e82112a429586bfd64351a4b
NativeFormatImporter:
externalObjects: {}
mainObjectFileID: 23800000
userData:
assetBundleName:
assetBundleVariant:

2
Assets/HePingFanDian/ShiNei/SNXHS.FBX.meta

@ -793,7 +793,7 @@ ModelImporter:
extraExposedTransformPaths: []
extraUserProperties: []
clipAnimations: []
isReadable: 0
isReadable: 1
meshes:
lODScreenPercentages: []
globalScale: 1

2
Assets/HePingFanDian/ShiNei/ShiNei.FBX.meta

@ -2166,7 +2166,7 @@ ModelImporter:
extraExposedTransformPaths: []
extraUserProperties: []
clipAnimations: []
isReadable: 0
isReadable: 1
meshes:
lODScreenPercentages: []
globalScale: 1

64540
Assets/HePingFanDian/hpfd.prefab

File diff suppressed because it is too large Load Diff

7
Assets/HePingFanDian/hpfd.prefab.meta

@ -0,0 +1,7 @@
fileFormatVersion: 2
guid: 895e7d1d41193b74aa9970b6399b9cf7
PrefabImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

2
Assets/MscPublicShangHai

@ -1 +1 @@
Subproject commit 96baeb6a141fe2d8c041252d78eba2c7f03c6dfd
Subproject commit 076146f55103cf0e744940e2adbec5d6ff7ecc6f

8
Assets/MscPublicShangHai.meta

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

8
Assets/StreamingAssets.meta

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

41
Packages/manifest.json

@ -1,4 +1,41 @@
{
"dependencies": {
}
"dependencies": {
"com.unity.ads": "2.0.8",
"com.unity.analytics": "3.2.3",
"com.unity.assetbundlebrowser": "1.7.0",
"com.unity.collab-proxy": "1.2.15",
"com.unity.package-manager-ui": "2.0.13",
"com.unity.purchasing": "2.1.1",
"com.unity.textmeshpro": "1.4.1",
"com.unity.modules.ai": "1.0.0",
"com.unity.modules.animation": "1.0.0",
"com.unity.modules.assetbundle": "1.0.0",
"com.unity.modules.audio": "1.0.0",
"com.unity.modules.cloth": "1.0.0",
"com.unity.modules.director": "1.0.0",
"com.unity.modules.imageconversion": "1.0.0",
"com.unity.modules.imgui": "1.0.0",
"com.unity.modules.jsonserialize": "1.0.0",
"com.unity.modules.particlesystem": "1.0.0",
"com.unity.modules.physics": "1.0.0",
"com.unity.modules.physics2d": "1.0.0",
"com.unity.modules.screencapture": "1.0.0",
"com.unity.modules.terrain": "1.0.0",
"com.unity.modules.terrainphysics": "1.0.0",
"com.unity.modules.tilemap": "1.0.0",
"com.unity.modules.ui": "1.0.0",
"com.unity.modules.uielements": "1.0.0",
"com.unity.modules.umbra": "1.0.0",
"com.unity.modules.unityanalytics": "1.0.0",
"com.unity.modules.unitywebrequest": "1.0.0",
"com.unity.modules.unitywebrequestassetbundle": "1.0.0",
"com.unity.modules.unitywebrequestaudio": "1.0.0",
"com.unity.modules.unitywebrequesttexture": "1.0.0",
"com.unity.modules.unitywebrequestwww": "1.0.0",
"com.unity.modules.vehicles": "1.0.0",
"com.unity.modules.video": "1.0.0",
"com.unity.modules.vr": "1.0.0",
"com.unity.modules.wind": "1.0.0",
"com.unity.modules.xr": "1.0.0"
}
}

15
ProjectSettings/EditorBuildSettings.asset

@ -6,24 +6,21 @@ EditorBuildSettings:
serializedVersion: 2
m_Scenes:
- enabled: 1
path: Assets/MscPublic/Assets/Scenes/StartScene.unity
path: Assets/Scenes/StartScene.unity
guid: 37300393dbb336140841b54477ad48e2
- enabled: 1
path: Assets/MscPublic/Assets/Scenes/Login.unity
path: Assets/Scenes/Login.unity
guid: 951c5d21caa1164428c832c3e9a9de44
- enabled: 1
path: Assets/MscPublic/Assets/Scenes/Administrator.unity
path: Assets/Scenes/Administrator.unity
guid: 98a59c6747c23314a8c2be3943b8f882
- enabled: 1
path: Assets/MscPublic/Assets/Scenes/Examiner.unity
path: Assets/Scenes/Examiner.unity
guid: 9f5b02a7be06a3845a20da86c9f9f2ec
- enabled: 1
path: Assets/MscPublic/Assets/Scenes/Examinee.unity
path: Assets/Scenes/Examinee.unity
guid: cbd9062f507eac74780a1da70b6a3381
- enabled: 1
path: Assets/MscPublic/Assets/Scenes/Main.unity
path: Assets/Scenes/Main.unity
guid: 91cc03ee5fa98f6429a0d238c4602d50
- enabled: 1
path: Assets/Scenes/BuildingScene.unity
guid: 9fe6a5649e3332842a472edcae69d596
m_configObjects: {}

32
ProjectSettings/InputManager.asset

@ -773,3 +773,35 @@ InputManager:
type: 0
axis: 0
joyNum: 0
- serializedVersion: 3
m_Name: W
descriptiveName:
descriptiveNegativeName:
negativeButton:
positiveButton: w
altNegativeButton:
altPositiveButton:
gravity: 1000
dead: 0.001
sensitivity: 1000
snap: 0
invert: 0
type: 0
axis: 0
joyNum: 0
- serializedVersion: 3
m_Name: S
descriptiveName:
descriptiveNegativeName:
negativeButton:
positiveButton: s
altNegativeButton:
altPositiveButton:
gravity: 1000
dead: 0.001
sensitivity: 1000
snap: 0
invert: 0
type: 0
axis: 0
joyNum: 0

30
ProjectSettings/ProjectSettings.asset

@ -3,7 +3,7 @@
--- !u!129 &1
PlayerSettings:
m_ObjectHideFlags: 0
serializedVersion: 15
serializedVersion: 18
productGUID: e9072b0fc7d3355469b53868bf3343ff
AndroidProfiler: 0
AndroidFilterTouchesWhenObscured: 0
@ -18,7 +18,7 @@ PlayerSettings:
cursorHotspot: {x: 0, y: 0}
m_SplashScreenBackgroundColor: {r: 0.13725491, g: 0.12156863, b: 0.1254902, a: 1}
m_ShowUnitySplashScreen: 1
m_ShowUnitySplashLogo: 1
m_ShowUnitySplashLogo: 0
m_SplashScreenOverlayOpacity: 1
m_SplashScreenAnimation: 1
m_SplashScreenLogoStyle: 1
@ -42,8 +42,8 @@ PlayerSettings:
m_SplashScreenLogos: []
m_VirtualRealitySplashScreen: {fileID: 0}
m_HolographicTrackingLossScreen: {fileID: 0}
defaultScreenWidth: 1024
defaultScreenHeight: 768
defaultScreenWidth: 1920
defaultScreenHeight: 1080
defaultScreenWidthWeb: 960
defaultScreenHeightWeb: 600
m_StereoRenderingPath: 0
@ -52,8 +52,8 @@ PlayerSettings:
m_StackTraceTypes: 010000000100000001000000010000000100000001000000
iosShowActivityIndicatorOnLoading: -1
androidShowActivityIndicatorOnLoading: -1
iosAppInBackgroundBehavior: 0
displayResolutionDialog: 1
iosUseCustomAppBackgroundBehavior: 0
iosAllowHTTPDownload: 1
allowedAutorotateToPortrait: 1
allowedAutorotateToPortraitUpsideDown: 1
@ -104,6 +104,7 @@ PlayerSettings:
xboxOneMonoLoggingLevel: 0
xboxOneLoggingLevel: 1
xboxOneDisableEsram: 0
xboxOneEnableTypeOptimization: 0
xboxOnePresentImmediateThreshold: 0
switchQueueCommandMemory: 0
switchQueueControlMemory: 16384
@ -111,6 +112,8 @@ PlayerSettings:
switchNVNShaderPoolsGranularity: 33554432
switchNVNDefaultPoolsGranularity: 16777216
switchNVNOtherPoolsGranularity: 16777216
switchNVNMaxPublicTextureIDCount: 0
switchNVNMaxPublicSamplerIDCount: 0
vulkanEnableSetSRGBWrite: 0
m_SupportedAspectRatios:
4:3: 1
@ -143,6 +146,9 @@ PlayerSettings:
oculus:
sharedDepthBuffer: 1
dashSupport: 1
lowOverheadMode: 0
protectedContext: 0
v2Signing: 0
enable360StereoCapture: 0
protectGraphicsMemory: 0
enableFrameTimingStats: 0
@ -228,6 +234,7 @@ PlayerSettings:
metalEditorSupport: 1
metalAPIValidation: 1
iOSRenderExtraFrameOnPause: 0
iosCopyPluginsCodeInsteadOfSymlink: 0
appleDeveloperTeamID:
iOSManualSigningProvisioningProfileID:
tvOSManualSigningProvisioningProfileID:
@ -257,7 +264,14 @@ PlayerSettings:
banner: {fileID: 0}
androidGamepadSupportLevel: 0
resolutionDialogBanner: {fileID: 0}
m_BuildTargetIcons: []
m_BuildTargetIcons:
- m_BuildTarget:
m_Icons:
- serializedVersion: 2
m_Icon: {fileID: 2800000, guid: 82c8104a89699c148bfef42c98377fca, type: 3}
m_Width: 128
m_Height: 128
m_Kind: 0
m_BuildTargetPlatformIcons: []
m_BuildTargetBatching:
- m_BuildTarget: Standalone
@ -412,6 +426,7 @@ PlayerSettings:
switchRatingsInt_9: 0
switchRatingsInt_10: 0
switchRatingsInt_11: 0
switchRatingsInt_12: 0
switchLocalCommunicationIds_0:
switchLocalCommunicationIds_1:
switchLocalCommunicationIds_2:
@ -468,6 +483,7 @@ PlayerSettings:
ps4ShareFilePath:
ps4ShareOverlayImagePath:
ps4PrivacyGuardImagePath:
ps4ExtraSceSysFile:
ps4NPtitleDatPath:
ps4RemotePlayKeyAssignment: -1
ps4RemotePlayKeyMappingDir:
@ -508,6 +524,8 @@ PlayerSettings:
ps4disableAutoHideSplash: 0
ps4videoRecordingFeaturesUsed: 0
ps4contentSearchFeaturesUsed: 0
ps4CompatibilityPS5: 0
ps4GPU800MHz: 1
ps4attribEyeToEyeDistanceSettingVR: 0
ps4IncludedModules: []
monoEnv:

2
ProjectSettings/QualitySettings.asset

@ -153,7 +153,7 @@ QualitySettings:
shadowResolution: 2
shadowProjection: 1
shadowCascades: 2
shadowDistance: 3000
shadowDistance: 40
shadowNearPlaneOffset: 3
shadowCascade2Split: 0.33333334
shadowCascade4Split: {x: 0.06666667, y: 0.2, z: 0.46666667}

Loading…
Cancel
Save