Re: command line issues with unit tests java/node
Re: command line issues with unit tests java/node You can also pipe output to a text file, for example npm test 2> errors.txt to pipe stderr to a text file. For stdout, just use > instead of 2>. URL: https://forum.audiogames.net/post/622520/#p622520 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: command line issues with unit tests java/node
Re: command line issues with unit tests java/node You can also pipe output to a text file, for example npm test 2> errors.txt URL: https://forum.audiogames.net/post/622520/#p622520 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: problem with Note function mush client
Re: problem with Note function mush client Hey, this is an issue with mushclient combined with mush reader. I've had this issue before, I think if you use print instead of note it doesn't trigger it. URL: https://forum.audiogames.net/post/620534/#p620534 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: problem with Note function mush client
Re: problem with Note function mush client Hey, this is a issue with mushclient combined with mush reader. I've had this issue before, I think if you use print instead of note it doesn't trigger it. URL: https://forum.audiogames.net/post/620534/#p620534 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Extended PEMDAS.
Re: Extended PEMDAS. Hey regarding the randomization of the dice result (that is using a random number between the minimum and maximum possible dice roll), you should avoid doing that. This is because it changes the probability distribution of the results.For example say you rolled 2d6. The minimum is 2 (1+1) and the maximum is 12 (6+6). So you then have an equal chance of rolling a number between 2 and 12 (1/11), however that isn't how the roll would play out for a real pair of dice. URL: https://forum.audiogames.net/post/619094/#p619094 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Extended PEMDAS.
Re: Extended PEMDAS. Hey regarding the randomization of the dice result (that is using a random number between the minimum and maximum possible dice roll), you should avoid doing that. This is because it changes the probability distribution of the results.For example say you rolled 2d6. The minimum is 2 (1+1) and the maximum is 12 (6+6). So you then have an equal chance of rolling a number between 2 and 12 (1/11), however that isn't how the roll would play out for a pair of dice. URL: https://forum.audiogames.net/post/619094/#p619094 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Any tips for using Wireshark?
Re: Any tips for using Wireshark? What do you need to do with it? In general though you can hit alt to access the menu bar and start capturing from there and I believe all of the settings screens/etc are accessible. Once you've started capturing, tab from display filter and then hit down arrow to browse the captured packets. You may need to use object nav to view some information. If you tab from that list you get to a tree view of packet details (hitting right arrow will silently expand some sections, left arrow to collapse). Make sure it is using the right connection to capture from, that was my problem when originally trying to get this to work. URL: https://forum.audiogames.net/post/599964/#p599964 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: A Collision Tutorial and some important points
Re: A Collision Tutorial and some important points I think he was using l as the array size (length). URL: https://forum.audiogames.net/post/593365/#p593365 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Assistance with my settings class (Python)
Re: Assistance with my settings class (Python) @tunmi13 you only initialize sd within the try block so when that try block ends sd goes out of scope. Your later code tries to use it and then errors as a result. Your excepts are using the pass statement so you aren't seeing any errors. URL: https://forum.audiogames.net/post/591520/#p591520 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Question about lexing
Re: Question about lexing Do you have another token for the subtraction operation that's matching the - first? That could be interfering with it. URL: https://forum.audiogames.net/post/588701/#p588701 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Question about lexing
Re: Question about lexing Do you have another token for the negative operation that's matching the - first? That could be interfering with it. URL: https://forum.audiogames.net/post/588701/#p588701 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: how to let a python class accept more than 1 instent going?
Re: how to let a python class accept more than 1 instent going? hey make sure that any method you have on a class has self as the first parameter (the name technically doesn't matter, but the convention is self). This value (self) is used to refer to the class (self.somevar, etc). for exampleclass SomeClass: def __init__(self, name, x, y): #assign stuffinstance = SomeClass("name", 0, 1) #Notice how you only call the method with 3 parameters, not 4 but when you declare the method you use 4 URL: https://forum.audiogames.net/post/587866/#p587866 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: how to let a python class accept more than 1 instent going?
Re: how to let a python class accept more than 1 instent going? hey make sure that any method you have on a class has self as the first parameter (the name technically doesn't matter, but the convention is self). This value (self) is used to refer to the class (self.somevar, etc). for exampleclass SomeClass: def __init__(self, name, x, y): #assign stuff URL: https://forum.audiogames.net/post/587866/#p587866 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Pyglet help
Re: Pyglet help hey for python strings you can check using endswith, for example a.endswith('.flac') URL: https://forum.audiogames.net/post/574589/#p574589 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: NVDA Addon assistance
Re: NVDA Addon assistance split by default splits on ' '. Because a space is the separator, the spaces aren't included in the list. So with the example of " ln 1", the list you get from split is ['ln', '1']. Also try value instead of name, though I'm not too sure on that one. URL: https://forum.audiogames.net/post/568757/#p568757 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: NVDA Addon assistance
Re: NVDA Addon assistance split by default splits on ' '. Because a space is the separator, the spaces aren't included in the list. So with the example of " ln 1", the list you get from split is ['ln', '1']. URL: https://forum.audiogames.net/post/568757/#p568757 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Reviewing Pyglet
Re: Reviewing Pyglet From what I've seen, Pyglet doesn't lag. A lot of tutorials I saw in the past initialized the audio library with an audio buffer that is way too large which I think is what people were referring to. URL: https://forum.audiogames.net/post/554772/#p554772 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: sound positioning calculation not getting
Re: sound positioning calculation not getting Pan step is pretty much how many units of panning you get per unit of distance. So for example moving 1 step to the right might move the pan by 5 or something (5*1) URL: https://forum.audiogames.net/post/553426/#p553426 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: onclick attribute with innerHTML?
Re: onclick attribute with innerHTML? Each of the choices should look similar to this.choicesDiv.innerHTML = "Begin exploring."; URL: https://forum.audiogames.net/post/537827/#p537827 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: onclick attribute with innerHTML?
Re: onclick attribute with innerHTML? Each of the choices should look like this.choicesDiv.innerHTML = "Begin exploring."; URL: https://forum.audiogames.net/post/537827/#p537827 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: onclick attribute with innerHTML?
Re: onclick attribute with innerHTML? \" is the escape string yeah, but you're escaping the " in _javascript_, not for the innerHTML also. So when you use the \" in _javascript_, _javascript_ gets a " character, which is then added to the html string. When the html itself is parsed, it needs its own escaping. URL: https://forum.audiogames.net/post/537798/#p537798 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: onclick attribute with innerHTML?
Re: onclick attribute with innerHTML? I think the problem is that you aren't escaping the quotes correctly within the attributes on the generated buttons. For example, this code:choicesDiv.innerHTML = "Begin exploring.";This would generate the following html:Begin exploring.So the browser tries to parse the html, hits a quote after the (, thinks that's a closing quote for the attribute value and silently breaks. Do you get a console error after clicking the buttons? You can use to represent a " character in html. URL: https://forum.audiogames.net/post/537775/#p537775 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: If statements in Inform 7
Re: If statements in Inform 7 There are two forms of if statements. One of them reqres spacial indentation, for example. Note the : instead of semicolon after the ifif the player holds the backpack: say "Now that you have your backpack, you 're ready to enter!"; Now the player is in Storage Room;otherwise: Say "You don't want to go in there without your backpack.";the spaces indented indicate that your code is part of the block (that is will be executed when the if condition is true, or false in the case of the otherwise block). Alternatively you can write it like thisIf the player holds the backpack begin;Say "Now that you have your backpack, you 're ready to enter!";Now the player is in Storage Room;Otherwise;Say "You don't want to go in there without your backpack.";end;now you use end to end a block (instead of just removing the indentation)For the second case, I believe ending a line with a period instead of a semicolon ends the block to? I may be wrong on this, it's been a while. URL: https://forum.audiogames.net/post/527056/#p527056 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: If statements in Inform 7
Re: If statements in Inform 7 There are two forms of if statements. One of them reqres spacial indentation, for example. Note the : instead of semicolon after the ifif the player holds the backpack: say "Now that you have your backpack, you 're ready to enter!"; Now the player is in Storage Room.otherwise: Say "You don't want to go in there without your backpack.";the spaces indented indicate that your code is part of the block (that is will be executed when the if condition is true, or false in the case of the otherwise block). Alternatively you can write it like thisIf the player holds the backpack begin;Say "Now that you have your backpack, you 're ready to enter!";Now the player is in Storage Room.Otherwise;Say "You don't want to go in there without your backpack.";end;now you use end to end a blck (instead of just removing the indentation) URL: https://forum.audiogames.net/post/527056/#p527056 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: My problem in C
Re: My problem in C You have a space after the * but not before (that is, you have a* (b+c)). Try doing a*(b+c) or a * (b + c) URL: https://forum.audiogames.net/post/522319/#p522319 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: My problem in C
Re: My problem in C You have a space after the * (that is, you have a* (b+c)). Try doing a*(b+c) or a * (b + c) URL: https://forum.audiogames.net/post/522319/#p522319 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: C input?
Re: C input? Yeah this is an annoying problem in C that comes up a lot. You could set getIntInput to return an int pointer, likeint *getIntInput() {...}then just alter main accordingly. Alternatively you could set up some kind of struct with another int signifying whether or not an error occured. URL: https://forum.audiogames.net/post/499639/#p499639 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: C input?
Re: C input? Yeah this is an annoying problem in C that comes up a lot. You could set getInput to return an int pointer, likeint *getInput() {...}then just alter main accordingly. Alternatively you could set up some kind of struct with another int signifying whether or not an error occured. URL: https://forum.audiogames.net/post/499639/#p499639 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: How learn in Python on blind
Re: How learn in Python on blind You need to run python scripts from the command line if you're blind (that is, windows r, cmd, enter. If you don't know how that program works you should learn at least the basics before python in my opinion. Scripts are then launched by python filename (or py -3 filename or py -2 filename) depending on your setup and python version. Ignore all the stuff related to Idle GUI, it isn't accessible. Everything else in most tutorials should work without any alternative setup.You can also launch the python console (also known as python repl). this lets you type out single statements and get immediate results (if this isn't clear yet don't worry just continue with the tutorial). The >>> is the input prompt for the python repl. URL: https://forum.audiogames.net/post/482871/#p482871 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: How learn in Python on blind
Re: How learn in Python on blind You need to run python scripts from the command line if you're blind (that is, windows r, cmd, enter. If you don't know how that program works you should learn at least the basics before python in my opinion. Scripts are then launched by python filename (or py -3 filename or py -2 filename) depending on your setup and python version. Ignore all the stuff related to Idle GUI, it isn't accessible. Everything else in most tutorials should work without any alternative setup. URL: https://forum.audiogames.net/post/482871/#p482871 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: How learn in Python on blind
Re: How learn in Python on blind You need to run python scripts from the command line if you're blind (that is, windows r, cmd, enter. If you don't know how that program works you should learn at least the basics before python in my opinion. Scripts are then launched by python filename (or py -3 filename or py -2 filename) depending on your setup and python version. Ignore all the stuff related to Idle GUI, it isn't accessible. Everything else in most tutorials should b valid. URL: https://forum.audiogames.net/post/482871/#p482871 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: My problem in C
Re: My problem in C The above code is overly complicated and less efficient than a simple solution. You absolutely do not need a complicated sorting algorithm to find the minimum and maximum numbers in an array (besides, heapsort is O(n log n) and finding minimum and maximum of an array is just O(n) efficiency).The problem with the code is this sectionfor(i=1;ilist[ i ]) { minimum=list[1]; }//if closed. }//loop closedThe problem is that you are always comparing the current list item with the first or second (indexes 0 and 1), wihch means you won't end up with the accurate maximum or minimum. To get this to work, you need some base value for minimum and maximum to start out as, before the loop even begins. The first element in the array or list or whatever works (in this case set minimum and maximum to list[0]). Now you can iterate through the list. If the current element (list[i]) is less than minimum, simply set minimum to list[i]. Likewise if list[i] is greater than maximum, set maximum to list[i]. Also the for loop should start at i=0 not i=1. URL: https://forum.audiogames.net/post/466335/#p466335 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Prototyping game for blind players and need feedback
Re: Prototyping game for blind players and need feedback I feel like adding visual descriptors to descriptions is a good idea. It helps those who have had enough vision to visualize them. Blind people also have associations to words, for example they know which colors are brighter or that shiny might indicate value, even if they haven't experienced what those actually look like. URL: https://forum.audiogames.net/post/462823/#p462823 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Prototyping game for blind players and need feedback
Re: Prototyping game for blind players and need feedback I feel like adding visual descriptors to descriptions is a good idea. It helps those who have had enough vision to visualize them. Blind people also have associations to words, for example they know which colors or brighter or that shiny might indicate value, even if they haven't experienced what those actually look like. URL: https://forum.audiogames.net/post/462823/#p462823 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: My problem in C
Re: My problem in C Scanf does support negative number inputs. The same format specifiers (for the most part) that you'd pass to printf work for scanf in the same way. If you use %d (specifier for a normal signed int) it'll work. URL: https://forum.audiogames.net/post/462630/#p462630 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: My problem in C
Re: My problem in C That code isn't quite right, the tirnary comparison thing is an _expression_ so you should return the whole thing, also it's written differentlyint minimum(int a, int b) { return a < b ? a : b;}You don't need to do it this way, the more simple case is perfectly valid:int minimum(int a, int b) { if (a < b) { return a; } return b;}Like someone said above, you can treat negative numbers just like positive numbers so long as the data type supports them (which int does, so long as it isn't an unsigned int). URL: https://forum.audiogames.net/post/462596/#p462596 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Another question about pythonic syntax, yea!
Re: Another question about pythonic syntax, yea! @5 That is what is happening@3 That code is a list comprehension, which is kind of a for loop. The original list is not being changed directly by the list comprehension at all. This should be clearer with a slightly modified example.x = [1,2,3,4,5,6,7,8,9,3,3,4,5,4,3]y = [item for item in x if item!=3]The list comprehension is only interacting with the original because you told it to (by referencing x directly). All this is doing is repeating the item variable through x. If item is not equal to 3, it adds the number from x to the new list. If item is 3, it just does nothing because the condition if item != 3 is false. The two lists (x and y) are two completely different objects in the same way as two ints are different, even though they may hold the same number as a value. To remove all the 3's from x directly, you'd have to call some method on x, such as x.remove(3) multiple times or do it some other way.The reason the list changed originally in your example was because you set x equal to the new list. URL: https://forum.audiogames.net/post/436888/#p436888 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Another question about pythonic syntax, yea!
Re: Another question about pythonic syntax, yea! @5 That is what is happening@3 That code is a list comprehension, which is kind of a for loop. The original list is not being changed directly by the list comprehension at all. This should be clearer with a slightly modified example.x = [1,2,3,4,5,6,7,8,9,3,3,4,5,4,3]y = [item for item in x if item!=3]The list comprehension is only interacting with the original because you told it to (by referencing x directly). All this is doing is repeating the item variable through x. If item is not equal to 3, it adds the number from x to the new list. If item is 3, it just does nothing because the condition if item != 3 is false. The two lists (x and y) are two completely different objects in the same way as two integers are different, even though they may hold the same number as a value. To remove all the 3's from x directly, you'd have to call some method on x, such as x.remove(3) multiple times or do it some other way.The reason the list changed originally in your example was because you set x equal to the new list. URL: https://forum.audiogames.net/post/436888/#p436888 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Another question about pythonic syntax, yea!
Re: Another question about pythonic syntax, yea! you use [a for item instead of [item for item. Think of it like a for loop, the variable being referred to has to be the one looping through the list. Also keep in mind that you aren't removing anything from the list when using a list comprehension. In this case you're building a copy of the old list that does not contain 3. URL: https://forum.audiogames.net/post/436860/#p436860 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Another question about pythonic syntax, yea!
Re: Another question about pythonic syntax, yea! you use [a for item instead of [item for item. Think of it like a for loop, the variable being referred to has to be the one looping through the list. URL: https://forum.audiogames.net/post/436860/#p436860 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: error in python
Re: error in python @ethin that code is wrong. You use if i == 5, however i isn't declared anywhere and you should use count for that. Also you increment count after the if condition with the continue, so it will loop forever when count is 5 because count never increases. Your loop will also count 11, because when count is 10 it still triggers the loop.You could code it like thiscount = 0while count < 10: # Do this to avoid it printing 11 count += 1 if count == 5: continue print(count)input("Press enter to exit") URL: https://forum.audiogames.net/post/432905/#p432905 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Panning in IRR Klang
Re: Panning in IRR Klang I don't know which of the sound classes you're using, but you can look at the setPan method herehttps://www.ambiera.com/irrklang/docu/c … 78df5e8531 URL: https://forum.audiogames.net/post/422939/#p422939 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Quite weird problem with a C# code
Re: Quite weird problem with a C# code As far as I can tell, the call to write is occurring outside of the foreach loop, so it isn't actually writing each item to the file. URL: https://forum.audiogames.net/post/420481/#p420481 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Another question about sounds...
Re: Another question about sounds... An imported module only ever has a single instance. When another file imports a module, it's just given the reference to the already existing module instance. URL: https://forum.audiogames.net/post/414071/#p414071 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: I need help, again!
Re: I need help, again! I'm pretty sure iterating through the event queue is enough for pygame to handle it. URL: https://forum.audiogames.net/post/410508/#p410508 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: I need help, again!
Re: I need help, again! I did notice that in your code you call the pygame event pump function unnecessarily. It could be that function since you're calling it a lot. URL: https://forum.audiogames.net/post/410424/#p410424 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: I need help, again!
Re: I need help, again! The loop problems from what I can see aren't caused by Tolk. There are a few logic errors.In the menu module you haven't imported pygame. For every module you import that module needs to import required modules. K_UP and K_DOWN are defined in the pygame module itself, so those need to be pygame.K_UP and pygame.K_DOWN.The run function iterates through the event queue, which is fine. However as soon as the event queue is empty the program will stop executing. To fix this wrap the repeating menu logic (including the event queue iteration) in a while loop. URL: https://forum.audiogames.net/post/409489/#p409489 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: I need help, again!
Re: I need help, again! Normally the ^ operator is exponentiation (2^2 = 2 squared, 2^3 = 2 cubed, etc). In python though ^ is the bitwise xor operation. Python's exponentiation operator is ** (as in, 2**2 or 2**3).You can't directly reverse the modulus operation unless you know the number you were dividing by (call it d), the whole number part of the result (call it w), and the remainder (which mod finds, call it r). Mod returns a single number, so it would be impossible to tell which combination resulted. You could multiply the dividing number by the whole part (d*w) and add the remainder r to get back to the original number.For example, try 30%7 (30 mod 7). 30 divided by 7 results in 4 remainder 2. To get back to 30 you could do 4*7+2 (4*7 to get to 28, add the remainder of 2 to get to 30). Without having all 3 of those numbers the inversion would have been impossible. URL: https://forum.audiogames.net/post/405808/#p405808 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: I need help, again!
Re: I need help, again! Normally the ^ operator is exponentiation (2^2 = 2 squared, 2^3 = 2 cubed, etc). In python though ^ is the bitwise xor operation. Python's exponentiation operator is ** (as in, 2**2 or 2**3).You can't directly reverse the modulus operation unless you know the number you were dividing by (call itt d), the whole number part of the result (call it w), and the remainder (which mod finds, call it r). Mod returns a single number, so it would be impossible to tell which combination resulted. You could multiply the dividing number by the whole part (d*w) and add the remainder r to get back to the original number.For example, try 30%7 (30 mod 7). 30 divided by 7 results in 4 remainder 2. To get back to 30 you could do 4*7+2 (4*7 to get to 28, add the remainder of 2 to get to 30). Without having all 3 of those numbers the inversion would have been impossible. URL: https://forum.audiogames.net/post/405808/#p405808 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: I need help, again!
Re: I need help, again! Ord takes a character as input and returns the ascii value of that character, which in python is an integer. You are transforming the integer for the cipher, which is fine. You then call str on the result, which just turns the number into a string without actually converting the ascii code back to a character. If you replace the str call with chr (since it's only one character anyway), it should work.(edit)You call chr to convert the ascii back to a single character, not ord.(/edit) URL: https://forum.audiogames.net/post/405532/#p405532 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: I need help, again!
Re: I need help, again! Ord takes a character as input and returns the ascii value of that character, which in python is an integer. You are transforming the integer for the cipher, which is fine. You then call str on the result, which just turns the number into a string without actually converting the ascii code back to a character. If you replace the str call with ord (since it's only one character anyway), it should work. URL: https://forum.audiogames.net/post/405532/#p405532 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: While loop doesn't work correctly in Python + Pygame
Re: While loop doesn't work correctly in Python + Pygame this line has a problem while dlgAudio.isPlaying:You never actually call isPlaying as a function, so the while loop is just being passed the reference to the isPlaying function of the sound instance and not actually triggering the function. Since isPlaying is set and not a reference to null, it returns as true for the while loop and loops forever. Also is_busy may not directly correspond to whether or not a sound is playing, you may want to use pygame audio channels to make life easier. URL: http://forum.audiogames.net/post/404904/#p404904 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: While loop doesn't work correctly in Python + Pygame
Re: While loop doesn't work correctly in Python + Pygame this line has a problem while dlgAudio.isPlaying:You never actually call isPlaying as a function, so the while loop is just being passed the reference to the isPlaying function of the sound instance and not actually triggering the function. Since isPlaying is set and not a reference to null, it returns as true for the while loop and loops forever. Also is_busy may not directly correspond to whether or not a sound iss playing, you may want to use pygame audio channels to make life easier. URL: http://forum.audiogames.net/post/404904/#p404904 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: The Worst App in the World
Re: The Worst App in the World I believe collections in C# are indexed. Just iterate through the collection of voices and add each voice.VoiceInfo.Name to the combo box, then you can refer to the selected voice by just finding the current position of the user in the combo box. URL: http://forum.audiogames.net/viewtopic.php?pid=358594#p358594 -- Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Thaumistry and JAWS Compatibility
Re: Thaumistry and JAWS Compatibility I have no problems with ssh and NVDA regarding the cursor now. I believe either the 2017.3 or 2017.4 release fixed it. URL: http://forum.audiogames.net/viewtopic.php?pid=351472#p351472 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: What is the most accessible way to develop iOS apps?
Re: What is the most accessible way to develop iOS apps? If you have to use a Java IDE for class, Eclipse is the most accessible one that I've found. URL: http://forum.audiogames.net/viewtopic.php?pid=335440#p335440 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Is it me or is bgt really terrible with memory consumption
Re: Is it me or is bgt really terrible with memory consumption In C89 you have to declare all variables at the start of the function. Also doing something like for (int c=0;c < 5;c++) {} will just not work. C99 and C++ changed this. URL: http://forum.audiogames.net/viewtopic.php?pid=301000#p301000 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Is it me or is bgt really terrible with memory consumption
Re: Is it me or is bgt really terrible with memory consumption I believe a character is 1 byte which is composed of 8 bits.If you have a dictionary of 8100 strings, your programming shouldn't be freezing. The reason your math was off: think of a multidimensional array as a list of lists. This is simplified out to a grid so you have the first element at (0, 0). Which is essentially saying the first element of the first list of the array.The initialisation code above I think is wrong, it should be:void main(){ int[][][] test; test.resize(90); //No need to declare the variables before the for loop, you can declare them on the same line. for(uint i=0;i
Re: Python Help Needed
Re: Python Help Needed Regarding the filename part, are you specifying the name as a program parameter? If so, spaces could be breaking it.I'm not sure if the forum is removing part of the code, but that code should be throwing runtime errors. with open("{}".format(filename), "rb") as infile: infile.read()The infile.read() here is redundant because .read() returns the entire content of the file as a string. This isn't allocated to anything so it will just read the file and do nothing. You don't really need to format a string here either since there isn't really any other text in the string, you can just call with open(filename, "r") as infile instead. Also binary and textfiles are different, I recommend just going with the default "r" file mode. This is actually default so you don't even need to specify the second parameter of "r".for line in file: your input file is named infile. The type of the file object is file, so that code is literally trying to iterate over the type object of a file.If you do for line in infile, you may end up with some strange blank lines and characters, I don't really know why. Python actually has a readlines method on file objects so you can just call lines = infile.readlines() for example then iterate through those.You can use .replace(original, replacement) to replace characters. This also lets you replace them with the empty string. So you can just do line.replace("%", "") to remove all instances of a % character in a string. URL: http://forum.audiogames.net/viewtopic.php?pid=298647#p298647 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: C# (C sharp question)
Re: C# (C sharp question) To get around the control issue, tab between the controls you added to the form. Hit f4 to edit one. Expand the location attribute and you can set its coordinates on the form manually. This can get annoying after a while, but there are controls that lay out elements on the form for you. I believe it is called flowLayoutPanel but I can't fully remember. URL: http://forum.audiogames.net/viewtopic.php?pid=298273#p298273 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Coding A Life Sim In Inform 7
Re: Coding A Life Sim In Inform 7 It would be doable in Inform 7, but probably vastly more complicated than it would e in other languages. I recommend trying something like Python. Inform 7 can't easily handle arrays on objects/etc, the closest you can get to linking things together is via relationships. You can make many to many relationships, but it'd probably end up horribly labyrinthine and confusing. URL: http://forum.audiogames.net/viewtopic.php?pid=282654#p282654 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Coding A Life Sim In Inform 7
Re: Coding A Life Sim In Inform 7 It would be doable in Inform 7, but probably vastly more complicated than it would e in other languages. I recommend trying something like Python. URL: http://forum.audiogames.net/viewtopic.php?pid=282654#p282654 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: trigonometry in audio games, how do I apply the concept?
Re: trigonometry in audio games, how do I apply the concept? For a start, try this?https://www.khanacademy.org/math/geomet … igonometry URL: http://forum.audiogames.net/viewtopic.php?pid=273718#p273718 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Luna Stories 3d Audio Game Open Source c#
Re: Luna Stories 3d Audio Game Open Source c# Is there any chance you can put this on github or something? Keeping track of everything as a zip file is probably going to get convoluted and clunky as you go on. URL: http://forum.audiogames.net/viewtopic.php?pid=267805#p267805 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Codecademy's Python Course
Re: Codecademy's Python Course I'm pretty sure the problem with that example is that the Codeacademy course is using Python2 whereas you're using Python3. Just change the print line to print(now) and it should work. Print in Python3 is a function, not a keyword so parentheses are required.Python 2 and 3 do have some significant differences, such as division being integer by default in Python2 and all strings in Python3 using Unicode by default, in Python2 they are just standard. URL: http://forum.audiogames.net/viewtopic.php?pid=265814#p265814 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Codecademy's Python Course
Re: Codecademy's Python Course I'm pretty sure the problem with that example is that the Codeacademy course is using Python2 whereas you're using Python3. Just change the print line to print(now) and it should work. Print in Python3 is a function, not a keyword so parentheses are required. URL: http://forum.audiogames.net/viewtopic.php?pid=265814#p265814 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Codecademy's Python Course
Re: Codecademy's Python Course I'm pretty sure the problem with that example is that the Codeacademy course is using Python2 where as you're using Python3. Just change the print line to print(now) and it should work. Print in Python3 is a function, not a keyword so parentheses are required. URL: http://forum.audiogames.net/viewtopic.php?pid=265814#p265814 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: How to Determine a Column Conflict in Python
Re: How to Determine a Column Conflict in Python Just find the coordinates of the point and the queen. Find the difference in coordinates (say, dy for p2.y-p1.y) and the same for dx.Now you're subtracting one set from another, so you're essentially finding the location of the second queen compared to the first. If its a diagonal, the x and y distances have to be the same. Therefore, check the absolute values on dy and dx are equal. URL: http://forum.audiogames.net/viewtopic.php?pid=255019#p255019 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: How to Determine a Column Conflict in Python
Re: How to Determine a Column Conflict in Python Just find the coordinates of the point and the queen. Find the difference in coordinates (say, dy for p2.y-p1.y) and the same for dx.Now you're subtracting one set from another, so you're essentially finding the location of the second queen compared to the first. If its a diagonal, then the absolute value of dy/dx will be 1, because if its a diagonal, then it has to be the exact same x distance as y distance from the first one. Just remember if using python to make the values float first or could you get erroneous results. URL: http://forum.audiogames.net/viewtopic.php?pid=255019#p255019 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Some questions about bgt
Re: Some questions about bgt Move all of the code to intisde of the main function. You cant execute anything like an if statement etc outside of one. URL: http://forum.audiogames.net/viewtopic.php?pid=224555#p224555 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Python 2.7: name is not defined (when in fact it is)
Re: Python 2.7: name is not defined (when in fact it is) The problem is that you defined the habla function after you call it. That function doesnt exist in a python script until you define it. URL: http://forum.audiogames.net/viewtopic.php?pid=219254#p219254 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: BGT confusion
Re: BGT confusion Remember that programs run from top to bottom (kind of, at least in functions anyway).Your code is running the fleetmenu then commandmenu functions. Execution works something like this.Running fleetmenuRunning commandmenu (while still in fleetmenu)So you now have one function running as the previous one is running. When commandmenu stops running, then fleetmenu continues. Fleetmenu has nothing else to do, therefore it exits. Then I imagine this happens all the way back to the main function. When the main function ends, the program exits. I recommend using some form of while loop to prevent this at some level. URL: http://forum.audiogames.net/viewtopic.php?pid=209443#p209443 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Strangeness function bgt? ;Help please!
Re: Strangeness function bgt? ;Help please! Try adding a } before void game_play() { You dont have a closing } for the class, so its thinking that game_play is part of the enemy class. Forgive me if Im wrong, but I have limited time to check this. Also I think you dont have the correct number of closes on the void_play function. URL: http://forum.audiogames.net/viewtopic.php?pid=207760#p207760 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: sounds stop
Re: sounds stop There sadly is no way to do this, you have to stop each sound manually. You could look into the sound_pool class however. URL: http://forum.audiogames.net/viewtopic.php?pid=207763#p207763 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Strangeness function bgt? ;Help please!
Re: Strangeness function bgt? ;Help please! Try adding a } before void game_play() { You dont have a closing } for the class, so its thinking that game_play is part of the enemy class. Forgive me if Im wrong, but I have limited time to check this. Also I think you dont have the correct number of } on the void_play function. URL: http://forum.audiogames.net/viewtopic.php?pid=207760#p207760 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: The minimum environment for using VC++ compiler, cl.exe
Re: The minimum environment for using VC++ compiler, cl.exe I agree, thats kind of what I was pointing out. I kind of wish someone would draw this to the attention of Dark or something. URL: http://forum.audiogames.net/viewtopic.php?pid=206786#p206786 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: The minimum environment for using VC++ compiler, cl.exe
Re: The minimum environment for using VC++ compiler, cl.exe Mortal Kombat.Round 1. Camlorn vs Ethin. Fight.Oh wait, this isnt about Mortal Kombat or conflict? [[wow]], what an odd concept. I can imagine a forum where pointless redundant arguments dont consume the original topics point. this is a fundamentally difficult to understand concept, but Im sure that understanding can be achieved with sufficient time (IE: More than 5 seconds of thought put into it.) URL: http://forum.audiogames.net/viewtopic.php?pid=206784#p206784 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: The minimum environment for using VC++ compiler, cl.exe
Re: The minimum environment for using VC++ compiler, cl.exe Mortal Kombat.Round 1. Camlorn vs Ethin. Fight.Oh wait, this isnt about Mortal Kombat or conflict? [[wow]], what an odd concept. I can imagine a forum where pointless redundant arguments dont consume the original topics point. this is a fundamentally difficult to understand concept, but Im sure that understand can be achieved with sufficient time (IE: More than 5 seconds of thought put into it.) URL: http://forum.audiogames.net/viewtopic.php?pid=206784#p206784 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: programming a sidescroller game
Re: programming a sidescroller game You do not need math for a basic sidescroller. If your just starting out with something basic, you can just handle it with the 4 basic math operations. This includes 2 dimensions, but you probably wont get anything regarding angles, however its not really necessary if its a basic project. URL: http://forum.audiogames.net/viewtopic.php?pid=202357#p202357 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: BGT - a class question
Re: BGT - a class question That is class inheritance.Basically class inheritance allows for an object to based upon another, IE a webpage based upon a template possibly. the class inheriting from the base class now hsa access to the exact same methods and fields as the base class as they now apply to this one. Therefore its easier to make things such as different enemy types that all use the same base as a template, etc. URL: http://forum.audiogames.net/viewtopic.php?pid=201150#p201150 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Collision detection in 2d games when turning is a thing?
Re: Collision detection in 2d games when turning is a thing? I would personally use target_x-player_x, since if you do the reverse youll get the negative values of what they should be. URL: http://forum.audiogames.net/viewtopic.php?pid=197914#p197914 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Collision detection in 2d games when turning is a thing?
Re: Collision detection in 2d games when turning is a thing? I would personally use target_x-player_x, since if you do the reverse youll get the negative values of what they should be. Also you could totate both the object and the point about 0 0 by the angle of the tested object, so that if the point is within the target object, you can determine with a simple bounds check. URL: http://forum.audiogames.net/viewtopic.php?pid=197914#p197914 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Collision detection in 2d games when turning is a thing?
Re: Collision detection in 2d games when turning is a thing? I would personally use target_x-player_x, since if you do the reverse youll get the negative values of what they should be. Also you could rotate both the object and the point about 0 0 by the angle of the tested object, so that the tested object lies with a 0 angle to the x axis, so that if the point is within the target object, you can determine with a simple bounds check. URL: http://forum.audiogames.net/viewtopic.php?pid=197914#p197914 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Collision detection in 2d games when turning is a thing?
Re: Collision detection in 2d games when turning is a thing? Id personally do target_x-player_x, not the other way around because you can do the following.If you need to get the angle between an angle, you can use:angle = atan(sin(target_y-player_y)/cos(target_x-player_x))If you have a point at say 3, 3 and the player is at 1, 1, then you can subtract the players coordinates from the targets coordinates. Similarly, if the player is at 3 3 and the target at 1 1, then the relative difference between the 2 points is -2, -2, therefore you get the angle in the appropriate quadrant.If you do player_x-target_x, if the player is at 1 and the target at 2, you get a relative difference of -1, which is the negative of the correct distance. Similarly if the player is at -1 and the target at -2, -1-(-2) = 1, therefore you have the target appearing in the opposite direction. URL: http://forum.audiogames.net/viewtopic.php?pid=197853#p197853 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: how to make guis in python or more like how to import tkenter
Re: how to make guis in python or more like how to import tkenter Regardless of your operating system, packages and libraries seem to work better if you install the 32 bit version of python. URL: http://forum.audiogames.net/viewtopic.php?pid=196480#p196480 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: I want to get started with programming moos but I am not sure where to
Re: I want to get started with programming moos but I am not sure where to I honestly disagree with the points stated above. If you can get a simple core, such as lambdamoo, then you can start looking at how it works. If your looking for actual programs to run them, there are a number of resources. Id advise being familiar with a command line terminal before using one though.Resourceshttp://lisdude.com/moo/For a tutorial of actually using a moo db:http://cmc.uib.no/moo/yib/ URL: http://forum.audiogames.net/viewtopic.php?pid=195952#p195952 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: how to make guis in python or more like how to import tkenter
Re: how to make guis in python or more like how to import tkenter The package I believe is TkInter, not tkenter. When your importing make sure the cases match, python packages are case sensitive. URL: http://forum.audiogames.net/viewtopic.php?pid=194991#p194991 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Help with a do loop
Re: Help with a do loop Also.when you run the do loop, you dont actually call the menu for each loop iteration. so if you chose a result say 0, that do loop would execute forever and bog down your system. URL: http://forum.audiogames.net/viewtopic.php?pid=194944#p194944 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Help with a do loop
Re: Help with a do loop Also.when you run the do loop, you dont actually call the menu for each loop iteration. so if you chose a result say 0 or -1 after hitting escape, that do loop would execute forever and bog down your system. URL: http://forum.audiogames.net/viewtopic.php?pid=194944#p194944 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: While parcing statement block error
Re: "While parcing statement block" error The first issue I can see is:else if(choice==3){speech.configure();}//This should be an else statement.{while(choice!=0 and choice!=4);/*This line of code will do nothing whatsoever. A while loop executes the code within its block, IE enclosed within the braces. This loop will also execute if the loop is not equal to 0 or if the loop does not equal 4. This will trigger for the other menu choices. A while loop is a loop that executes when a given condition is true. An if statement does the same thing, but doesnt repeat. If you execute this loop, the speak_wait line will be repeated infinitely.*/speech.speak_wait(See ya later!);}//You do not have enough closing braces, the program doesnt see the end of the main function. URL: http://forum.audiogames.net/viewtopic.php?pid=194712#p194712 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: While parcing statement block error
Re: "While parcing statement block" error The first issue I can see is:else if(choice==3){speech.configure();}//This should be an else statement.{while(choice!=0 and choice!=4);/*This line of code will do nothing whatsoever. A while loop executes the code within its block, IE enclosed within the braces. This loop will also execute if the loop is not equal to 0 or if the loop does not equal 4. This will trigger for the other menu choices. A while loop is a loop that executes when a given condition is true. An if statement does the same thing, but doesnt repeat. If you execute this loop, the speak_wait line will be repeated infinitely.*/speech.speak_wait(See ya later!);}//You do not have enough closing braces, the program doesnt see the end of the main function.Later on in the code you have similar:while(!game_over);This will not lead to a while loop. URL: http://forum.audiogames.net/viewtopic.php?pid=194712#p194712 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Accessible C++ Compiler
Re: Accessible C++ Compiler A few things.When your setting the various properties of controls, Im pretty sure they look different depending on the property you set. If a controls enabled property is set to false, its going to look greyed out or not even be there at all. Read only keeps the text control there, you just cant input anything. Similarly if you add a textbox occupying the same pixel coordinates as a label, you could run into potential problems. Keep in mind that there are transparency settings for controls etc, people are going to notice if you can tab to a label where you usually cant, the exception being link labels.With visual studio, code is relatively accessible, despite some annoying focus changes and sometimes text not being read properly. If you are debugging, its not accessible in the least. Some of the property dialogs act weirdly to, sometimes the focus for reading properties of controls screws up so the properties dont show up whe n you select the name. URL: http://forum.audiogames.net/viewtopic.php?pid=194281#p194281 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: Slightly OT - Building a GUI in PureBasic
Re: Slightly OT - Building a GUI in PureBasic Keep in mind that you do have to position objects using pixel coordinates. Im not sure if pure basic has flow layout panels or anything however. URL: http://forum.audiogames.net/viewtopic.php?pid=192427#p192427 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: LLVM discussion
Re: LLVM discussion Im pretty sure you can find open source solutions that have already done this entire process as well. I honestly dont really think its a language issue, since he seems to understand terminology. repeatedly stating that as the issue and forcing compliance really isnt the way to go here. Id recommend the lupa package for python as a starting point, or angelscript. Python can also be embedded (though I dont really know enough to verify if itd work). Are you aiming for any particular language type? URL: http://forum.audiogames.net/viewtopic.php?pid=192116#p192116 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: LLVM discussion
Re: LLVM discussion A Google translation might not be entirely accurate. URL: http://forum.audiogames.net/viewtopic.php?pid=192043#p192043 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: I encountered a problem with my little sidescrolling movement program
Re: I encountered a problem with my little sidescrolling movement program His problem was that the players position variable was being incremented thousands of times a second. You could use a wait() function, or you could check your results against a timer. A wait function will basically hault execution of the program however until the wait period end. URL: http://forum.audiogames.net/viewtopic.php?pid=191940#p191940 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector
Re: LLVM discussion
Re: LLVM discussion I personally wouldnt say that. If you have a sincere need to use llvm and you have to knowledge to do so, then go ahead use it. Were not forcing you to use a particular piece of software here, were just giving recommendations despite any appearances given. Llvm has its uses, creating an interpreter for a scripting language has its uses. the goal here is to weigh the advantages and disadvantages of using llvm and a script interpreter, following the path that will lead to a finished piece of software. URL: http://forum.audiogames.net/viewtopic.php?pid=191771#p191771 ___ Audiogames-reflector mailing list Audiogames-reflector@sabahattin-gucukoglu.com https://sabahattin-gucukoglu.com/cgi-bin/mailman/listinfo/audiogames-reflector