Ambiera ForumDiscussions, Help and Support. |
|
| [ 1 2 3 ] Page 2 of 3 |
|
|||||
|
Wa-a-a-ait a minute... Are you like, dividing 'offset' variable by a vector length? ... offset / Math.sqrt(Math.pow(actualPos.x - posPlayer.x, 2) + Math.pow(actualPos.y - posPlayer.y, 2) + Math.pow(actualPos.z - posPlayer.z, 2)) If so, you can make it a fair bit better, by, first, making a variable for the afforementioned length (because I doubt that you really need to calculate the same thing a bunch of times, waste of performance) ...and, second, just simplify it ... |
||||
|
good idea, i'll try it! |
||||
|
Yep, works better. Thanks! |
||||
|
Oh, and one more thing. You might've already figured this out, but you can also do the division part with the 'length' variable before the rest. Like ...Didn't think about that initially, but I'll leave this here just in case. After all, I was the one who said: I doubt that you really need to calculate the same thing a bunch of times, waste of performance
|
||||
|
Hi winterdev, how does the final product look like now? Can you show it via youtube? |
||||
|
I don't see why not (: https://www.youtube.com/watch?v=... |
||||
|
Good job It seems to be a hlitchy a bit, but i don't know whether the recording software is the issue or not But, its great, I recommend you use dynamic lighting and lights, and also you use new game assets from online, these will make your gane look more polished |
||||
|
Don't thank me, the better version is Dekon's. But i kept my own if the player tries to lift something really heavy and the gun malfunctions, that's where my code executes. Here's the thing: I do use dynamic lighting and lights. But, i am planning to use downloaded game assets. |
||||
|
That is absolutely great, i wish you luck, feel free to share your progress with the community, Are you on Discord? |
||||
|
um.. no, but im that kinda person who would create an account for one person so in a Schrodinger's cat way, i am. |
||||
|
Okay i logged in my name is 'WinterDev :3' |
||||
|
Which server did you join? |
||||
|
None. i tried to find coppercube game developer servers but i did not find any.. can you recommend me a server? |
||||
|
Did not find one so i created my own https://discord.gg/4cwSAqC9 |
||||
|
Oh okay i've joined, here they are, i recommend joining both https://discord.gg/kCUtR42m >>This is my server https://discord.gg/afk3hq7j >>This is the actual discord server dedicated to Coppercube |
||||
| [ 1 2 3 ] Page 2 of 3 |
|
|