From 6c86b5159863792fd134492dbc932b0dae521160 Mon Sep 17 00:00:00 2001 From: Natashi <32347635+Natashi@users.noreply.github.com> Date: Mon, 7 Feb 2022 00:27:32 +0700 Subject: [PATCH] Added 2 more args to AddPatternA5 --- source/TouhouDanmakufu/Common/StgStageScript.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/source/TouhouDanmakufu/Common/StgStageScript.cpp b/source/TouhouDanmakufu/Common/StgStageScript.cpp index b49b8d05..3972f08c 100644 --- a/source/TouhouDanmakufu/Common/StgStageScript.cpp +++ b/source/TouhouDanmakufu/Common/StgStageScript.cpp @@ -385,7 +385,7 @@ static const std::vector stgStageFunction = { { "ObjMove_AddPatternA2", StgStageScript::Func_ObjMove_AddPatternA2, 7 }, { "ObjMove_AddPatternA3", StgStageScript::Func_ObjMove_AddPatternA3, 8 }, { "ObjMove_AddPatternA4", StgStageScript::Func_ObjMove_AddPatternA4, 9 }, - { "ObjMove_AddPatternA5", StgStageScript::Func_ObjMove_AddPatternA5, 9 }, + { "ObjMove_AddPatternA5", StgStageScript::Func_ObjMove_AddPatternA5, 11 }, { "ObjMove_AddPatternB1", StgStageScript::Func_ObjMove_AddPatternB1, 4 }, { "ObjMove_AddPatternB2", StgStageScript::Func_ObjMove_AddPatternB2, 8 }, { "ObjMove_AddPatternB3", StgStageScript::Func_ObjMove_AddPatternB3, 9 }, @@ -3195,6 +3195,8 @@ gstd::value StgStageScript::Func_ObjMove_AddPatternA5(gstd::script_machine* mach double agvel = argv[6].as_float(); double agacc = argv[7].as_float(); double agmax = argv[8].as_float(); + int idGraphic = argv[9].as_int(); + int idRelative = argv[10].as_int(); ref_unsync_ptr pattern = new StgMovePattern_Angle(obj); @@ -3206,6 +3208,9 @@ gstd::value StgStageScript::Func_ObjMove_AddPatternA5(gstd::script_machine* mach ADD_CMD2(StgMovePattern_Angle::SET_AGACC, agacc, Math::DegreeToRadian(agacc)); ADD_CMD2(StgMovePattern_Angle::SET_AGMAX, agmax, Math::DegreeToRadian(agmax)); + pattern->SetShotDataID(idGraphic); + pattern->SetRelativeObject(idRelative); + obj->AddPattern(frame, pattern); } return value();