[Release] [ALPHA] "Arma III" Styled Missions

OgCl
i will not sleep tonight
wiiiiiîiiiiiii
:ok_hand:

1 Like

I have another update to 2.9.5 in a little bit, to fix a desync bug for clients joining when random missions are running. Just caught that with some more playtesting.

2.9.5d which fixes a bug with clients not synching up when joining when a random generated mission is being played:
https://www.mediafire.com/file/nu4yxjgm3ooti6c/mrp-missions-2.9.5d.zip/file

You are thinking that using netids might improve efficiency because the entity iterator method is too intensive? It’s possible but it would be unfortunate – I like the solution you are using now and it avoids many potential complications using netcode. It would be ideal if one could confirm resource use of one technique vs another. I thought I read something recently in the FiveM updates thread about being able to do this but I can’t remember.

As for resource manifest and CreateObject, I did notice a report of a similar problem causing some scripts to revert back to manifest 44febabe-d386-4d18-afbe-5e627f4af937.

On the other hand, ghermans in Cops-FiveM seems to be using the latest 05cfa83c-a124-4cfa-a768-c24a5811d8f9 and still creating props in menu.lua. Not sure what is up there.

1 Like

sixsens, I’m not sure this release will solve the problems that you experienced on your server with high numbers of players. My main aim was getting this to a point that was playable at least on a LAN, hopefully online as well with some coordination with players as a gametype maybe, where the host player can be counted on to be online.

Mission16 for instance will be hard if you cannot see blips across the map for players, but at least players will know where to defend based on the marker. Same with some of the defend target missions, they will see a start and end blip, but the target NPC may veer off somewhere else if being chased by an enemy.

Cheers Loque, that might be what I am running into re: createobject.

You are thinking that using netids might improve efficiency because the entity iterator method is too intensive?

It has crossed my mind, but I would imagine that its only when an object changes on the host/or client that net traffic is being generated, but maybe decor is more expensive. Sixsens server is very cool RP, first time I visited an RP server , and it has a ton of mods running as well, and I saw a lot of errors from other scripts in the console. I’m not sure if that has something to do with the lag as well, which is why playing with more players on a more vanilla server might be a better test,or maybe not. Saying that, the host is still very important, and if they disconnect it’s not a show stopper, but certain NPCs may stop doing their assigned tasks etc… until the next mission. I put in some loops for all clients to run every 10 seconds to workaround this, but enough is enough… I thought, and also that did not seem to work very well.

I should time the entity iterator, part of my optimization after sixsens feedback was to remove 4 loops into 1 loop… it appears to be moe than quick enough when I have my 2 clients at home (my old laptop as well as host), my main game state loop is calling it once every second (I should probably shorten this), I do not experience any noticeable hitches beyond what I get with vanilla Fivem (even when I had the 3 redundant loops :grinning:
There are other loops too that happen as well though, that I can also probably remove a couple that are not need and definitely other tidy up.

I did notice that the code that showa a message in the middle of the screen when securing an objective no longer show via triggerevent, so I use chat message. I’m not sure if this is due to a bottle neck, or just a silly error somewhere I am not seeing, since I have the same code running for buying at the safe house and it works fine.

One thing I am not doing as well is SetModelAsNoLongerNeeded in my code.

1 Like

had the middle finger pointed at me by hateful NPCs during my playtesting more than I can remember…
:rofl:

1 Like

yes i have some error cause im in a dev phase… and one or 2 script need attention…
As we talk now those error doenst exist no more.

some ressource can be harmful sometime…
I will try testing new built with a minimum of ressource just to see.

ill give feedbaxk around 2am

minor update 2.9.5.e to fix some misspellings and z axis of spawns of some safehouses being too high
2.9.5.e
http://www.mediafire.com/file/t675fhhmu85d0e5/mrp-missions-2.9.5e.zip/file

1 Like

and another update, to 2.9.5f
https://www.mediafire.com/file/qd17atfddjl7kme/mrp-missions-2.9.5f.zip/file

I have been doing some real playing through the first mission without using invulnerability etc…and maybe since I am a more casual player who uses a joypad, I found that adding a regeneration option for health, and around 2000 health for crackdown mode made it real fun for me atm. These are not turned on by default (unlike crackdown mode, which I will turn off by default in the next update), since this is not true Arma type gameplay.
To enable regen health (I dont think the armour regen works), like in halo, in missions.lua:
Config.RegenHealthAndArmour = true
(all credit to mman0385’s original mod.)
Players who earned some type of cash reward for the mission can optionally receive full health and armor at the mission completion with:
Config.RegenHealthAndArmourOnReward = true

Finally, this is experimental, but with it turned on, when you respawn it will take you back to the current mission safehouse, if safehouses are enabled.
Config.TeleportToSafeHouseOnSpawn = true

I’m also seeing that it would be good to have safe house vehicles and aircraft spawn near the safehouse too. Maybe have 3 locations near each air strip.

2 Likes

best built so far. 2.9.5.f
no more lag.
autostart work great
Timer is better… still have some desync in time but the worst desync was 29 sec. Meaning mission stop and 30 seconde left. happens once.

everything is much better.

some issue…
when the host go offline. Sometime… the npc (ennemy and friendly) disapear for everyone.

Only the host see npc blip on map from far away.
everyone else see if close to them.

ressource is still on after 17 hours… no error no lag.

You can be proud. This is big deal ressource.
Stable.
Still have many new option to test.
Cheers my dude

I miss the progrees text 5…4…3…2…1… :sweat_smile:

my bad… esx was ok… go back to what it was…
go back to all pay the player and put back both line like they were. Sorry.

2 Likes

Thank you for testing sixsens, :slight_smile: , glad to hear it is more stable for you.

I have one final update for my alpha branch from this resource, which I added after my own playing through some of the missions properly. I will probably create a new thread soon for this version of LanceGood’s resource and credit LanceGood and his resource which influenced/inspired me to work on this. Everything I added is built around what he created. I put a ton of effort into this over the last month to get it to a decent point, while I have the time, which I wont have as much anymore.
v2.9.6
http://www.mediafire.com/file/eqiu1k8d2ci1222/mrp-missions-2.9.6.zip/file

Features:
–Fixes many bugs, like in regular missions, driving=true attribute is working again.
–There are now only 3 safe house locations, at Los Santos Airport, Desert Airstrip, Military Base. The safe house vehicles/aircraft and safehouse boats are all near each other and the main safehouse. When a random mission is spawned, the resource spawns the closest of the 3 safehouses to the mission (unless <500m away).
–Config.TeleportToSafeHouseOnMissionStart = true teleports players 5 seconds after the start of the new mission to the safehouse to start the mission together. If you are in a vehicle it will spawn you with the vehicle at the vehicle safe house location just outside the main safe house.
–The IsDefendTarget Ped is more buff now, to stop them dying so quickly. They have 100 armor and 600 health by default… can be changed via: Config.IsDefendTargetMaxHealth. Have a new Mission20 which has a couple of random IsDefendTarget mission where you need to defend a target ped from being eliminated by hostile NPCs with melee weapons and some with pistols.
–Capture Objective and Rescue Hostage messages are back @sixsens … I missed them too :slight_smile:

All these values can be changed globally, or overridden per mission.

I have decided to release 2.9.6 with the config I like to play atm. This creates its own server gamemode, where everyone is participating. When players come to the server, they will ‘travel’ to the safehouse to start the mission if there is a mission in progress. When a mission ends, there is the mission space time which I have set to 30 seconds.Enemies drop their weapons now, which I found was helpful with Mission19 ‘Warfare’ where there are a lot of enemies, where players might run out of ammo. So the 30 seconds gives players some time to pick up ammo (and get back to their vehicles as well), then when the next mission starts, they all ‘travel’ to the safehouse for the next mission. This puts everyone on a more ‘equal’ footing when the mission starts.

Also Config.RandomMissions = true which means mission progress is random, so all missions, regular and/or IsRandom (random mission generator mission) the mission chosen will be random.

I have health regen enabled, and health/armor renewal when getting any type of reward for the mission. For safehouses, I have SafeHouseTimeTillNextUse = 3 minutes, something small, I may even turn it off, since the cost I set to be $2000, same with safehouse vehicle cost. You can claim up to 2 safehouse vehicles per mission as well. If you are in your safehouse vehicle when the next mission start you get to keep it (unless it is a boat) and it will ‘travel’ with you.
Oh yeah, I also have SafeHouseCrackDownMode = true, with the health at 2000, so you get the fast run & swim and super jump as well.

This all leads to a more fast pace game style, of competitive co-op. All these features, like safehouses etc… can be turned off or changed to be more arma-esque in missions.lua, so a server can run this resource as side missions etc… as well. the balance of NPC weaponry/vehicles vs safehous vehicles/weaponary no doubt needs a lot of tweaking as well, which I haven’t playtested enough, but can also be changed.

I will post a well commented version of missions.lua online to explain how to configure everything as well, and to create your own missions.

there was one bug I got for a joining client that happened once, that I tried very hard to reproduce, it was around line 740, but was not able too… it might be a wierd timing issue, but if it crops up again, will try and fix it.

EDIT: @sixsens, I did test the regular pickups again with my 2 clients. Both saw mission and reward pickups. And if one was able to pickup the pickup object due to low ammo, it vanished for both. Mission and Reward pickups also disappeared for both if not picked up. I did have them both teleport to the spawn locations to test this. I’m really not sure what is going on with what we saw when testing before, this was another reason why I created the safehouse option for getting pickups etc…, due to potential wierdness with normal pickups… also the safehouse can more easily be configured to also give weapon components.
I also wanted to add a player distance check when regular missions and random mission spawned, but since I am using safe house mission teleport, there is no need for me to do it, since players will be moved away anyway at mission start. I may add it in a future version.

2 Likes

ok ill update with this one…

why
Config.EnemiesCanSpawnPickups = false
doesnt work anymore…
npc seem to always spawn weapon now.

Oh yeah… Config.EnemiesCanSpawnPickups is doing special spawns by the resource over the dead body that could be removed by the resource. Now I have the native function having them all spawn weapons.
I can add a flag to disable the native weapon spawns. I can add add a flag for you to turn off.

if you can ill apreciate.
thanks a lot.
:star_struck:

Here you go:
2.9.6b
http://www.mediafire.com/file/2b17uggv9kjwdza/mrp-missions-2.9.6b.zip/file

SetPedDropsWeaponsWhenDead set this to false to stop native weapon dropping.
There is now:
EnemySpawnedPickupsChance which is the chance that a dead ped will drop the special pickups at mission end.
spawnableWeapons array in client.lua has now been moved to EnemySpawnedPickups array in missions.lua.

Also finally added code that stops players from being wanted by police. If you want to remove this, look for the code right under: “–remove wanted level

2 Likes

awesome dude… Im on it.
Cant say how much im happy about all that man.
Dude of the dude.

1 Like

there was a typo in one line…
line 3091in client.lua change “input” to “MissionName”
http://www.mediafire.com/file/3ldt15s6ll4md0t/mrp-missions-2.9.6c.zip/file

Work !! :slight_smile:

10/10

Now ill go try to built some more mission with the millions of options :sunglasses:
Best Resource Ever!

1 Like

Thanks man, glad it is working for you… and I appreciate all the testing and feedback.

I will post on pastebin a detailed description of missions.lua and all the options over the weekend.

I also found a bug in the health regen, which I fixed. It’s also enhanced so that if you take damage, it resets the time till regen counter, so you have to find cover etc… also, if you are running,/sprinting shooting, etc…it will reset… (credit to Agent Pineapple’s Vitality mod)

http://www.mediafire.com/file/wciec4ge8c3fcuh/mrp-missions-2.9.6d.zip/file