Search found 128 matches

by Deckhead
Mon Apr 20, 2020 1:20 am
Forum: Game Development
Topic: openAl sound
Replies: 37
Views: 54117

Re: openAl sound

Yes. You adjust the AL_MAX_DISTANCE and AL_REFERENCE_DISTANCE. The latest article here should help you https://indiegamedev.net/2020/04/12/the ... ng-sounds/
by Deckhead
Fri Apr 17, 2020 5:52 am
Forum: Game Development
Topic: The Last Boundary
Replies: 9
Views: 18647

Re: The Last Boundary

I'd been having some difficulty in determining how to make my game a little more interactive. I never intended to make a Visual Novel, but here I am. So I've done a bit of research into various ways Visual Novels have made their product a little more interactive. Combat seems to be the big thing, wh...
by Deckhead
Thu Apr 16, 2020 8:20 am
Forum: Game Development
Topic: openAl sound
Replies: 37
Views: 54117

Re: openAl sound

BTW I'd love to see your game.
by Deckhead
Thu Apr 16, 2020 8:19 am
Forum: Game Development
Topic: openAl sound
Replies: 37
Views: 54117

Re: openAl sound

Attenuation happens automatically so long as you set the position and velocity as you're doing now. In regards to waiting a few seconds... Are you multithreading your engine? It's not a good idea to wait a few seconds, what you should do is have some sort of flag or signal notify a system that it ca...
by Deckhead
Wed Apr 15, 2020 10:19 am
Forum: Game Development
Topic: openAl sound
Replies: 37
Views: 54117

Re: openAl sound

Well, it's hard to say without seeing all of your code in it's entirety. I can see that you are dereferencing the vehicles so they're likely pointers to the actual vehicles, in which case your code looks like it should work. If you're getting that AL_INVALID_NAME error on the alSource3f calls, the o...
by Deckhead
Wed Apr 15, 2020 2:18 am
Forum: Game Development
Topic: openAl sound
Replies: 37
Views: 54117

Re: openAl sound

AL_INVALID_NAME only occurs in alSource3f when the source ALuint that you're providing is not valid. Looking at your code, I believe you might want to be using an auto& in your initialisation loop. Otherwise you're assigning values to a copy of a Component::Vehicle , not the Component::Vehicle ...
by Deckhead
Tue Apr 14, 2020 8:29 pm
Forum: Game Development
Topic: null
Replies: 2
Views: 11075

Re: GRANDIOSE DELUSIONS - I made a 1-bit visual novel

Like I said on itch, I like this game. It feels like Death Note just a little bit.
by Deckhead
Tue Apr 14, 2020 8:21 pm
Forum: Game Development
Topic: openAl sound
Replies: 37
Views: 54117

Re: openAl sound

Mckl wrote: Tue Apr 14, 2020 9:45 am Oh so instead of calculation relative position between vehicle player and some car source(where car is relatively to listener) I can just put listener position and source position.
Yes, exactly. OpenAL will calculate relative distance between listener and source for you.
by Deckhead
Tue Apr 14, 2020 9:22 am
Forum: Game Development
Topic: openAl sound
Replies: 37
Views: 54117

Re: openAl sound

Ahh not sure how, should I combine velocities somehow? You set the position and velocity of your listener and set the position and velocity of the sources. You set these every frame, independently of the others. That's all you need to do, you don't need to calculate anything else, OpenAL will under...
by Deckhead
Tue Apr 14, 2020 7:55 am
Forum: Game Development
Topic: openAl sound
Replies: 37
Views: 54117

Re: openAl sound

Yes definitely.