- Strength to Increase Rep
- +6
- Strength to Decrease Rep
- -1
- Upvotes Received
- 14
- Posts with Upvotes
- 14
- Upvoting Members
- 10
- Downvotes Received
- 1
- Posts with Downvotes
- 1
- Downvoting Members
- 1
- Interests
- Programming. What else?!
- PC Specs
- Ubuntu 10.04
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 … | |
Re: When I started threading in Python, I had the exact same problem. It's quite difficult to find a very basic example of it. Let me try to give you one using the scenario you described. I'm not quite sure how you are going to connect to the two client machines, … | |
Re: Sorry, I know this code is for Python 2.x, but hopefully it can point you in the right direction. There is a piece of code that I did NOT write myself but I implemented it in one of my programs. It basically creates a few text widgets in a loop … | |
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 … | |
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. … | |
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 … | |
Re: Could you be more descriptive than "I can't use this"? Do you get an error? Does it just not do anything in general? As you probably know, you need elevated privileges to run a command with "sudo," so my guess is that you need to run your script with "sudo": … | |
Re: You could use a separate thread to function as a sort of timer and simply call the .Destroy() function (correct me if I am wrong, can't remember the function name) after a given amount of time. If you need help with threads or anything feel free to post back. | |
Re: [QUOTE=Garrett85;1343360]I have another post entitled 'understanding wxPython' in which my code runs but fails to build the scroll bars as shown by my python programming book. Note that the code in the book is running on Windows and mine is running on Ubuntu.[/QUOTE] I tested this myself, and I can … | |
Re: Sadly, an easy alternative to raw_input that does not block (that is portable) is not too easy to find. I tried to create a version myself, but apparently raw_input even blocks other threads in the program from printing to the console. It's pretty strange. However, if this is just for … | |
Re: Well the problem is that Python and all other CGI scripting languages are [B]server-side[/B] scripting languages, which means they are only called when the page is requested for the first time. From what you say, you will need some sort of [B]client-side[/B] scripting language for the web interface. You mentioned … | |
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 … | |
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 … | |
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 … | |
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 … | |
Re: [QUOTE=dhanapal86mca;1263674]Can Any one tell me how to use phython with .net[/QUOTE] There's a nice library out there conveniently called "Python for .NET" [URL="http://pythonnet.sourceforge.net/readme.html"](link)[/URL]. [quote]and wat is the main use of phython[/quote] Come on, at least spell Python correctly! Python, as defined by About.com, is: [quote]Python is a general purpose programming … | |
Re: Are you looking for something along the lines of [URL="http://www.speech.kth.se/snack/"]tkSnack[/URL]? I cannot help you with integrating it into your C program, but from experience it is a highly dependable library that is quite easy to use; it is also cross-platform (at least for Windows & Linux). Its one downside is … | |
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 … | |
Re: It's probably not working because you are not supplying all the required arguments. Sadly, it looks like Facebook wants quite a few arguments to log in such as authentication token and api key, but the Facebook devs have provided some information on all of it: [URL="http://wiki.developers.facebook.com/index.php/Authorization_and_Authentication_for_Desktop_Applications"]http://wiki.developers.facebook.com/index.php/Authorization_and_Authentication_for_Desktop_Applications[/URL]. Good luck. | |
Re: Well, it doesn't even look like deepak's code is Python. I'm not quite sure what is going on with that. Anyways, I do not see any immediate problems why your code should not work except for the constant calling of the function "create_top." You call it eight times? That would … | |
Re: EDIT: Sorry, I did not read the "Active Directory" specification in your post. Well, a Google search turned up an active_directory module which appears to be cross-platform. It can be found here: [URL="http://tgolden.sc.sabren.com/python/ad_cookbook.html"]http://tgolden.sc.sabren.com/python/ad_cookbook.html[/URL]. | |
Re: The error is being raised because it is trying to find the integer value of the character '[', which is apparently part of your list. You could either put in a try/except statement to 'pass' when you run into those, or print out the contents of the list and manually … | |
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 … | |
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 … | |
Re: Yeah, sure. I think domain name masking would be the solution you're looking for. [URL="http://kb.siteground.com/article/Simple_domain_name_masking.html"]http://kb.siteground.com/article/Simple_domain_name_masking.html[/URL] | |
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 … | |
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 = … | |
Re: It just so happens I used this exact library to store information for my media player! I cleaned up the code a bit and just included some basic operations. (songDict is a dictionary which contains the name, artist, album, etc. of various songs -- I find it easiest to put … | |
Re: [QUOTE=shaqywacky7;1244704]I'm on windows, so I don't think thats the problem.[/QUOTE] Hah, I think that might be your exact problem, especially if you're on Vista. Try a good old 'Run as Administrator.' And maybe implement something like so: [code=python]import os if os.geteuid() != 0: print "You must be root to run … | |
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, … |