@mcal9909 Funniest one, strangest, and only happened once, while testing a driving script which i had run 100s of times without incident, suddenly a car stops in front of my vehicle (which is auto driving through script). My vehicle rear ends the vehicle and a couple occupants get out and start a firefight with another vehicle, completely random.
But it gets better. After the occupants of the car are killed, a jogger running by (NPC) stops, looks at the car, gets in and drives away. Too funny again.
P.S. You have to admit the ped in my video, well she's one badass.
And here is the prop positioning part added. You will never get it perfect, but this is infinitely easier than a trainer and you can just rerun it if you need to. Sensitivities can be adjusted if you are striving for perfection.
@JohnFromGWN Ok I figured this out. Classic PEBKAC or ID10T.
My code was executing perfectly, it was the display that was misleading.
For example, i had 35 which became 70, and 36 which become 72.
Since my display showed 70 and 72, i wrongly concluded it was adding 2.
Display should have been 35 to 70, 36 to 72.
And again many thanks for showing me how to get the correct event handler.
P.S. I should have known better as well because I write VBA code for Excel regularly.
What's nice is you can also nest a slider inside a submenu. You can use integers or strings as selections.
Just as a quick example, here I've nested a peds customization list inside a submenu with integers (strings would be more descriptive but choices were limited so integers were fine for the demo).
Again this isn't meant to replace any trainer, just a way to highly customize favourites or use this to setup a project for machinima or missions....or just fun sandboxing in the open world.
@JohnFromGWN Another thing I've noticed recently is that there are definitely some "bad" mods out there - either due to poor conversion, outdated, or maybe polygon counts in the millions.
A bad vehicle model can be harder to troubleshoot because it may only crash your system as you spawn other vehicles - rarely when they are spawned alone.
This may be my problem... I'm currently trying to trouble shoot a problematic "mod", a car mod which I'm sure is the culprit of my crashing. I don't want to hijack this thread with the plethora of questions I have but, I will agree with your statement on trouble shooting bad models.
@IAmJFry Good choice. In passing, if you use the list with strings, there is an error in the wiki documentation which the author acknowledged (brief comment exchange). He prefers to use enums but I can vouch that the strings work perfectly with one catch. The first item will not show up in the first slot as it does for integers - the solution is very simple, just leave first slot blank, first item goes in second slot.
private static readonly NativeListItem<String> MyList = new NativeListItem<String>("My Description", "", "Item 1", "Item 2", "Item n"); // nothing between the description and Item 1 except for the double quotes.
@Jitnaught Thanks again for the clarifications and sharing. I think I did something similar, but with VB.Net.
I broke up what was really 1 script into 4 pieces, using Partial. I think C# uses the same keyword?
It was also the first time I used Namespace, I normally omit it, but this time it was necessary. I had really done this just to organize my code. Cheers.
P.S. I was sloppy with my declarations, should have just written
Public Ped0, Ped1, Ped2 As Ped, etc