This commit is contained in:
CortexCore
2025-04-18 18:47:30 +08:00
parent 98f554e57c
commit 5324d73239
18 changed files with 870 additions and 1195 deletions

View File

@@ -72,7 +72,7 @@ MonoBehaviour:
runAnimations:
_serializedList:
- Key: 1
Value: {fileID: -623603649343465320, guid: fb78ad17d7c6e8942a9984f6e86bfb55, type: 3}
Value: {fileID: -2601123519176111313, guid: 07e559271089db64b8382609fabc6a69, type: 3}
sprintAnimations:
_serializedList:
- Key: 1

View File

@@ -90,6 +90,37 @@ Transform:
m_Children: []
m_Father: {fileID: 5409078068046653646}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &3066824526575945453
GameObject:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
serializedVersion: 6
m_Component:
- component: {fileID: 9198065390282780830}
m_Layer: 6
m_Name: player_weapon
m_TagString: Untagged
m_Icon: {fileID: 0}
m_NavMeshLayer: 0
m_StaticEditorFlags: 0
m_IsActive: 1
--- !u!4 &9198065390282780830
Transform:
m_ObjectHideFlags: 0
m_CorrespondingSourceObject: {fileID: 0}
m_PrefabInstance: {fileID: 0}
m_PrefabAsset: {fileID: 0}
m_GameObject: {fileID: 3066824526575945453}
serializedVersion: 2
m_LocalRotation: {x: 0, y: 0, z: 0, w: 1}
m_LocalPosition: {x: 0, y: 0, z: 0}
m_LocalScale: {x: 1, y: 1, z: 1}
m_ConstrainProportionsScale: 0
m_Children: []
m_Father: {fileID: 5409078068046653646}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!1 &4061158270318089641
GameObject:
m_ObjectHideFlags: 0
@@ -493,6 +524,7 @@ Transform:
- {fileID: 7790705391717203476}
- {fileID: 6230482868901816064}
- {fileID: 506139165593134584}
- {fileID: 9198065390282780830}
m_Father: {fileID: 0}
m_LocalEulerAnglesHint: {x: 0, y: 0, z: 0}
--- !u!95 &56232337106050265
@@ -628,6 +660,7 @@ MonoBehaviour:
UnityEngine.AnimationModule, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null]]"},"player_arm_model":{"_value":[],"_name":"player_arm_model","_id":"245b0981-0791-4429-8175-0620b823c70d","$type":"NodeCanvas.Framework.Variable`1[[System.Collections.Generic.List`1[[UnityEngine.Renderer,
UnityEngine.CoreModule, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null]],
mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]]"},"weapon_root":{"_value":14,"_name":"weapon_root","_id":"940c9dd0-4ce8-4696-828b-4839a0d5bf32","$type":"NodeCanvas.Framework.Variable`1[[UnityEngine.Transform,
UnityEngine.CoreModule, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null]]"},"player_weapon":{"_value":15,"_name":"player_weapon","_id":"d3f87a0d-377a-4f04-9203-1f51274eeb4c","$type":"NodeCanvas.Framework.Variable`1[[UnityEngine.Transform,
UnityEngine.CoreModule, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null]]"}}}'
_objectReferences:
- {fileID: 0}
@@ -645,6 +678,7 @@ MonoBehaviour:
- {fileID: 6041155785600406570}
- {fileID: 31900000, guid: cca2613b82a49a9499858e9db9304015, type: 2}
- {fileID: 8704381047114730674}
- {fileID: 9198065390282780830}
_serializedVariables:
- _json: '{"_value":1,"_name":"player_view","_id":"a28d2c46-f3d5-4d32-85f0-cc2c7005f888","$type":"NodeCanvas.Framework.Variable`1[[UnityEngine.Transform,
UnityEngine.CoreModule, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null]]"}'
@@ -725,6 +759,11 @@ MonoBehaviour:
_references:
- {fileID: 0}
- {fileID: 8704381047114730674}
- _json: '{"_value":1,"_name":"player_weapon","_id":"d3f87a0d-377a-4f04-9203-1f51274eeb4c","$type":"NodeCanvas.Framework.Variable`1[[UnityEngine.Transform,
UnityEngine.CoreModule, Version=0.0.0.0, Culture=neutral, PublicKeyToken=null]]"}'
_references:
- {fileID: 0}
- {fileID: 9198065390282780830}
--- !u!114 &2519517685296362873
MonoBehaviour:
m_ObjectHideFlags: 0

View File

@@ -8,6 +8,7 @@ using Microsoft.Extensions.DependencyInjection;
using Microsoft.Extensions.Logging;
using Net.BITKit.Localization;
using Net.Like.Xue.Tokyo.UX;
using Net.Project.B.AI;
using Net.Project.B.Chat;
using Net.Project.B.PDA;
using Net.Project.B.UX;
@@ -82,6 +83,10 @@ namespace Net.Like.Xue.Tokyo
@"http://server.bitfall.icu:21982/net.like.xue.tokyo/net.like.xue.tokyo.localization.csv";
await global::Project.B.Program.BuildServiceProvider(serviceProvider,destroyCancellationToken);
serviceProvider.QueryComponents(out AIHumanService aiHumanService);
aiHumanService.DamageOnBreakDialogue = 30;
var uxService = serviceProvider.GetRequiredService<IUXService>();

View File

@@ -20,7 +20,8 @@
"GUID:44495f3f3cb105748baf59ecacd464c6",
"GUID:6efaa16b661faf94188fd63eda46f87c",
"GUID:ecc5a2501a2c44d4cb8366674714f3d9",
"GUID:68e8cf1a3c026044da8fe2f07f7de963"
"GUID:68e8cf1a3c026044da8fe2f07f7de963",
"GUID:8f79dfa3edfa9514b8f6d7d2f0102ccc"
],
"includePlatforms": [],
"excludePlatforms": [],

View File

@@ -10,6 +10,7 @@ using BITKit.WorldNode;
using Cysharp.Threading.Tasks;
using Microsoft.Extensions.DependencyInjection;
using Net.Project.B.Emoji;
using Net.Project.B.Health;
using Net.Project.B.Interaction;
using Net.Project.B.Quest;
using Net.Project.B.UX;
@@ -35,6 +36,10 @@ namespace Net.Like.Xue.Tokyo.UX
[Inject]
private IEmojiService<AnimationClip> _emojiService;
[UXBindPath("health-bar")]
private ProgressBar _healthBar;
public UXHud(IUXService uxService, IGameMapService gameMapService, IWorldInteractionService interactionService, IQuestService questService, UXRadialMenu radialMenu, IPlayerFactory playerFactory, IEntitiesService entitiesService, IUXKeyMap<InputAction> uxKeyMap) : base(uxService)
{
_gameMapService = gameMapService;
@@ -79,9 +84,20 @@ namespace Net.Like.Xue.Tokyo.UX
private UniTask OnEntityCreated(string arg1, IEntity arg2)
{
arg2.Inject(this);
arg2.ServiceProvider.QueryComponents(out IHealthComponent healthComponent);
healthComponent.OnHealthChanged += OnHealthChanged;
OnHealthChanged(healthComponent.HealthPoint,healthComponent.HealthPoint);
return UniTask.CompletedTask;
}
private void OnHealthChanged(int arg1, int arg2)
{
_healthBar.value = arg2;
}
private void OnInteraction(object arg1, IWorldInteractable arg2, WorldInteractionProcess arg3, object arg4)
{
switch (arg3)

View File

@@ -15,6 +15,11 @@
</ui:VisualElement>
<ui:Slider label="时间" high-value="24" name="time-slider" show-input-field="false" focusable="false" style="display: none;" />
</ui:VisualElement>
<ui:VisualElement name="PLAYER" style="position: absolute; left: 32px; bottom: 32px;">
<ui:VisualElement style="background-color: rgba(0, 0, 0, 0.5); width: 128px;">
<ui:ProgressBar value="37.1" title="Expose" name="health-bar" style="margin-top: 0; margin-right: 0; margin-bottom: 0; margin-left: 0;" />
</ui:VisualElement>
</ui:VisualElement>
<ui:VisualElement name="mark-container" picking-mode="Ignore" class="root">
<ui:Instance template="ui_mark-template" name="ui_mark-template" class="selected" />
<ui:Instance template="ui_mark-template" name="ui_mark-template" />

View File

@@ -19,7 +19,7 @@ MonoBehaviour:
m_Scale: 1
m_ReferenceDpi: 96
m_FallbackDpi: 96
m_ReferenceResolution: {x: 1280, y: 720}
m_ReferenceResolution: {x: 1920, y: 1080}
m_ScreenMatchMode: 0
m_Match: 0.421
m_SortingOrder: 0