59 Discussion / Question Topics

Remove Filter
Member Avatar for SoulMazer

Hi all, I'm working on a (Python) program which, in short, is a threaded TCP socket server which creates a new "tab" in a wx.Notebook widget for every incoming connection it sees. I've run into a strange problem where when I call notebook.AddPage(...), one of three things happens: 1. A …

Member Avatar for Gribouillis
1
739
Member Avatar for SoulMazer

Hi, I'm a beginner to C++ and am having some trouble with my list. I first define a struct named "bullet' like so: [code=c++]struct bullet { bool alive; bullet() alive = true; };[/code] Then, I create a list of objects of type "bullet": [icode]list<bullet> bullet_list;[/icode] In my program, I frequently …

Member Avatar for saravmittar
0
197
Member Avatar for SoulMazer

I should begin by stating that XML and I don't seem to get along very well. I've just about finished the interface on the level editor for a game I've made, and the next step is generating a XML file so that it can be read into the game dynamically. …

Member Avatar for ultimatebuster
0
157
Member Avatar for SoulMazer

Hi, I'm in the process of writing an Android game, and I need just a little bit of help with some physics. I do not wish to implement an entire physics engine, as, 1) I have already tried the Java port of Box2D on an Android device, and there is …

Member Avatar for dwks
0
133
Member Avatar for SoulMazer

Hi, I made a post about a similar subject quite a while ago, but I'm a little more serious about it now. I've created two games in C++ and one in Python, but I'd like to start making games for the web to let them be more visible and more …

Member Avatar for Tomsky
0
174
Member Avatar for SoulMazer

Hi, I'm new to C++ and I'm having trouble with this dang linker error. The full error is as follows: [quote]Error 4 error LNK2001: unresolved external symbol "public: static class std::list<class Node,class std::allocator<class Node> > NodeManager::node_list" (?node_list@NodeManager@@2V?$list@VNode@@V?$allocator@VNode@@@std@@@std@@A) Nodes.obj Error 5 fatal error LNK1120: 1 unresolved externals[/quote]From this error, I have …

Member Avatar for SoulMazer
0
318
Member Avatar for SoulMazer

Hi, I'm in the process of writing my own FPS in C++ and I had a general question about game programming. Up until this week, I was developing the game on a computer with a low-end graphics card and everything was working just fine. This week, I've changed my development …

Member Avatar for gusano79
0
127
Member Avatar for SoulMazer

Hi, I've just finished writing a Pong game with Python and pygame and thought it would be cool to make it multiplayer over the net with a friend. So, I changed my old asynchat-based instant messaging server into a server for this multiplayer Pong game. The only bad thing about …

Member Avatar for ultimatebuster
0
140
Member Avatar for SoulMazer

Hi, I'm writing a program that goes through all of the music in a user-specified directory and I am having some trouble with Unicode characters. More specifically, [icode]'ascii' codec can't encode character u'\\xe7'[/icode]. The song names need to both be printed to a HTML page as well as be passed …

Member Avatar for SoulMazer
0
111
Member Avatar for SoulMazer

Okay, I'm not sure what's going on, but tkSnack [URL="http://www.speech.kth.se/snack/"](link)[/URL] is deciding to not work for me all of a sudden. I have written a full-blown freaking media player with it, and I am now failing to simply play a song from the command line. I can get it to …

Member Avatar for SpeedyWizard
0
99
Member Avatar for SoulMazer

Ugh, this is quite frustrating. I am writing a series of CGI scripts with Python that all work perfectly until I add in a stylesheet reference. Interestingly, if I put the styling rules inside the CGI script, it runs perfectly; it only throws an error when it is in an …

0
123
Member Avatar for SoulMazer

Hi, I recently found a pair of wireless outdoor speakers [URL="http://www.amazon.com/ZipConnect-Wireless-Outdoor-Speakers-SR288/dp/B000C6URMI"](link)[/URL] that work flawlessly except they lack the central unit (your iPod connects to it and broadcasts music to the speakers). I would like to take advantage of the nice speakers by streaming to them via my computer. Is this …

0
74
Member Avatar for SoulMazer

Hi, I have a very simple problem yet I can't find out how to do it for the life of me. I am creating a simple CGI script with Python and part of it needs a HTML form. This is what I have so far (excludes imports, etc): [code=python]font_size = …

Member Avatar for SoulMazer
0
196
Member Avatar for SoulMazer

Hi, so I'm having quite the difficulty here. Let me start by explaining the architecture of my scripts. My "Listener.py" is a script that uses asyncore in order to listen for connections and receive commands from them. If it receives the text "play" from a connection, it calls another script, …

Member Avatar for SoulMazer
0
275
Member Avatar for SoulMazer

Hi, I've tried searching around for other problems similar to mine, and I was unable to find any. I seem to not be able to "color" text in a TextCtrl widget on Windows, but I can on Linux. I have a little screenshot and some code to show this: [URL="http://i189.photobucket.com/albums/z266/Capn_Soul/WinLinuxDifference.jpg"]Screenshot[/URL] …

Member Avatar for SoulMazer
0
815
Member Avatar for SoulMazer

Hi, I'm trying to color some text with wxPython but I am having some trouble. I am using the SetStyle method of the TextCtrl widget. My problem is that the coloring works perfectly on Linux but does not under Windows. My script basically gives a vocabulary test, and if you …

Member Avatar for vegaseat
0
148
Member Avatar for SoulMazer

Okay, I am writing a script that might be impossible to fully explain in words. Therefore, I am going to come up with an example that shows the same problem, so please do not tell me to simply combine the scripts or anything, as I am unable to. Anyways, I …

Member Avatar for SoulMazer
0
125
Member Avatar for SoulMazer

Hi, I'm writing a media player with wxPython and I seem to be having a bit of trouble. In my script, I create a wx.media.MediaCtrl widget; this line of code causes the trouble. On my Linux machine (running wxPython 2.8), this line of code causes no trouble at all. However, …

Member Avatar for vegaseat
0
230
Member Avatar for SoulMazer

Hi, I'm writing a GUI app with wxPython and I am wondering how I would insert and read/parse accented letters (Spanish accents, for that matter) from a TextCtrl widget. Also, I would like this would be compatible with all platforms (Windows, Linux, etc.). How could I do this? Thanks very …

0
80
Member Avatar for SoulMazer

Hi, I'm writing a multi-threaded script with wxPython as a GUI toolkit. About 50% of the time, I can run my script flawlessly. The other 50% of the time, I get [U]huge[/U] errors regarding wxPython that I cannot seem to decipher; however, I think it could possibly be a problem …

Member Avatar for SoulMazer
0
832
Member Avatar for SoulMazer

Hi, so I'm in the process of writing a music player with a GUI. I would like to be able to print a statement after I am done playing a song. I originally through I could just get away with getting the song's length and time.sleep'ing for that long. Since …

Member Avatar for Stefano Mtangoo
0
113
Member Avatar for SoulMazer

Hi, so I've been programming with Python (2.x) for a while now, and I was wondering about what people thought of 3.x. From just a few quick searches, some people recommend that people get used to it quickly as it is the future, and others say to just stay with …

Member Avatar for SoulMazer
0
159
Member Avatar for SoulMazer

EDIT: Hello, I need to figure out how I would download email from a Linux-based Postfix/Dovecot mail server. Is there a library that makes this relatively simple that good documentation/examples? Thanks in advance.

Member Avatar for SoulMazer
0
89
Member Avatar for SoulMazer

Hi, so I'm currently porting one of my applications (it's a media player) from Tkinter to wxPython and I am having some trouble as this is the first wx application I have attempted. I am trying to create something similar to [URL="http://i189.photobucket.com/albums/z266/Capn_Soul/DesiredLook.jpg"]this[/URL]. However, I can't figure out the wxPython code …

Member Avatar for SoulMazer
0
171
Member Avatar for SoulMazer

Hi, so in essence I have two little scripts: a server side script and a client side script. My client script sends a request to the server, and the server sends a string to the client. Once I get the string back into the client, I set it to the …

Member Avatar for SoulMazer
0
2K
Member Avatar for SoulMazer

Hi, I'm mostly a Python programmer but I now want to move to more web-based applications. What languages would you guys recommend for creating online games/applications? I already have a few Java books as I have been itching to learn it; would it be a good choice for web development? …

Member Avatar for ImMoRtAl-
0
148
Member Avatar for SoulMazer

Hi, so as an excuse to learn Java (I currently only know Python), I would like to write a simple 2D web-based game. How would you recommend me doing this? Should I write the entire game from the ground up? Should I use a game engine? If you would like …

Member Avatar for SoulMazer
0
187
Member Avatar for SoulMazer

Okay, being a Linux guy, I absolutely hate it when applications are not cross-platform (Windows only). So, I decided to write myself a cross-platform media player. I have spent quite the bit of time making it look great on Linux, but I am unable to do the same on Windows …

Member Avatar for Stefano Mtangoo
0
120
Member Avatar for SoulMazer

Hello, I'm writing a music player and I'm having trouble with one of the most important concepts of it: remembering songs you add to your "Library". The main draw of my music play is being quick and efficient at everything, and keeping that in mind, what would be the best …

Member Avatar for SoulMazer
0
146
Member Avatar for SoulMazer

Hi, I'm trying to add an icon to my Tkinter GUI window and have had no luck. After some searching, I came up with the same piece of code which does not work. Here is a snippet of my code: [code=python]from Tkinter import * root = Tk() root.minsize(290, 700) root.title("My …

Member Avatar for SoulMazer
0
24K
Member Avatar for SoulMazer

I'm trying to bind a Tkinter widget to a method in another file. I'm not quite sure how to do this, but let me show you what I have so far. [code=python]#!/usr/bin/python # File1.py from Tkinter import * import File2 class MyFile: def __init__(self): master = Tk() obj = File2.DoStuff(master) …

0
71
Member Avatar for SoulMazer

Okay, well I have to say I am completely stumped where to go from here. I am writing a media player and I am currently working on song indexing. I have figured out how to extract the song name and its complete path using os.walk(); however, I have no idea …

Member Avatar for SoulMazer
0
112
Member Avatar for SoulMazer

So...I have just begun to whet my appetite for Java today, and I have already run into a stumbling block. When I put my code in a .java file and compile it (via javac), I receive no errors. However, when I actually run my script, I receive quite the nasty …

Member Avatar for peter_budo
0
207
Member Avatar for SoulMazer

Okay, well I've been looking for at least an hour now for some straight-forward python-xlib documentation, and I have been unable to find any. Luckily...I have quite the easy problem. If somebody would be able to help me create a simple script that would say "Hello" every time the left …

Member Avatar for SoulMazer
0
585
Member Avatar for SoulMazer

Okay, well I'm having trouble getting a variable from one place to the other. I have two scripts: for now, let's call them MainScript.py and ChildScript.py. [code=python]#!/usr/bin/python # MainScript.py import ChildScript from Tkinter import * class GetVariable: def __init__(self): master = Tk() master.withdraw() ChildScript.VariableDialog(master) # From right here, I would …

Member Avatar for SoulMazer
0
144
Member Avatar for SoulMazer

Okay, so I am writing a media player and I would like to be able to control the entire thing without the use of a GUI. So...are there any libraries or anything that would allow me to collect keystrokes on any OS (not just Windows)? Thanks in advance.

Member Avatar for Tech B
0
235
Member Avatar for SoulMazer

So, I have a script that needs to "clean up" when it is exited: it needs to clear a special logging file and other small things that affect the next startup of the script. The script has a GUI written in Tkinter, if that is relevant at all. Is there …

Member Avatar for SoulMazer
0
103
Member Avatar for SoulMazer

Okay, so I'm having a little trouble. Let's say I run "scriptA.py" and it has a GUI (Tkinter) and it is running in its mainloop. I want to create a "scriptB.py" that can end "scriptA.py"; would there be a way to do this regardless of the OS it is on …

Member Avatar for SoulMazer
0
269
Member Avatar for SoulMazer

Ok, well I am JUST beginning to learn Java, and I have run into a little stumbling block. I am attempting to write a little applet, but it doesn't seem to want to run. My Java code: [code=java] import java.awt.*; import java.applet.*; public class TestApplet extends Applet { public void …

Member Avatar for jasimp
1
144
Member Avatar for SoulMazer

Hi, I'm looking for a little help with the function "getattr". Here's my code: [code=python]class MyClass: def __init__(self): trycmd = getattr(self, "cmd_testing") try: trycmd() except: print "Fail." def cmd_testing(self): print "Victory!" obj = MyClass()[/code] So, when I run this code, I get the output "Fail.". I'm not sure what I'm …

Member Avatar for vegaseat
1
142
Member Avatar for SoulMazer

So, I have a rather simple question today. I'll try to explain it by using an example. Let's say there is a line of HTML in the page "www.mywebsite.com/py" that says "<tr colData0='Friday'>". However, this line of code can change to be "Sunday", "Tuesday", etc. What would be the easiest …

Member Avatar for SoulMazer
1
165
Member Avatar for SoulMazer

Hi, I have written a simple chat server and a client that can connect to it. To make it more secure, I would like to add SSL to the connection process. How would I go about doing this? Thanks in advance.

Member Avatar for SoulMazer
0
156
Member Avatar for SoulMazer

Ok, I am writing a client for the "instant messaging" server I just wrote. The client is in all Python, and the GUI is made with Tkinter. Anyways, my first question is this: is there a way to make a scrollbar widget automatically scroll to the bottom? Second, in a …

Member Avatar for SoulMazer
0
4K
Member Avatar for SoulMazer

Hi, so in order to make my problem more clear, I shall just make a simple example of what I am trying to do. I will start with a little code: [code=python]from Tkinter import * master = Tk() msgbox = Text(master) msgbox.pack() mytext = raw_input("> ") msgbox.insert(END, mytext) master.mainloop()[/code] Now, …

Member Avatar for SoulMazer
0
547
Member Avatar for SoulMazer

Ok, I really hated to resort to threading, but it seems like I have no other choice. I am writing a client script for the "instant message" server I just finished writing. Sadly, I am having a slight problem with threading. What I would like to do is have two …

Member Avatar for SoulMazer
0
156
Member Avatar for SoulMazer

Hi, so I am trying to write a simple chat server in Python. If I just run the server, it runs fine. Yet, when I try to connect to the server from a different terminal via a "telnet localhost (port)", the server gives me an error: [quote] error: uncaptured python …

Member Avatar for SoulMazer
0
164
Member Avatar for SoulMazer

Hi, I am writing a script that aims to help a person keep a list of characters while reading a book. In doing this, I am writing to a file and checking it constantly, except I ran into a problem. Say I executed a code block such as the following: …

Member Avatar for SoulMazer
0
1K
Member Avatar for SoulMazer

This is my first PHP script, so please excuse my clumsiness. I have a HTML page which consists of a form and a PHP page which deals with the variables that are outputted. The HTML page functions as a small box that asks to input an email account/password, and the …

Member Avatar for SoulMazer
0
92
Member Avatar for SoulMazer

So, I always thought that it was possible to return dictionaries in Python. I was wanting to do this because I would prefer not to use globals. However, I am having trouble with returning my dictionary. Code: [code=python] #!/usr/bin/python # 6/9/09 def loadWords(): pathstart = "/home/foo/Documents/PyScripts/Vocab/Lists/" print "What is the …

Member Avatar for jlm699
0
104
Member Avatar for SoulMazer

So, I have this script that I am using to study some Biology vocab words for my final tomorrow. All I did was put the list of words/definitions in my existing script, and everything seems to go wrong. I have a total of 50 definitions, yet it says there are …

Member Avatar for SoulMazer
0
135

The End.