Jump to content

Xonyne88

Members
  • Posts

    36
  • Joined

  • Last visited

1 Follower

Profile Information

  • Country
    Romania
  • Gender
    Male

Recent Profile Visitors

333 profile views

Xonyne88's Achievements

Upstanding Citizen

Upstanding Citizen (2/12)

3

Reputation

  1. I will try to add these callouts in my callouts pack!
  2. Yes, I know, but I always like to set them first, it's just my preference.
  3. I don't think there are Detective plugins in the downloads section, but a quick search might help. It is possible that some developers will add this features to theirl plugins or callouts pack.
  4. To be honest, I agree with @Reddington's opinion. First of all, some of the plugins you specified might broke in future updates so it will possible break the game. Second, Reddington is right, in my opinion it's better for users to have the option to customize the game. This is my personal opinion.
  5. I am currently developing a callouts pack. After I finish it, I will add these features to my list for a future plugin!
  6. I always make a bool first and set it as false. Then I check if it is false and I set it to true in the if statement so it doesn't repeat, it works pretty okay for me. bool notificationDisplayed = false; // do this at the beginning (in your class, not in any method) public override void Process() { if(condition && !notificationDisplayed) { //do your thing notificatioDisplayed = true; } }
  7. Random ped: Ped ped = new Ped(); Random vehicle: Vehicle vehicle = new Vehicle();
  8. [WIP] MIXED CALLOUTS Description Today I'm starting the development of a new Callouts Pack called Mixed Callouts. The idea of this callout pack is to add callouts for everyone to play. Mixed Callouts will have callouts for every type of police officer: shootouts, chases and normal everyday callouts. My goal is to create realistic and some crazy callouts so you officers can have fun! Planned Callouts Casual Callouts All of these callouts have different outcomes! [WIP] Domestic Dispute between Family In this callout you will receive a 911 call regarding a Domestic Dispute. You are sent to investigate. [PLANNED] Injured Biker We received a 911 call regarding an injured biker in the middle of the street. [PLANNED] Car Crash Two cars crashed in traffic and the drivers called 911. Resolve the situation. [PLANNED] Missing pet Someone lost their pet, get to the scene and search for the missing animal. [PLANNED] Suspicious Activity In this callout you will receive a 911 call from a person who thought they heard/saw something weird happened. [PLANNED] 911 Hangup This callout features a high variety of outcomes, so is hard to explain here. Shootouts and chases All of these callouts have different outcomes! [PLANNED] Gang attack against an officer An officer is attacked by a well known gang. Go to the scene and resolve the situation. [PLANNED] Pursuit in Progress A criminal is resisting arrest. Pursue them and catch them. Read this Please note that I'm still developing this callouts pack so there might be more callouts. I was initially planning to add a train callout, but I didn't decide yet. So I am asking you, the reader, to give me callouts suggestions in this topic and ping me too. Special thanks to @Reddington for giving me ideas for callouts. I will update this post as progress continues.
  9. @Felix1212 put it instead of mySuspect.Tasks.FightAgainstClosestHatedTarget(200f, 1);
  10. First of all, we can't give you the full code. Second, you need a basic understanding of C#. I would love to help you, but you have to do something too. I recommend watching Albo's tutorials, I'm sure they will help ( also thanks @Albo1125 you made me start developing for Rage Plugin Hook and LSPDFR). If you have this knowledge, you can send me a PM or ping me here and I will see what I can do. @ktrain
  11. For people who can't find the class library in later versions of Visual Studio, it is called Class Library(.NET Framework) and it is under Visual C#.
  12. Now I have this problem. I have this code. First, I can only hear CITIZENS_REPORT IN, without the actual name of the crime. When I try to speak with the agent(press Y), nothing happens, even if I am close to him. This is my code: using System; using System.Drawing; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; using Rage; using Rage.Native; using LSPD_First_Response.Mod.API; using LSPD_First_Response.Mod.Callouts; using LSPD_First_Response.Engine.Scripting.Entities; using System.Windows.Forms; namespace Advanced_Policer.Callouts { [CalloutInfo("GangActivity", CalloutProbability.Medium)] public class GangActivity : Callout { public List<string> dialogWithCop = new List<string> { "~b~You~w~: Hello Agent! What's the situation? (1/10)", "~b~Agent James~w~: Hello Officer! A well known gang has been spotted. (2/10)", "~b~You~w~: Are they doing something illegal? (3/10)", "~b~Agent James~w~: We have reasons to believe that they are going to attend to a drug deal. (4/10)", "~b~You~w~: That's serious. Are they armed? (5/10)", "~b~Agent James~w~: We have been informed that the gang leader is armed with a ~r~Carbine Rifle~w~. (6/10)", "~b~You~w~: What's the plan? (7/10)", "~b~Agent James~w~: Try to arrest the suspects. (8/10)", "~b~You~w~: Alright! (9/10)", "~b~Agent James~w~: Let's get this done. (10/10)", }; public int dialogWithCopIndex; public LHandle pursuit; public Vector3 SpawnPoint; public Vector3 gangLeaderSpawnPoint; public Blip myBlip; public Ped FBIAgent; public Ped gangLeader; public Ped suspect1; public Ped suspect2; public Ped suspect3; public Ped suspect4; public Ped suspect5; public Ped suspect6; public Ped suspect7; public Blip gangLeaderBlip; public ECalloutState state; public override bool OnBeforeCalloutDisplayed() { gangLeaderSpawnPoint = World.GetNextPositionOnStreet(Game.LocalPlayer.Character.Position.Around(350f)); SpawnPoint = World.GetNextPositionOnStreet(Game.LocalPlayer.Character.Position.Around(200f)); FBIAgent = new Ped("s_m_m_fiboffice_02", SpawnPoint, Game.LocalPlayer.Character.Heading + 180); FBIAgent.BlockPermanentEvents = true; FBIAgent.IsPersistent = true; gangLeader = new Ped(gangLeaderSpawnPoint); gangLeader.IsPersistent = true; gangLeader.BlockPermanentEvents = true; if (!FBIAgent.Exists()) return false; this.ShowCalloutAreaBlipBeforeAccepting(SpawnPoint, 15f); this.AddMinimumDistanceCheck(5f, SpawnPoint); this.CalloutMessage = "Gang Activity"; this.CalloutPosition = SpawnPoint; Functions.PlayScannerAudioUsingPosition("CITIZENS_REPORT GANG_TRANSIT IN_OR_ON_POSITION", this.SpawnPoint); return base.OnBeforeCalloutDisplayed(); } public override bool OnCalloutAccepted() { GameFiber.StartNew(delegate { myBlip = new Blip(FBIAgent); myBlip.Color = Color.LightBlue; myBlip.EnableRoute(Color.Yellow); state = ECalloutState.EnRoute; Game.DisplayNotification("3dtextures", "mpgroundlogo_cops", "Officer", "", "Dispatch, I'm on my way."); GameFiber.Sleep(2500); Game.DisplayNotification("3dtextures", "mpgroundlogo_cops", "Dispatch", "", "Copy that officer, report to ~b~Agent James~w~ for briefing."); GameFiber.Sleep(2500); Game.DisplayNotification("3dtextures", "mpgroundlogo_cops", "Officer", "", "10-4. Responding Code ~r~3~w~."); }); Game.DisplaySubtitle("Speak with ~b~Agent James~w~.", 7500); return base.OnCalloutAccepted(); } public override void OnCalloutNotAccepted() { base.OnCalloutNotAccepted(); if (gangLeader.Exists()) gangLeader.Delete(); if (FBIAgent.Exists()) FBIAgent.Delete(); myBlip.Delete(); } public override void Process() { base.Process(); if (Game.IsKeyDownRightNow(Keys.End)) { EndCallout(); } if (gangLeader.IsDead || gangLeader.IsCuffed) { if (suspect1.IsDead || suspect1.IsCuffed) { if (suspect2.IsDead || suspect2.IsCuffed) { if (suspect3.IsDead || suspect3.IsCuffed) { if (suspect4.IsDead || suspect4.IsCuffed) { if (suspect5.IsDead || suspect5.IsCuffed) { if (suspect6.IsDead || suspect6.IsCuffed) { if (suspect7.IsDead || suspect7.IsCuffed) { EndCallout(); } } } } } } } } switch (state) { case ECalloutState.Talking: if (FBIAgent) { if (FBIAgent.IsAlive) { if (Game.LocalPlayer.Character.IsOnFoot) { if (Game.LocalPlayer.Character.DistanceTo2D(FBIAgent) <= 2) { if (Game.IsKeyDown(Keys.Y)) { Game.HideHelp(); if (dialogWithCopIndex < dialogWithCop.Count) { Game.DisplaySubtitle(dialogWithCop[dialogWithCopIndex]); dialogWithCopIndex++; } if (dialogWithCopIndex == dialogWithCop.Count) { suspect1 = new Ped(gangLeader.Position); suspect2 = new Ped(gangLeader.Position); suspect3 = new Ped(gangLeader.Position); suspect4 = new Ped(gangLeader.Position); suspect5 = new Ped(gangLeader.Position); suspect6 = new Ped(gangLeader.Position); suspect7 = new Ped(gangLeader.Position); suspect1.IsPersistent = true; suspect2.IsPersistent = true; suspect3.IsPersistent = true; suspect4.IsPersistent = true; suspect5.IsPersistent = true; suspect6.IsPersistent = true; suspect7.IsPersistent = true; suspect1.BlockPermanentEvents = true; suspect2.BlockPermanentEvents = true; suspect3.BlockPermanentEvents = true; suspect4.BlockPermanentEvents = true; suspect5.BlockPermanentEvents = true; suspect6.BlockPermanentEvents = true; suspect7.BlockPermanentEvents = true; gangLeader.Inventory.GiveNewWeapon("WEAPON_CARBINERIFLE", 9999, true); myBlip.Delete(); gangLeaderBlip = new Blip(gangLeader); gangLeaderBlip.EnableRoute(Color.Yellow); suspect1.RelationshipGroup = "RelSuspect"; suspect2.RelationshipGroup = "RelSuspect"; suspect3.RelationshipGroup = "RelSuspect"; suspect4.RelationshipGroup = "RelSuspect"; suspect5.RelationshipGroup = "RelSuspect"; suspect6.RelationshipGroup = "RelSuspect"; suspect7.RelationshipGroup = "RelSuspect"; Game.SetRelationshipBetweenRelationshipGroups("RelSuspect", "COP", Relationship.Hate); suspect1.Inventory.GiveNewWeapon("WEAPON_PISTOL", 9999, true); suspect2.Inventory.GiveNewWeapon("WEAPON_PISTOL", 9999, true); suspect3.Inventory.GiveNewWeapon("WEAPON_PISTOL", 9999, true); suspect4.Inventory.GiveNewWeapon("WEAPON_PISTOL", 9999, true); suspect5.Inventory.GiveNewWeapon("WEAPON_PISTOL", 9999, true); suspect6.Inventory.GiveNewWeapon("WEAPON_PISTOL", 9999, true); suspect7.Inventory.GiveNewWeapon("WEAPON_PISTOL", 9999, true); state = ECalloutState.OnScene; switch (state) { case ECalloutState.OnScene: if(Game.LocalPlayer.Character.DistanceTo2D(gangLeader) <=10) { gangLeader.Tasks.FightAgainstClosestHatedTarget(1000f); suspect1.Tasks.FightAgainstClosestHatedTarget(1000f); suspect2.Tasks.FightAgainstClosestHatedTarget(1000f); suspect3.Tasks.FightAgainstClosestHatedTarget(1000f); suspect4.Tasks.FightAgainstClosestHatedTarget(1000f); suspect5.Tasks.FightAgainstClosestHatedTarget(1000f); suspect6.Tasks.FightAgainstClosestHatedTarget(1000f); suspect7.Tasks.FightAgainstClosestHatedTarget(1000f); Game.DisplayNotification("3dtextures", "mpgroundlogo_cops", "Officer", "", "I'm under fire. Requesting S.W.A.T Team Alpha!"); Game.DisplayNotification("3dtextures", "mpgroundlogo_cops", "S.W.A.T Leader", "Alpha Team", "Copy that. S.W.A.T Team Alpha is en route."); Functions.RequestBackup(Game.LocalPlayer.Character.Position, LSPD_First_Response.EBackupResponseType.Code3, LSPD_First_Response.EBackupUnitType.SwatTeam); Functions.RequestBackup(Game.LocalPlayer.Character.Position, LSPD_First_Response.EBackupResponseType.Code3, LSPD_First_Response.EBackupUnitType.LocalUnit); Functions.RequestBackup(Game.LocalPlayer.Character.Position, LSPD_First_Response.EBackupResponseType.Code3, LSPD_First_Response.EBackupUnitType.LocalUnit); } break; } } } } } } } break; } } private void EndCallout() { Functions.PlayScannerAudio("ATTENTION_ALL_UNITS WE_ARE_CODE FOUR NO_FURTHER_UNITS_REQUIRED"); gangLeaderBlip.Delete(); gangLeader.Dismiss(); suspect1.Dismiss(); suspect2.Dismiss(); suspect3.Dismiss(); suspect4.Dismiss(); suspect5.Dismiss(); suspect6.Dismiss(); suspect7.Dismiss(); FBIAgent.Dismiss(); Game.DisplayNotification("3dtextures", "mpgroundlogo_cops", "Dispatch", "", "We are ~g~CODE 4~s~, good job officer!"); End(); } public override void End() { base.End(); } } public enum ECalloutState { EnRoute, Talking, OnScene, Code4 } }
  13. Also @PNWParksFan and you @LukeD, do I need to make a new gamefiber to use gamefiber.sleep in a callout?
  14. @PNWParksFan the blip still remains on the map.
×
×
  • Create New...