Ok I’m bored say something

If you want to handle 3D movement, grab your forward vector and multiply that by a new vector3 that consists of your horizontal and vertical input, do not apply anything to the Y.

var direction = object.transform.forward * vector3(h, 0, v);

A cool trick if you handle analogue movement is to grab the lenght of the input if it's a vector
let magnitude = input.lenght()

then add that when calculating the velocity

velocity = direction * speed * magnitude

this will let you smoothly handle analogue input, if the player moves the stick slowly the object will move accordingly instead of reaching it's maximum velocity.

you could mimic this with lerp if you are using keyboard input but might require additional input.
 
If you want to handle 3D movement, grab your forward vector and multiply that by a new vector3 that consists of your horizontal and vertical input, do not apply anything to the Y.

var direction = object.transform.forward * vector3(h, 0, v);

A cool trick if you handle analogue movement is to grab the lenght of the input if it's a vector
let magnitude = input.lenght()

then add that when calculating the velocity

velocity = direction * speed * magnitude

this will let you smoothly handle analogue input, if the player moves the stick slowly the object will move accordingly instead of reaching it's maximum velocity.

you could mimic this with lerp if you are using keyboard input but might require additional input.
Call The Midwife Help GIF by PBS

Did AI put you up to this point?
 
It's okay to stab a dragon with a wooden stake because it's not illegal.
 
I have a crippling addiction to Fire Emblem and being given random compliments by strangers, especially by men since I am attracted to them.

That being said, these two addictions contradict each other. I live in a world of very little joy.
 
I have a crippling addiction to Fire Emblem and being given random compliments by strangers, especially by men since I am attracted to them.

That being said, these two addictions contradict each other. I live in a world of very little joy.
We could see an upcoming Fire Emblem title for Nintendo Switch 2 soon, don't give up hope yet
 
here's a random thing that keeps popping up in my head.

ive been using vscode for a while before moving to neovim. neovim is great, i'm so grateful that i can move around quickly. unfortunately, setting up plugins and all that is a pain - it is such a pain compared to vscode. sometimes it's the plugins that makes or break the code editor.

as someone who enjoys building sites for fun - testing my API endpoints is an important part of the workflow. thunderclient on vscode does this masterfully. unfortunately there's not really an alternative to that on neovim, and i have to result to writing the whole endpoint, headers, and req body manually in a curl statement and pipe responses through jq.

if i'm testing only a few endpoints that's ok. but if i'm building a "full-stack" site, i'm gna have a lot of API endpoints and writing the whole curl statement over and over again is a chore so i end up opening vscode just for thunderclient. a lot of neovim users who think they're superior to users of other code editors just say "ooo just use curl" but tech is there to make things better in your life, so why wld i make it harder for myself by using curl statements.

if there's a good plugin like thunderclient on neovim i'd be grateful. i don't care if it's a curl wrapper as long as it takes away the cumbersome process of writing the whole curl statement in the terminal.

in the absence of it, i'll try to build my own.
 
We're pushing
down in a hole right before our eyes.
The rising heat and the melting ice.
Now all we care for is
Blood & Satellites.
 
my anus is having a nice day.png

please don't click unless you have a sick sense of humor also it's kinda NSFW (this might get modded but i did spoiler it and did a warning about it
 
Using enums for simple state handling in your games is the best approach but only if your entity will have a specific state at a given time like: idle, moving, shooting but if there's more complex states like in the air shooting, considers a state machine pattern with objects and a multi layered approach.

Also think of ways of passing values to states, a dictionary works.
 

Users who are viewing this thread

Connect with us

Support this Site

RGT relies on you to stay afloat. Help covering the site costs and get some pretty Level 7 perks too.

Featured Video

Latest Threads

Sega Offline Games List

Hi folks, was wondering if someone could help me find something. Years ago, on my older college...
Read more

Cool Dreamcast Hardware

The Dreamcast has a ton of great hardware variants. It’s like they saw what...
Read more

New Sales and Deals from Nintendo Store

Fullbleed-Sales-Desktop.jpeg

Nintendo launches huge blockbuster sale. There is a huge sale now running in the...
Read more

Is a Boku No Natsuyasumi PSP/PS1 English port being worked on?

So there is a Spanish patch of this once only Japanese PSP/PS1 game...
Read more

Online statistics

Members online
150
Guests online
236
Total visitors
386

Forum statistics

Threads
12,630
Messages
308,060
Members
867,575
Latest member
pharostick

Advertisers

Back
Top