local EventAction_EnableInfBullets = { } -- 触发器激活时,将执行Action的Execute function EventAction_EnableInfBullets:Execute(...) if UGCGameSystem.IsServer() then UGCEventSystem.SetTimerLoop(UGCGameSystem.GameState, function() local AllPlayerPawn = UGCGameSystem.GetAllPlayerPawn() for i, PlayerPawn in pairs(AllPlayerPawn) do for k, ShootWeaponEnum in pairs(ShootWeaponEnums) do local Weapon = UGCWeaponManagerSystem.GetWeaponBySlot(PlayerPawn, ShootWeaponEnum) if UE.IsValid(Weapon) then UGCGunSystem.EnableClipInfiniteBullets(Weapon, true) -- Weapon:ForceModifyCurrentBulletNumInClipOnServer(UGCGunSystem.GetMaxBulletNumInOneClip(Weapon)) end end end end, 0.5 ) end return true end return EventAction_EnableInfBullets