Search Results

Showing results 1 to 40 of 58
Search took 0.01 seconds.
Search: Posts Made By: besktrap
Forum: Python Jun 18th, 2009
Replies: 3
Views: 293
Posted By besktrap
there's not alot of info about it, but check the pygame website www.pygame.org
Forum: Python Jun 18th, 2009
Replies: 11
Views: 679
Posted By besktrap
Well, I have a class imported from a file:
from lib.class import *
in the main program, I read a text file which outputs:
Vent( 100,300, 'Vent' )
I assign that string from the text file to a var...
Forum: Python Jun 17th, 2009
Replies: 11
Views: 679
Posted By besktrap
Hate to bother you, but I have one more question. I have this string:
temp_string = "Vent( Screen, 100, 484, 'Vent' )"
and when I do exec:
exec(temp_string)
python doesn't return anything (like...
Forum: Python Jun 17th, 2009
Replies: 11
Views: 679
Posted By besktrap
oh I see. lol with the stuff i'm working on, I won't need to worry about that, but thanks for the tip!
Forum: Python Jun 17th, 2009
Replies: 11
Views: 679
Posted By besktrap
Thanks! but, why is the exec function is a risk?
Forum: Python Jun 17th, 2009
Replies: 11
Views: 679
Posted By besktrap
I would be getting the string from a text file, but i'll try what you recommended
Forum: Python Jun 17th, 2009
Replies: 11
Views: 679
Posted By besktrap
Hi all. Is there any way that if I give python a string, it can convert it into code? Example, say I am given this string:
string = "Class( 0,100 )"

Now I want to convert it into code:
Class(...
Forum: Python Jun 15th, 2009
Replies: 7
Views: 288
Posted By besktrap
Seems like you are transitioning from c++/c to python. ( BTW when you have an if statement, you don't have to have parenthesizes around your expression). When you call a function, there is no need to...
Forum: Python Jun 15th, 2009
Replies: 13
Views: 893
Posted By besktrap
If you wanted to start 2d games in python, I begin with pygame (a python port of SDL). There are tons of tuts everywhere, just have a look. Try www.pygame.org for more info.
Forum: Python Apr 25th, 2009
Replies: 4
Views: 631
Posted By besktrap
thanks everyone!
I got it working just fine. all I needed was the __init__.py file and some code clean up!
Forum: Python Apr 25th, 2009
Replies: 4
Views: 631
Posted By besktrap
hi everyone! I have two files, main.py and sprite_class.py. sprite_class.py is in a separate folder called lib. here's a quick diagram:

------------------------------------
/folder engine/
...
Forum: Python Mar 28th, 2009
Replies: 2
Views: 285
Posted By besktrap
thanks alot! :)
Forum: Python Mar 28th, 2009
Replies: 2
Views: 285
Posted By besktrap
Hi everyone. I'm having a little trouble trying to understand what argument passing really is. I know that it 'passes' arguments, but what does that actually mean and how can you use it to my...
Forum: Python Mar 6th, 2009
Replies: 4
Views: 507
Posted By besktrap
thats good, but how would I say that each block is, for example, to the right other block + 50 pixels. Also, how would I specify the number of blocks so the program doesn't spawn blocks forever?
Forum: Python Mar 2nd, 2009
Replies: 4
Views: 507
Posted By besktrap
thanks, but the only problem is that each instance of the object (in this, it would a cube that the player can collide with) needs to have specific code that will determine if it is touching the...
Forum: Python Mar 1st, 2009
Replies: 4
Views: 507
Posted By besktrap
Hi everyone!

I am currently creating somewhat of a platformer/puzzle game in pygame and ran into a problem with creating levels. I really don't want to take the time to program collisions...
Forum: Python Feb 12th, 2009
Replies: 1
Views: 258
Posted By besktrap
hey everyone. i am writing a program in python w/ Tkinter and ran into a problem with padding. So, i have a Label object named DataPool_Text. when I run it (side=TOP), it goes to the top middle of...
Forum: Python Feb 1st, 2009
Replies: 1
Views: 283
Posted By besktrap
oops! sorry. anyways...

i'm a little fuzzy on all this socket server stuff, so try to bear with me. I want to users to be able to connect to each other. the code for my server is:

import...
Forum: Python Feb 1st, 2009
Replies: 1
Views: 283
Posted By besktrap
Hello all. I'm working with pygame and are trying to implement some type of server.
Forum: Python Jan 26th, 2009
Replies: 2
Views: 1,403
Posted By besktrap
does anyone know how to shutdown a computer on windows XP (using python of course ;) given the IP address and the computer name (probably don't need it, though)? I don't want to use os commands like...
Forum: C++ Jan 10th, 2009
Replies: 6
Views: 359
Posted By besktrap
Thanks again! But when I cout << game, i get

0x441000

What happend there?
Forum: C++ Jan 10th, 2009
Replies: 6
Views: 359
Posted By besktrap
Thanks! But how would I change the contents of variable with out completely erasing it?
ex:
In Tic Tac Toe, the third line looks like this:

Line_one[3] = { ' ', ' ', ' ' }

Then the player...
Forum: C++ Jan 10th, 2009
Replies: 6
Views: 359
Posted By besktrap
Hi everyone. I'm currently working on a Tic Tac Toe game, and I am having a little trouble with, well, I'm not even sure what to call them. They are a variable with brackets like so below. Anyway, I...
Forum: JavaScript / DHTML / AJAX Dec 4th, 2008
Replies: 8
Views: 4,218
Posted By besktrap
so I have these two chunks of code:

<form action="#" onsubmit="return false;">
<input type="text" value="Email" name="Email"
style="color:grey;text-align:left;background:white"...
Forum: JavaScript / DHTML / AJAX Dec 4th, 2008
Replies: 8
Views: 4,218
Posted By besktrap
um...ok.
how do you hide the textbox when clicked? :icon_wink:
Forum: JavaScript / DHTML / AJAX Dec 3rd, 2008
Replies: 8
Views: 4,218
Posted By besktrap
thanks! it worked fine, but how would I have it clear the value of the textbox when clicked?
Forum: JavaScript / DHTML / AJAX Dec 1st, 2008
Replies: 8
Views: 4,218
Posted By besktrap
Hopefully this is the correct place to post this, so here ya go. I'm learning HTML and just had a few questions. I was using some tutorials from w3schools.com, and I came across Event Attributes. So...
Forum: HTML and CSS Nov 30th, 2008
Replies: 2
Views: 5,077
Posted By besktrap
Hi y'all. I'm just starting to learn HTML and just had a few questions. I was using some tutorials from w3schools.com, and I came across Event Attributes. So I have this textbox, and I want it, when...
Forum: Python Sep 27th, 2008
Replies: 1
Views: 879
Posted By besktrap
hello everyone, just a quick question about pygame rotations.

If i have an image, say "image.bmp", how would I zoom in on that image? Thank in advanced
Forum: Project Partners Wanted Sep 17th, 2008
Replies: 12
Views: 2,329
Posted By besktrap
Hi there. I can use python/pygame,Batch, and other languages, and would be interested in this RPG. Sign me up!
Forum: Python Aug 21st, 2008
Replies: 34
Views: 2,654
Posted By besktrap
I'm still working on it, but I am working on including some code that will let you drag the ball around and throw it (hopefully more than just on the Y axis) and a Tk window that will let you change...
Forum: Python Aug 21st, 2008
Replies: 34
Views: 2,654
Posted By besktrap
Thanks you very much! I understand the code now; I can't do "(ballSpeed[1]/4*3)", but in order for it to work, I must create separate variables for the numbers: "ypos = ypos + int(((velocity +...
Forum: Python Aug 21st, 2008
Replies: 34
Views: 2,654
Posted By besktrap
thanks so much!

does python have an infinite varible?
Forum: Python Aug 21st, 2008
Replies: 34
Views: 2,654
Posted By besktrap
I fixed the parenthesis, but it stops at loop 20.
Forum: Python Aug 20th, 2008
Replies: 34
Views: 2,654
Posted By besktrap
That doesn't work: link. (http://i510.photobucket.com/albums/s342/besktrap/se4.jpg)

I don't see why it wouldn't work.
Forum: Python Aug 20th, 2008
Replies: 34
Views: 2,654
Posted By besktrap
Sure; I promise to understand it. If I don't, I'll look online or the Pygame documentations for help.

I hate it when I make something, but I don't know how it works.
Forum: Python Aug 20th, 2008
Replies: 34
Views: 2,654
Posted By besktrap
The first part of your code looks fine, but when you get to the ballSpeed[1]=((-ballSpeed[1]/4*3)) the math still doesn't work right. link: http://i510.photobucket.com/albums/s342/besktrap/-s3.jpg
Forum: Python Aug 20th, 2008
Replies: 34
Views: 2,654
Posted By besktrap
I'm trying to make it multiply by 3/4 every time the ball hits the bottom of the screen, but it just loops on that if statment.
Forum: Python Aug 20th, 2008
Replies: 34
Views: 2,654
Posted By besktrap
The first part of the code looks fine, but the math still doesn't work right. Link. (http://i510.photobucket.com/albums/s342/besktrap/-s3.jpg)

I though of just doing the math without...
Forum: Python Aug 20th, 2008
Replies: 34
Views: 2,654
Posted By besktrap
Read the first page of posts.
Showing results 1 to 40 of 58

 


About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC