@LeeC2202
I take it you're well knowledged in programming.
Edit: I just thought about the way you did it in more detail, and it makes perfect sense. This thread has made me 'slightly' better at math.
@LeeC2202
I take it you're well knowledged in programming.
Edit: I just thought about the way you did it in more detail, and it makes perfect sense. This thread has made me 'slightly' better at math.
@LeeC2202
Yeah it's whatever, Math gives me a headache. I was providing a way to figure it out by using 255 as a reference.
By starting at 255, you could divide 255 and cut it in half or double it, and that's another way of working that out. I followed the same procedure you did actually only I used seconds in the second place. The difference is the fact that I got a headache while doing it and you likely didn't.
255;-=2/s(1000ms)
Would better be interpreted as 255 / 2000ms * (1000ms)
Although I didn't realize changing the 2nd numbers to ms, and multiplying it by the third would give the answer to his question. But at least I did the math correctly.
I barely knew what I was doing and ended up with the same order of events sort of lol. I think I got confused when the amount of time passing between each decrement was unclear as he stated 'each millisecond'
255 / TotalTimeInMilliseconds) * elapsedMillisecondsPerFrame
@LeeC2202
"What amount of value would I need to decrease each millisecond so it is 0 when the x amount of milliseconds have passed?"
You would need to decrease 1 each millisecond so it's 0 when 255 amount of milliseconds have passed.
You would need to decrease 0.5 each millisecond so it's 0 when 500 amount of milliseconds have passed.
You would need to decrease 0.3 each millisecond so it's 0 when 765 amount of milliseconds have passed.
You would need to decrease 0.25 each millisecond so it's 0 when 1020 amount of milliseconds have passed.
That's the way I read it.
The way you did it is more logical, that's just the way I would think of working it out, I couldn't figure out the procedure in such a simple formula in my head like you could, I have to think about it.
My approach to this problem was starting like this.
We know that if we have 255, that it will be 0,
If decreased by 1 every millisecond, that it would take 255 milliseconds to get to down to 0.
If we divide 255 by 2, it would take half the time. Now we're reducing it twice as fast.
If decreased by 2 every millisecond, it would take 127.5 milliseconds.
You could start cutting the milliseconds in half if you needed to, 1 millisecond is 1000 microseconds. Reduce it by 1 every millisecond or reduce it by 1 every half a millisecond if you can only take 1 at a time away. There's many ways to do it, it depends on exactly what you need to do.
So from that point you just divide 255 by 3, 4 or 5 and that's how many milliseconds it would take to reduce 255 to 0.
255 - 5 every millisecond = 51 milliseconds.
So, what hellacious script are you working on now? It's not that car spawning script is it?
I'm not good at math either but, assuming you mean What amount of value would you need to decrease per second, so it is zero when X amount of milliseconds have passed. If you mean what value you would need to decrease per millisecond then you would be dealing with microseconds, and there are 1000ยตs(Microseconds) in a single millisecond. In that case, this would start to get confusing for me. Reducing 255 to 0, would take 255 microseconds if decreased at a rate of 1 per microsecond. It would take half that time if decreased at a rate of 2 per microsecond. I'm pretty sure I'm correct, but like I said. I'm not good at math. ๐ So let's see here.. We have a integer of 255, if we take 1 from that every 1000 milliseconds, it's gonna be at 0 in 255,000 milliseconds, or 255,000,000 microseconds. If we take 1 from it every 500 milliseconds, it would be at 0 in [Now Divide 255 by 2 and get 127.5] half the time.
255; -=1/s(1000ms)=[4.250 Minutes] 255s {255000ms}
255;-=2/s(1000ms)= [2.125 Minutes] 127.5s {127500ms}
255;-=3/s(1000ms)= [1.416 Minutes] 84.96s {84960ms}
255;-=4/s(1000ms)= [1.060 Minutes] 63.60s {65600ms}
255;-=5/s(1000ms)= [0.850 Minutes] 51.00s {51000ms}
So if you reduce 255 by 5 every 1000ms, those are the times it would take to reach 0.
Reducing 255 to 0 takes 255,000 milliseconds if reduced by 1 every 1000 milliseconds.
Reducing 255 to 0 takes 127,500 milliseconds if reduced by 2 every 1000 milliseconds.
Reducing 255 to 0 takes 84,960 milliseconds if reduced by 3 every 1000 milliseconds.
Reducing 255 to 0 takes 65,600 milliseconds if reduced by 4 every 1000 milliseconds.
Reducing 255 to 0 takes 51,000 milliseconds if reduced by 5 every 1000 milliseconds.
Do you have any Ibuprofen now?![]()
@JimmyG said in Marking your favourite mods:
@rappo thanks didnt knew. But would be cooo to see the bookmarked mods of other persons. Like you can set the bookmarks on private or on public
Hence why I suggested bookmarks to be renamed to favorites, it seems more general. Then in account settings.
[Checkbox] Make my favorites public.
Good idea.
@AHK1221 I've had fun with 99999 mass before, but I never tried using '1'. It actually acts like the vehicle has a lot of mass, but immediately damages and destroys your engine sometimes, like I said. It's a really interesting effect. If you drive at a fair rate of speed and hit a pedestrian of another car, the camera shakes in a very cool realistic effect.
If there was a way to trigger that camera shake every time something is hit, that would definitely need to be a mod. Actually the effect I was getting was from the mass being 99999, and I just didn't realize it because my car acted weird and came to a stop and wouldn't move anywhere, which gave me the illusion that the mass was at 1 but in reality the engine was destroyed. When I use this to reinitialize a new value like 1000 in to it, or 1 for some reason it's not working and only worked the first time. Will have to keep testing it.
Edit: Just die and respawn, and the values will re-initialize.
@AHK1221 said in What is the future of GTA V Modding?:
Any developers know if it's possible to alter vehicle handling data in-game? There aren't any handling injection mods out there and the only one that I ever found doesn't work.
This seems to work:
https://www.gta5-mods.com/tools/real-time-handling-editor
Just tested it out, went from putting 99999 mass on a Sultan with 1 mass.
Really interesting result. ๐
@AHK1221 I sort of thought about that. ยฏ\(ใ)/ยฏ
But my confusion originated from not knowing 'exactly' what it is that scripthook does. I may have forgot, or never knew. I just know it had something to do with allowing mods to be installed in GTA V, not knowing the actual programmatic function of it.
@AHK1221 Right. What API are we referring to? Is Scripthook an API? I've not well knowledged in these areas of programming yet, forgive my confusion. However, I'm starting to get in to programming now, rather than just the typical HTML/CSS and XUL I'm used to using. I'm upset with the lack of knowledge in this area. There are many people who want to make modifications, and have no idea where to even start, and it can be difficult to get results and answers to some questions via google. I like that in this community we all seem to be working together, and that's a great thing and I think the sharing of knowledge and information that is taking place is also a great thing.