2017-04-07 15:01:20

Hello to all of you on the forum.
I want to know the following:
I want to make audiogames with python.
I want them to have screen_reader surport, and i want sound positioning aswell, and i want the sound to pan.
Whitch good library will work for me??
I am using python 2.7.13
I have tryed to use pyaudiogame, but it is not that good at all. it just has screen reading surport.
I tryed audio-game-kit for python created by mason, but every time i run an example script, i get the error, no module named agk.misk.
So please help if you can.
thanks

best regards
never give up on what ever you are doing.

2017-04-07 17:47:37

You'll have to use multiple libraries to achieve that. For screen reader support you could use accessible_output or Tolk or some of those libraries. For audio purposes I recommend libaudioverse, which is a bit complicated, but you can ask for help on this forum. But just don't forget that you'll need some framework which does the key handling and screen display for you, just use pygame or pyglet or some comparable package for your purposes.
Best Regards.
Hijacker

2017-04-07 21:52:14

My choices for the requirements you've described are as follows.

Audio: The excellent libaudioverse library by camlorn, with the environment node and source nodes for 3-dimensional sound positioning.
Screenreader output: accessible_output2 by ctoth.
Keyboard, mouse, events and screen: The pyglet library. You didn't mention this in your original post, but you'll need it if you want to do an audiogame.
networking: Twisted. Again, you didn't mention this but if you want anything that isn't single player you'll most likely need to talk to a server somewhere. Python of course has the built in socket and socket server modules, but twisted abstracts things away for you and handles corner cases.

Regards,
Blademan
Twitter: @bladehunter2213

2017-04-08 11:27:04

Thanks to all of you for your help.
This rely helps me.
I already have accessable_output 2 installed, and also for libaudioverse.
Now my question is, Are there any example audiogames writen in any one of this librarys?
If there are, can any one please give me a link to them?
thanks.

best regards
never give up on what ever you are doing.

2017-04-09 06:18:06

Hi Ashley.
Well I was going to answer your questions but you got some really nice posts so that's good. Anyway, I don't know of too many source code games written in python. There was a fighting game called luta, that had it's source code included, butt that's gone as far as I know. The only other one I can think of is usa blackjack, but the usagames sight is down so I don't know where to get blackjack. It's possible i might have a copy of usa blackjack, I'll take a look. I don't have a copy of luta, I know that for sure. If your looking for just general source code stuff there are a couple of sights that have small programs which are open source these will help you to learn. I'm new to this stuff too so I can understand what your going through.
Hth.

Guitarman.
What has been created in the laws of nature holds true in the laws of magic as well. Where there is light, there is darkness,  and where there is life, there is also death.
Aerodyne: first of the wizard order

2017-04-09 11:02:13

Thank you guitarman That you understand.
I can maby find a few soft ware source codes, but they are not always accessable for the blind with screen readers. So i actualy want to try making audiogames.
Thanks

best regards
never give up on what ever you are doing.

2017-04-09 16:15:47

RSGames is written in python 2.7. although, this game is really slow and laggy and i doubt you really want to base you code off of them. I'm not really sure if the lag is their algorithms or what, but its not good. also, soundRTS is written in python 2.7 I believe. that is a good game and open source. Rockwaters at http://rockywaters.co.uk writes all of his stuff in python. those games contain graphics and he has done a great job with his stuff.

I don’t believe in fighting unnecessarily.  But if something is worth fighting for, then its always a fight worth winning.
check me out on Twitter and on GitHub

2017-04-09 23:44:30

If you cannot find example code, another option is to write your own example code. If I am trying to learn how to use a framework and the code examples do not help, I will often write small little programs to try to learn pieces of the framework.

2017-04-10 00:04:25

Hello Ashley.
Oh that's right I forgot about soundrts and rs games. I've never played rs games. Sound rts is really cool although I did not know it was open source. Last time I saw it, it was a pyc file which is just a compiled python file. If rs games does have lag than I wouldn't use it as an example.
I would suggest like hektor said, that you write and test your own code to see if it works properly. This has nothing to do with making audiogames, but if you want to get a little more familiar with python, read the free online version of learn python the hard way. It's easy to understand and it's what I'm using to teach myself python.
Hth.

Guitarman.
What has been created in the laws of nature holds true in the laws of magic as well. Where there is light, there is darkness,  and where there is life, there is also death.
Aerodyne: first of the wizard order

2017-04-10 07:34:13

Hello.
My only problem is that i don't have a lot of knollage with python.
i only have a little bit of knolage with BGT.
But i don't think that i have enough knolage with python that i am able to write my own example python scripts.
Is there any good python learning python options.
i have heard about learnpytyhonthehardway.org, but i tried it.
I am afraid that they are going to move to python 3, and i am still using python 2.7.13
i don't want to switch python versions now, because i could almost say that i am more used to python 2 than i am to python 3.
Thanks

best regards
never give up on what ever you are doing.

2017-04-10 08:17:56

Hello.
Don't worry the free online version is for python 2.7. You can buy the book that's written for python 3 but you really don't need to. You can read the free book easily it sticks to python 2.7 so you have nothing to worry about.
You said you don't know much about python. Well let me ask you. Can you print text to the screen? Can you make variables and perform operations on them? Can you use statements and loops to do things?
If the answer is yes to all of these then you probably are at a good starting point. You might not be ready to write a masterpiece, but you would be off to a good start with python.

Guitarman.
What has been created in the laws of nature holds true in the laws of magic as well. Where there is light, there is darkness,  and where there is life, there is also death.
Aerodyne: first of the wizard order

2017-04-10 11:32:48

Hello guitarman, i can do all of those things that you mesioned.
then i m going to continue.

best regards
never give up on what ever you are doing.

2017-04-10 18:44:20

ZedShaw the author of LPTHW isn't going to python 3. Long story short, he hates it and tries to convince everyone its awful as well. That doesn't mean you should learn python 2 from him, but it is something to think about. I'll leave searching for his posts on why python 3 is evil incarnate up to you.

I don’t believe in fighting unnecessarily.  But if something is worth fighting for, then its always a fight worth winning.
check me out on Twitter and on GitHub

2017-04-10 22:09:47

If you do not have a lot of knowledge about python, this might be the best time to switch to using python 3. Most of the basics are similar. Is there anything particular you are looking for in a python tutorial?

2017-04-11 03:45:23

Hi.
I did not know about this, I just saw an add on his website that said he was writing learn python 3.6. I don't want to read posts about how python 3 is bad, I will probably use it someday so I don't want to turn against it before I know anything about it. It's strange that he's so against python 3, maybe he's afraid of moving forward.
I figure I'll stick with python 2 for now, because most of the programmers I've talked to say python 2 has at least 4 or 5 more years before it's taken out. I think nvda is written in python 2, although they might have upgraded it to python 3 after all this time.

Guitarman.
What has been created in the laws of nature holds true in the laws of magic as well. Where there is light, there is darkness,  and where there is life, there is also death.
Aerodyne: first of the wizard order

2017-04-11 04:25:33

What are the other options for liaudioverse? I was looking at it earlier and I am not sure I would recommend using that library for a new python programmer. It looks like it is a good library for audio, but the setup is a bit involved for beginners.

2017-04-11 06:02:27

@Guirtarman
I don't think its a fear of moving forward, so much as how puerile and arbitrary he finds Python 3 to be. I won't get into it either, but if you feel so inclined do a bit of reading on the subject and decide for yourself.

The other option would be PyAL or Pyglet if you want to expand its OpenAL bindings, you'd need to install OpenAL as well though, so maybe just as involved as libaudioverse. I do have some example scripts around though.

-BrushTone v1.3.3: Accessible Paint Tool
-AudiMesh3D v1.0.0: Accessible 3D Model Viewer

2017-04-11 06:41:57 (edited by Hrvoje 2017-04-11 06:44:25)

Regarding LibAudioVerse and how hard or easy it is for beginners, you can't make game with 3D sound with no experience in programming at all. You really can't. There's no beginner friendly 3D library. OpenAl for Python as an alternative is even harder to use, as all functions are low-level type. As a beginner, you're best to go with 2D sound and Pygame. Don't use Pyglet, you'll get confused. Use Pygame as it's more beginner friendly, then after you get some experience you can try switching to Pyglet vs. Libaudioverse combination.
And, regarding Python3, it certainly has some really nice features that I like, especially some implemented in 3.6, but compatibility with external libraries is still worse than with Python2. Therefore, it's quite normal that some devs don't wanna switch to or even recommend Python3.

2017-04-11 07:17:33

Hello all.
I feel that i want to stick with python 2, because there are a lot of libraries for python 2.
more than there is for python 3.
Nvda is writen in python 2, yes, because i think that wxpython is still in development for python 3.
and learnpythonthehardway.org is a very nice book to read. and i agree, a first programmer like me, will not use 3d audio in a game yet, altho i have libaudioverse and pyglet installed on my computer.
thanks

best regards
never give up on what ever you are doing.

2017-04-11 20:05:11

@Hektor.
I'm confused, what about libaudioverse setup is difficult at all?
The manual has examples, you can install the library with one command (pip install --pre libaudioverse), and if you don't understand something, you can ask the libaudioverse mailing list which is specifically for that purpose.

While I agree that someone new to python might not want to try a full 3-d game for their first project (I'm a fairly experienced python coder and making my 3-d game has definitely caused me some head scratching), I don't believe libaudioverse is the cause of this; it's simply the considerations and choices you have to make as far as how your game will operate, how you will load and save maps and the map state, etc.
If you know of specific considerations I've missed here concerning libaudioverse, please let me know - I'd also be happy to provide examples for those not sure how to do something with the library if I understand how to do it.

Regards,
Blademan
Twitter: @bladehunter2213

2017-04-13 13:05:24

I would be interested in knowing where you found the information on using pip to install libaudioverse because I missed that somewhere. Also, why are you using the --pre option for pip install?

2017-04-13 14:52:57

I just said pip install libaudioverse.
i can not remember the exact spelling, but i did it. i can run some of mason's projects with python, and they use libaudioverse.

best regards
never give up on what ever you are doing.

2017-04-13 15:19:39

--pre installs prereleases, source.

--Pre gets you the latest version, usually a few commits behind the head of Master.

--pre is recommended at this time because until 1.0, Camlorn's mostly going to release alphas.

2017-04-13 15:33:18

so how do i use the pre?

best regards
never give up on what ever you are doing.

2017-04-13 15:36:52

As Blademan mentioned above, just type pip install --pre libaudioverse, and to update type pip install --upgrade --pre libaudioverse