Components of this study are sometimes known as "The Four Pillars of Destiny" or "Bazi" and originated during the Tang Dynasty (618-907), and was expanded to apply to weaponry during the Song Dynas...
With the techniques of Source Code Meditation, you can activate latent energy in your body to energize and awaken your higher brain before meditation begins. With the higher brain prepped and tuned...
Source CodeFull description
buku panduan belajar javascript Source CodeDeskripsi lengkap
This project explores the area of Source Code In Database (SCID) and moves on to the design and implementation of a tool that parses source code and stores useful information (such as classe…Full description
Source Code Menggambar rumah 3D Menggunakan OpenGLDeskripsi lengkap
.l.Descripción completa
Descripción completa
Descripción completa
siakadDeskripsi lengkap
term paper on scientific calculator, C++ programme on scientific calculator, source code on scientific calculatorFull description
Working code of game, just include words.txt of 4000 words and compile it..
source code rute terpendek menggunakan metode hill climbingFull description
Source Code Menggambar rumah 3D Menggunakan OpenGLFull description
source code java
it is a calculator and illustrator based on Vedic Mathematics.Descripción completa
Source Code Menggambar rumah 3D Menggunakan OpenGL
Source Code Aplikasi Kas Keuangan Berbasis Web
asdasdDescripción completa
Full description
makalah source rockFull description
Mass sourceFull description
// Pacman by X5K MaStEr X5K and John // Started September 10, 2001 // // // //
We used some code from: Warp By Karl Hornell, June 10, 1996 to get us going. Thanks Karl!
import java.util.Random; public final class Pacman extends java.applet.Applet implements Runnable { Thre Thread ad upda update teTh Thre read ad; ; // thre thread ad in whic which h the the game game will will run run long startTime; // used to keep track of timing and to p revent applet from running too fast Graphi Graphics cs gBuf gBuf; ; // used used for doubledouble-buf buffer fered ed grap graphic hics s Imag Image e imgB imgBuf uf; ; // als also o used used for for dou doubl blee-bu buff ffer ered ed gra graph phic ics s static final int MAX_X = 400; // widest the playing screen can be static final int MAX_Y = 400; // tallest the playing screen can be public void init() { // Make the applet window the size we want it to be resize(MAX_X, MAX_Y); // Load the images we will use from the web getMainGraphics(); // Garbage collection call. System.gc();
Not really needed.
// Make a black background setBackground(Color.black); // Set up double-buffered graphics. // This allows us to draw without flickering. imgBuf = createImage(MAX_X, MAX_Y); gBuf = imgBuf.getGraphics(); // try to grab the keyboard focus. requestFocus(); }
public void getMainGraphics() // Load and process the most common graphics { MediaTracker tracker; int i = 0; tracker = new MediaTracker(this);
// this code doesn't load any graphics yet! try { tracker.waitForAll(); } catch (InterruptedException e) { } }
public void run() { // This is the most important method. It loops over and // over again as the game is running. It makes the calls // that move things and then draw them. while (updateThread != null) { try { // this code slows the applet down if it is on a really fast machine long sleepTime = Math.max(startTime - System.currentTime Millis(), 20); updateThread.sleep(sleepTime); } catch (InterruptedException e) { } startTime = System.currentTimeMillis() + 40; // DRAW STUFF HERE: // clear what we drew last time. gBuf.clearRect(0, 0, MAX_X, MAX_Y); // set the drawing color gBuf.setColor(Color.yellow); // draw a rectangle for now. gBuf.drawRect(10, 10, 50, 50); // repaint() will call paint(Graphics) which will call update(Gr aphics) repaint(); } } // This method is called when the applet is run. // It initiallizes the thread and gets things going. public void start()
{ if (updateThread == null) { updateThread = new Thread(this, "Game"); updateThread.start(); startTime = System.currentTimeMillis(); } } // This method is called when the applet is stopped. public void stop() { updateThread = null; } public boolean keyDown(java.awt.Event e, int key) { // This method handles key presses. // For now all the statements are placeholders. // // // //
it is nice to have a print statement here. it can be quickly uncommented and the output used to get keycodes since I am too lazy to look them up.
//System.out.println(key); if (key == 1006) // right arrow { return false; } if (key == 1007) // left arrow { return false; } if (key == 1004) // up arrow { return false; } if (key == 1005) // down arrow { return false; } if (key == 32) // space bar { return false; } if (key == 112) // 'P' key {
return false; } return false; } public boolean keyUp(java.awt.Event e, int key) { // This method is called when a key is released. // right now it just has place holders. if (key == 1006 key == 1007) {
// left or right key released
return false; } if (key == 1004 key == 1005) // up or down key released. { return false; } if (key == 32) {
// space bar released
return false; } return false; } // To ensure Java 1.1 compatibility, request focus on mouseDown public boolean mouseDown(java.awt.Event e, int x, int y) { requestFocus(); return false; } public void paint(Graphics g) // Draw the control panel and stuff { // Since there are no borders or anything // static to draw yet we only need to call // the update method. update(g); } public void update(Graphics g) { // draw the offscreen buffer to the screen! // This buffer was drawn on by the run() method // and by any methods run() might have called. g.drawImage(imgBuf, 0, 0, this); } }