- Strength to Increase Rep
- +0
- Strength to Decrease Rep
- -0
- Upvotes Received
- 1
- Posts with Upvotes
- 1
- Upvoting Members
- 1
- Downvotes Received
- 0
- Posts with Downvotes
- 0
- Downvoting Members
- 0
21 Posted Topics
Hi there, i have a ball: [icode] void ball (void) { glColor3f(0.0, 1.0, 0.0); //set ball colour glTranslatef(0.0,0.0,1); //moving it toward the screen a bit on creation glutSolidSphere (0.6, 7, 7); //create ball. } [/icode] I am trying to get the ball to move in a direction when i press … | |
Hi guys, As the title says i have 3 boids, all given a number (0,1,2) by way of [B][I]i=0, i<3,i++[/I][/B] Later on i'm assigning a certain boid to turn red when it gets within range of it's target boid. At the minute its only turning red when it comes within … | |
Hi there, I'm making a simple shell program in [B]pico using Unix[/B]. I was given most the code from a tutor and added bits to it, it's supposed to go to a prompt allowing user to type but instead it does nothing. [B]No errors are shown.[/B] Btw: i use [B]gcc … | |
Hi there, I'm currently in the process of creating a Multi-User Dungeon (MUD) in python. It'll allow multiple users to explore a text based world. I've got a basic server but i can't seem to get a client to work with it. [B]MUD server.py[/B] [code] import socket #Connect with telnet … | |
HI there, I've been trying to implement a class of a ball i was given by an tutor but am having troubles. She gave me: [B]TBall.h[/B] [CODE] class TBall { public: double _radius; // defines the radius of the ball TVector _position; // defines the position of the ball TVector … | |
Hi there, I have this cube which i rotate around a centre, I'm attempting to make it register when i move a sphere beyond it's x,y,z position. However the cubes x,y,z position seems to be it's origin of rotation and not it's actual current position. I believe this is because … | |
Hi there, I have an OpenGL scene containing a circular plane, ball and box. I'm attempting to set up bounding box's around each for a primative form of collision detection. I am trying to follow a tutorial from here: [URL="http://www.morrowland.com/apron/article/gl/boundingbox/index.php"]http://www.morrowland.com/apron/article/gl/boundingbox/index.php[/URL] But it says i should use TVector3 ... i have … | |
Hi there, i have this rectangle and i want to be able to rotate this shape around another when i press a key. i have been able to make it rotate where it is. There are two problems i am having difficulties with: - I can get the shape to … | |
Hi, i didn't know whether to put this under C or Shell scripting so i chose this one. Well I am doing a piece of shell scripting and have written some code. and basically when i run it no prompt shows up so i cannot type commands like help or … | |
Hi there, using TKinter Is it possible to change a buttons text after you've clicked it? So if a button has text of "hi" and when clicked has text of "Goodbye"? [icode] button_switch = True def click(): global button_switch if button_switch: button_switch = False else: button_switch = True [/icode] This … | |
I was wondering if theres anywhere to get C++. You see i have work to do for homework and i'm trying to do it at home but it's quite hard to do without the program. Is there any free or trial software that can help check my code for ...lets … | |
Greetings Pythoneers. I've got this problem and the problem is thus: i have drawn a shape using [B]pygame.draw.circle[/B] i am finding it hard to make it move. i tried [icode]self.move_to(self.x-5,self.y)[/icode] and also [icode]self.forward(random.randint(0,10))[/icode] (Where forward is defined as a function as [icode]self.x,self.y + 10[/icode])<== I dont think i defined the … | |
Evening there. [B]I need to return an (x,y) tuple of an object, This x,y will be used to help 1 object calculate where the other object is and move towards it.[/B] My problem is that both the objects need to know the others' x,y. (i'm unsure how to get the … | |
Hi there, I'm trying to create a class with whats below. I made it and it works but i need to be able to withdraw an amount from the balance. I'm just having trouble with the layout and whether i got the right idea? Is the underlined area on the … | |
I'm struggling on how to do this. For example. [code] for i in range (1 ,100): if i % 3 == 2: print i, " mod ", 3, "= 2"[/code] i think i need to understand what this does more. Firstly what does % mean? [B]if i is the square … | |
wow it's me again! i have: [code] i=0 while i<11: print i, print '' i=i+1[/code] this gives the answer: 0 1 2 3 4 5 6 7 8 9 10 i need to give the answer. * * * * * * * * * * * * * * … | |
I am trying to: [B]Implement an iterative Python function which returns the sum of the first n integers[/B] so far i have this: [code] i = 0 total = 0 def sum(n): while i <> n: total = total + 1; i = i + 1; return total [/code] then … | |
Hello there, I've a homework assignment from a while ago that asks [B]"Implement a recursive Python function which returns the sum of the first n integers"[/B] Now i just dont know exactly what it's asking and how to get started. Recursive functions, right (my thoughts so far is it'll look … | |
I have currently built a database (based on IMDB) that i can add dictionaries too, list them and exit. [B]I will put the program so far at the bottom of the page, just paste it in and run ti to see what it's like.[/B] I am trying to add a … | |
I have been asked the following: create inputs for a half-adder using python and the outputs i expect. I was hoping someone could just have a look at this for me and see if i've got the right idea. This will work from a copy and paste straight off the … | |
[B]Hi i've been assigned with doing a torn square, and i've kinda got it working with the code below.[/B] [code] import turtle turtle.reset() length=100 degree=60 i=0 while i < 4: turtle.forward(length/length*40) turtle.right(degree) turtle.forward(length/2) turtle.left(degree+degree) turtle.forward(length/2) turtle.right(degree) turtle.forward(length/length*40) i+=1 turtle.right(90) else: raw_input("there's hopefully a square, all torn like!") [/code] as you … |
The End.