From 63b909fdd51ebfa7a7da1d994e80334d383c3432 Mon Sep 17 00:00:00 2001
From: automatic9045 <67314487+automatic9045@users.noreply.github.com>
Date: Wed, 1 Nov 2023 23:28:07 +0900
Subject: [PATCH] =?UTF-8?q?feat:=20[=E3=82=AF=E3=83=A9=E3=82=B9=E3=83=A9?=
=?UTF-8?q?=E3=83=83=E3=83=91=E3=83=BC]=E3=83=9E=E3=83=83=E3=83=97?=
=?UTF-8?q?=E3=82=AA=E3=83=96=E3=82=B8=E3=82=A7=E3=82=AF=E3=83=88=E3=81=AE?=
=?UTF-8?q?=E9=80=9A=E9=81=8E=E6=99=82=E3=81=AB=E9=80=9A=E7=9F=A5=E3=81=99?=
=?UTF-8?q?=E3=82=8B=E3=82=A4=E3=83=99=E3=83=B3=E3=83=88=E3=82=92=E8=BF=BD?=
=?UTF-8?q?=E5=8A=A0?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../ClassWrappers/Public/MapObjectList.cs | 20 +++++++++++++++++++
Libs/BveTypes/WrapTypes/5.8.7554.391.xml | 6 ++++++
Libs/BveTypes/WrapTypes/6.0.7554.619.xml | 6 ++++++
3 files changed, 32 insertions(+)
diff --git a/Libs/BveTypes/ClassWrappers/Public/MapObjectList.cs b/Libs/BveTypes/ClassWrappers/Public/MapObjectList.cs
index 9fa03c6d..99540feb 100644
--- a/Libs/BveTypes/ClassWrappers/Public/MapObjectList.cs
+++ b/Libs/BveTypes/ClassWrappers/Public/MapObjectList.cs
@@ -28,6 +28,8 @@ private static void Initialize(BveTypeSet bveTypes)
CurrentIndexGetMethod = members.GetSourcePropertyGetterOf(nameof(CurrentIndex));
CurrentIndexSetMethod = members.GetSourcePropertySetterOf(nameof(CurrentIndex));
+ ObjectPassedEvent = members.GetSourceEventOf(nameof(ObjectPassed));
+
GoToAndGetCurrentMethod = members.GetSourceMethodOf(nameof(GoToAndGetCurrent));
GoToMethod = members.GetSourceMethodOf(nameof(GoTo));
}
@@ -62,6 +64,21 @@ public int CurrentIndex
set => CurrentIndexSetMethod.Invoke(Src, new object[] { value });
}
+ private static FastEvent ObjectPassedEvent;
+ ///
+ /// の値が変更されたときに発生します。
+ ///
+ public event ObjectPassedEventHandler ObjectPassed
+ {
+ add => ObjectPassedEvent.Add(Src, value);
+ remove => ObjectPassedEvent.Remove(Src, value);
+ }
+ ///
+ /// イベントを実行します。
+ ///
+ /// 自列車が通過したマップ オブジェクト。
+ public void ObjectPassed_Invoke(ObjectPassedEventArgs args) => ObjectPassedEvent.Invoke(Src, new object[] { Src, args.Src });
+
private static FastMethod GoToAndGetCurrentMethod;
///
/// コレクションの指定した距離程に対応する要素へ移動し、それを取得します。
@@ -79,5 +96,8 @@ public MapObjectBase GoToAndGetCurrent(double location)
///
/// 移動先のインデックス。
public void GoTo(int index) => GoToMethod.Invoke(Src, new object[] { index });
+
+
+ public delegate void ObjectPassedEventHandler(object sender, ObjectPassedEventArgs e);
}
}
diff --git a/Libs/BveTypes/WrapTypes/5.8.7554.391.xml b/Libs/BveTypes/WrapTypes/5.8.7554.391.xml
index 9a4612a5..32387015 100644
--- a/Libs/BveTypes/WrapTypes/5.8.7554.391.xml
+++ b/Libs/BveTypes/WrapTypes/5.8.7554.391.xml
@@ -524,11 +524,17 @@
+
+
+
+
+
+
diff --git a/Libs/BveTypes/WrapTypes/6.0.7554.619.xml b/Libs/BveTypes/WrapTypes/6.0.7554.619.xml
index 9a4612a5..32387015 100644
--- a/Libs/BveTypes/WrapTypes/6.0.7554.619.xml
+++ b/Libs/BveTypes/WrapTypes/6.0.7554.619.xml
@@ -524,11 +524,17 @@
+
+
+
+
+
+