Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Which Game Should i Make for ISU
Index -> Programming, Turing -> Turing Help
Goto page Previous  1, 2
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
apython1992




PostPosted: Wed Jun 08, 2011 10:52 pm   Post subject: Re: RE:Which Game Should i Make for ISU

JumpingLimaBean @ Wed Jun 08, 2011 10:45 pm wrote:
How do i impliment into code tho?

If you continue on with programming and computer science, this is something you will be asking yourself all the time. It's great to practice this kind of problem solving. Ask yourself these questions:

- Can I easily represent a graphical figure as a simple mathematical object in Turing? What values would define this object? (i.e. a circle in two-dimensional Euclidean space needs x, y, and radius)
- Can I use some basic mathematical functions like square root in Turing?
- How can I translate the graphical logic into procedural Turing code?

Really ask yourself those questions. If you get stuck, you can come back and ask for help.
Sponsor
Sponsor
Sponsor
sponsor
JumpingLimaBean




PostPosted: Wed Jun 08, 2011 11:00 pm   Post subject: RE:Which Game Should i Make for ISU

Which game do you think will be easier for me to create with low knowledge and EXP.




The one im working on now where its 2 player and you dodge debris and it goes in random directions bouncing of walls, if you get hit the other play scores 1 and the area is reset and it goes to 5.


Or pacman but smaller and built differently he cant go out of the walls, the ghosts go after him( but not insanly hard) and he picks up the dots. If he gets all of them without dieing he wins. There will also be the 4 dots that reject the ghosts.



Thanks for the help with the collision i get that if they are touching you need to make them move back but ya its still hard to understand
JumpingLimaBean




PostPosted: Wed Jun 08, 2011 11:04 pm   Post subject: RE:Which Game Should i Make for ISU

I dont very much understand square root its not my forte but i can use other basic mathematical functions xD.
I keep on trying to do like if x = and i dont know the turing code for other objects is frustrating that its all this special code writing hard to understand.


i cant easily represent a figure as mathematical object in turing Sad
2F_Zelda




PostPosted: Wed Jun 08, 2011 11:13 pm   Post subject: Re: Which Game Should i Make for ISU

Basic arrays, such as the one in the example I used, are simply for compressing a bunch of variables into one name. Let's say there's 5 variables. A, B, C, D, and E. I would put them into array Letters. To declare it, I would go:
Turing:

var letters : array 1 .. 5 of char


The var, you should know. The name is letters. Then it is told that it's an array, with variables numbered 1 to 5. Those 5 variables are then told they are of the char type.

Now, instead of using A or B, I would use letters(1) or letters(2).

Did that help?
JumpingLimaBean




PostPosted: Wed Jun 08, 2011 11:17 pm   Post subject: RE:Which Game Should i Make for ISU

Ya. I kind of get arrays now. But i dont get why you use array if you only using 2 squares to check collision.


I still slightly dont get all of the + and - of corners of square
Tony




PostPosted: Wed Jun 08, 2011 11:39 pm   Post subject: Re: RE:Which Game Should i Make for ISU

JumpingLimaBean @ Wed Jun 08, 2011 11:04 pm wrote:
...is frustrating...

that's... natural. The thing is, Computer Science is substantially different from most other classes that you get to take in high school. Those other courses are about memorizing some facts and steps for solving a very specific kind of a problem (remember those Math homework assignments where it's basically the same problem, but uses different values, and you have to solve those again and again and again?). There a teacher tells you exactly the steps to follow. Or a thing to memorize.

Computer Science is different in a way that you are given a bunch of very basic tools (if-statements, loops, etc.), but then you don't get a list of steps to follow. This is very different, and it _is_ frustrating, but it's also the most rewarding because you get to build your own games and programs.
Latest from compsci.ca/blog: Tony's programming blog. DWITE - a programming contest.
2F_Zelda




PostPosted: Thu Jun 09, 2011 12:27 am   Post subject: Re: RE:Which Game Should i Make for ISU

JumpingLimaBean @ Wed Jun 08, 2011 11:17 pm wrote:
I still slightly dont get all of the + and - of corners of square


Pretend you drew a square on a piece of paper. Now, pretend you drew lines of the same length as a side of the square from the bottom left corner of the square up, down, left, and right. Pretend that at each endpoint of these new lines you drew a square the same size as the first with the bottom left corner on the endpoint.

Those lines represent the farthest the other squares can be from the original square while still touching and triggering collision detection.
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 2 of 2  [ 22 Posts ]
Goto page Previous  1, 2
Jump to:   


Style:  
Search: