Hilfe bei Applet-Programmierung

Status
Nicht offen für weitere Antworten.

Halo_Player

Mitglied
hallo, Ich versuche ein kleines Spiel zu programmieren mit Hilfe von Sourcecode den ich im Internet gefunden habe,den ich abgeändert habe:
Das Apllet lässt mehrere Bilder über der bildschirm wandern, bei klick auf ein bild wird dieses gelöscht und ein neues erzeugt -> Treffer ! :) (Teil 1)
Jetzt habe ich versucht ein (quasi)menü zu implementieren. 5 Bilder- bei klick auf eines soll der maus cursur verändert werden. (Teil2)
Mein Problem ist das ich (Teil 1) und (Teil2)
unabhängig angegangen bin und es mir jetzt nicht gelingt die beiden zusammenzufügen.
Ich hoffe ihr wisst eine Lösung!

Vielen dank schon mal fü die Mühe. :toll:

Mfg Halo_Player




Teil 1:
Code:
import java.awt.*;
import java.awt.event.*;
import java.applet.*;
import java.util.*;

public class SplashShooter extends Applet {
	int x1;
	int y1;
	int x2;
	int y2;
	int x3; // Ganzahlvariablen
	int y3;
	int x4;
	int y4;
	int x5;
	int y5;

	private Image dbImage;
	private Graphics dbg;
	Image scheisse, flasche, dose, granate, tomate;
	Image hintergrund; // Bildvariablen
	Image bilder;

	int delay = 50; // timernoistartzeit(bewegung)
	javax.swing.Timer los = new javax.swing.Timer(delay, new starterAlle());// macht

	// nen
	// timer

	Image huhn; // imageobjekt für huhn
	Moorhuhn[] hennen = new Moorhuhn[5]; // max. moorhuhnzahl
	AudioClip schuss, anfang; // ton
	int bodycount = 0;
	Label counter = new Label("Los geht's!!! - Wähle deine Waffe aus: ");

	public void init() {

		anfang = getAudioClip(getCodeBase(), "doomsday.au");
		anfang.play();
		huhn = getImage(getCodeBase(), "huhn2.gif"); // bild vom huhn
		setSize(1024, 768); // appletgröße
		setBackground(Color.black);
		setForeground(Color.white);

		scheisse = getImage(getCodeBase(), "Scheisshaufen.gif");// laden einer
		// Imagedatei
		hintergrund = getImage(getCodeBase(), "stage.gif");
		flasche = getImage(getCodeBase(), "flasche.gif");
		tomate = getImage(getCodeBase(), "Tomate.gif");
		granate = getImage(getCodeBase(), "Granate.gif");
		dose = getImage(getCodeBase(), "Dose.gif");

		add(counter);

		for (int i = 0; i < hennen.length; i++) { // mach die hennen
			hennen[i] = new Moorhuhn(huhn);
		}

		los.start(); // starte den timer
		addMouseListener(new schuss());
	}

	public void start() {
	}

	public void paint( Graphics g ) {

		counter.setBounds(this.getWidth() * 1 / 5 + 20, this.getHeight() - 100,
				250, 20);

		for (int i = 0; i < hennen.length; i++) { // hennen anmalen
			hennen[i].paint(g);
		}
	}

	class starterAlle implements ActionListener { // timeraction
		public void actionPerformed( ActionEvent evt ) {
			for (int i = 0; i < hennen.length; i++) { // alle hennen
				// fliegenlassen
				hennen[i].move();
			}
			repaint();
		}
	}

	class schuss implements MouseListener {

		public void mousePressed( MouseEvent e ) {
			int xg = e.getX();
			int yg = e.getY();
			for (int i = 0; i < hennen.length; i++) { // hennen fliegenlassen

				if (hennen[i].erschossen(xg, yg)) {
					hennen[i] = new Moorhuhn(huhn);
					bodycount++;
					counter.setText(bodycount + " Sidos");
					if (bodycount >= 100) {
						counter.setText("100 Sidos- Ausrottung erfolgreich");
					}
					;
				}
			}
			schuss.play();
		}

		public void mouseReleased( MouseEvent e ) {
		}

		public void mouseEntered( MouseEvent e ) {
		}

		public void mouseExited( MouseEvent e ) {
		}

		public void mouseClicked( MouseEvent e ) {
		}
	}

}

class Moorhuhn extends Canvas implements ActionListener {

	static Random r = new Random();

	javax.swing.Timer weiter;

	Image h2;

	int x = -30;

	int y = 0;

	int richtung;

	private Image dbImage;

	private Graphics dbg;

	public Moorhuhn( Image h ) {

		h2 = h;

		y = zufall(380);
		richtung = zufall(2) % 2;
		if (richtung == 0) {
			x = (-30);
		}
		if (richtung == 1) {
			x = 530;
		}
	}

	public void paint( Graphics g2 ) {
		g2.drawImage(h2, x, y, this);
	}

	public void update( Graphics g2 ) {
		y = zufall(380);
		g2.drawImage(h2, x, y, this);

		// Initialisierung des DoubleBuffers
		if (dbImage == null) {
			dbImage = createImage(this.getSize().width, this.getSize().height);
			dbg = dbImage.getGraphics();
		}

		// Bildschirm im Hintergrund löschen
		dbg.setColor(getBackground());
		dbg.fillRect(0, 0, this.getSize().width, this.getSize().height);

		// Auf gelöschten Hintergrund Vordergrund zeichnen
		dbg.setColor(getForeground());
		paint(dbg);

		// Nun fertig gezeichnetes Bild Offscreen auf dem richtigen Bildschirm
		// anzeigen
		g2.drawImage(dbImage, 0, 0, this);

	}

	public static int zufall( int grenze ) { // zufallszahl zw. 0 und grenze
		return r.nextInt(grenze);
	}

	public void move() {
		if (richtung == 0) {
			x = x + 5;
		}
		if (richtung == 1) {
			x = x - 5;
		}

		y = y + zufall(10) - 5;
		if (x > 530) {
			x = -30;
		}
		if (x < -30) {
			x = 500;
		}
		if (y > 399) {
			y = 0;
		}
		if (y < -20) {
			y = 399;
		}
	}

	public boolean erschossen( int xs, int ys ) {
		if (x <= xs && xs <= (x + h2.getWidth(this)) && y <= ys
				&& ys <= (y + h2.getHeight(this))) {
			return true;
		} else {
			return false;
		}
	}

	public void noi() {
		weiter = new javax.swing.Timer(zufall(10000), this);
		weiter.start();
	}

	public void actionPerformed( ActionEvent e ) {
		move();
		weiter.stop();
	}
}
Teil2:
Code:
 import java.applet.AudioClip;
import java.awt.Cursor;
import java.awt.Font;
import java.awt.Graphics;
import java.awt.Image;
import java.awt.Label;
import java.awt.Point;
import java.awt.event.MouseEvent;
import java.awt.event.MouseListener;

public class SidoShooter implements MouseListener {
	// Deklarationsteil:
	int mausX, mausY;
	int x1;
	int y1;
	int x2;
	int y2;
	int x3; // Ganzahlvariablen
	int y3;
	int x4;
	int y4;
	int x5;
	int y5;
	int sidoX, sidoY;

	Image dbImage;
	Graphics dbg;

	Image scheisse, flasche, dose, granate, tomate;
	Image hintergrund; // Bildvariablen
	Image sido;

	Cursor cursorFlasche, cursorDose, cursorGranate, cursorTomate,
			cursorScheisse;

	// Cursorvariablen

	AudioClip glas, explosion, furz;
	AudioClip random; // Audiovariablen
	AudioClip anfang;

	Label counter;

	public void init() {// Konstruktor vom Applet

		addMouseListener(this);

		counter = new Label("Los geht's!!! - Wähle deine Waffe aus: ");
		add(counter);

		x1 = this.getWidth() * 1 / 5 - 100;// Ganzzahlvariablen werden Werte
                                            // übergeben
		y1 = this.getHeight() - 65;
		x2 = this.getWidth() * 2 / 5 - 125;
		y2 = this.getHeight() - 60;
		x3 = this.getWidth() * 3 / 5 - 135;
		y3 = this.getHeight() - 68;
		x4 = this.getWidth() * 4 / 5 - 125;
		y4 = this.getHeight() - 60;
		x5 = this.getWidth() * 5 / 5 - 140;
		y5 = this.getHeight() - 70;

		anfang = getAudioClip(getCodeBase(), "doomsday.au");// laden einer
                                                            // Audiodatei
		anfang.loop();// abspielen der Audiodatei in einer Loop-Schleife
		furz = getAudioClip(getCodeBase(), "fart.wav");
		explosion = getAudioClip(getCodeBase(), "explosion.wav");
		glas = getAudioClip(getCodeBase(), "breaking glass.wav");

		scheisse = getImage(getCodeBase(), "Scheisshaufen.gif");// laden einer
		// Imagedatei
		hintergrund = getImage(getCodeBase(), "stage.gif");
		flasche = getImage(getCodeBase(), "flasche.gif");
		tomate = getImage(getCodeBase(), "Tomate.gif");
		granate = getImage(getCodeBase(), "Granate.gif");
		dose = getImage(getCodeBase(), "Dose.gif");
		sido = getImage(getCodeBase(), "huhn2.gif");

		cursorFlasche = getToolkit().createCustomCursor(flasche,
				new Point(0, 0), "Cursor");// laden
		// von
		// CursorDateien
		cursorScheisse = getToolkit().createCustomCursor(scheisse,
				new Point(0, 0), "Cursor");
		cursorDose = getToolkit().createCustomCursor(dose, new Point(0, 0),
				"Cursor");
		cursorGranate = getToolkit().createCustomCursor(granate,
				new Point(0, 0), "Cursor");
		cursorTomate = getToolkit().createCustomCursor(tomate, new Point(0, 0),
				"Cursor");

	}

	public void paint( Graphics g )// paint-Methode
	{
		x1 = this.getWidth() * 1 / 5 - 100;
		y1 = this.getHeight() - 65;
		x2 = this.getWidth() * 2 / 5 - 125;
		y2 = this.getHeight() - 60;
		x3 = this.getWidth() * 3 / 5 - 135;
		y3 = this.getHeight() - 68;
		x4 = this.getWidth() * 4 / 5 - 125;
		y4 = this.getHeight() - 60;
		x5 = this.getWidth() * 5 / 5 - 140;
		y5 = this.getHeight() - 70;

		counter.setBounds(this.getWidth() * 1 / 5 + 20, this.getHeight() - 100,
				250, 20);

		g.setFont(new Font("SansSerif", Font.BOLD | Font.ITALIC, 24));// font
                                                                        // erzeugen
                                                                        // +
		// erstellen
		g
				.drawString(
						"Du befindest dich auf dem Splash - Deine Lieblingsrapper sind auf der Bühne: ",
						45, 50);
		// text schreiben
		g.drawLine(50, this.getHeight() - 10, this.getWidth() - 50, this
				.getHeight() - 10);// line zeichnen
		g.drawLine(50, this.getHeight() - 80, this.getWidth() - 50, this
				.getHeight() - 80);
		g.drawLine(50, this.getHeight() - 10, 50, this.getHeight() - 80);
		g.drawLine(this.getWidth() - 50, this.getHeight() - 10,
				this.getWidth() - 50, this.getHeight() - 80);
		g.drawLine(this.getWidth() * 1 / 5, this.getHeight() - 10, this
				.getWidth() * 1 / 5, this.getHeight() - 105);
		g.drawLine(this.getWidth() * 2 / 5, this.getHeight() - 10, this
				.getWidth() * 2 / 5, this.getHeight() - 80);
		g.drawLine(this.getWidth() * 3 / 5, this.getHeight() - 10, this
				.getWidth() * 3 / 5, this.getHeight() - 80);
		g.drawLine(this.getWidth() * 4 / 5, this.getHeight() - 10, this
				.getWidth() * 4 / 5, this.getHeight() - 105);
		g.drawLine(this.getWidth() * 1 / 5, this.getHeight() - 105, this
				.getWidth() * 4 / 5, this.getHeight() - 105);
		g.drawImage(flasche, x1, y1, this);// Bild positionieren
		g.drawImage(scheisse, x2, y2, this);
		g.drawImage(tomate, x3, y3, this);
		g.drawImage(granate, x4, y4, this);
		g.drawImage(dose, x5, y5, this);
		g.drawImage(hintergrund, 130, 70, this);

	}

	public void update( Graphics g ) {
		// Initialisierung des DoubleBuffers
		if (dbImage == null) {
			dbImage = createImage(this.getSize().width, this.getSize().height);
			dbg = dbImage.getGraphics();
		}

		// Bildschirm im Hintergrund löschen
		dbg.setColor(getBackground());
		dbg.fillRect(0, 0, this.getSize().width, this.getSize().height);

		// Auf gelöschten Hintergrund Vordergrund zeichnen
		dbg.setColor(getForeground());
		paint(dbg);

		// Nun fertig gezeichnetes Bild Offscreen auf dem richtigen Bildschirm
        // anzeigen
		g.drawImage(dbImage, 0, 0, this);
	}

	public boolean flascheClick() {
		if (x1 <= mausX && mausX <= (x1 + flasche.getWidth(this))
				&& y1 <= mausY && mausY <= (y1 + flasche.getHeight(this))) {
			return true;
		} else {
			return false;
		}
	}

	public boolean scheisseClick() {
		if (x2 <= mausX && mausX <= (x2 + scheisse.getWidth(this))
				&& y2 <= mausY && mausY <= (y2 + scheisse.getHeight(this))) {
			return true;
		} else {
			return false;
		}
	}

	public boolean tomateClick() {
		if (x3 <= mausX && mausX <= (x3 + tomate.getWidth(this)) && y3 <= mausY
				&& mausY <= (y3 + tomate.getHeight(this))) {
			return true;
		} else {
			return false;
		}
	}

	public boolean granateClick() {
		if (x4 <= mausX && mausX <= (x4 + granate.getWidth(this))
				&& y4 <= mausY && mausY <= (y4 + granate.getHeight(this))) {
			return true;
		} else {
			return false;
		}
	}

	public boolean doseClick() {
		if (x5 <= mausX && mausX <= (x5 + dose.getWidth(this)) && y5 <= mausY
				&& mausY <= (y5 + dose.getHeight(this))) {
			return true;
		}

		else {
			return false;
		}
	}

	public void mousePressed( MouseEvent e ) {
	}

	public void mouseReleased( MouseEvent e ) {
	}

	public void mouseEntered( MouseEvent e ) {
	}

	public void mouseExited( MouseEvent e ) {
	}

	public void mouseClicked( MouseEvent e ) {
		mausX = e.getX();
		mausY = e.getY();

		if (flascheClick() == true) {
			setCursor(cursorFlasche);
		} else if (granateClick() == true) {
			setCursor(cursorGranate);
		} else if (doseClick() == true) {
			setCursor(cursorDose);
		} else if (scheisseClick() == true) {
			setCursor(cursorScheisse);
		} else if (tomateClick() == true) {
			setCursor(cursorTomate);
		}
		;
	}

}

[Edit by Beni: den Code einmal durch einen Formater gejagt, damit er eingerückt ist.]
 

Campino

Top Contributor
Was hälst du davon in der Funktion die aufgerufen wird, wenn eines der Bilder getroffen wurde (müsste in Schuss sein) eine Variable hochzuzählen und wenn diese 5 ist den Mauscursor zu ändern und dann die Variable wieder auf null zu setzen.
 

Halo_Player

Mitglied
Ich glaub mein Problem ist noch nicht ganz klar geworden:
Teil 1 und Teil 2 sind momentan 2 unabhängig voneinander funktionierende Applets.

Teil 1 zeichnet 5 Fotos die sich durch Zufall bewegen, klickt man auf eines wird es gelöscht und ein neues Foto erzeugt. Der counter geht um eins höher.-> funktioniert!

Teil 2 (soll später in teil 1 integriert sein) ist eine mit Linien gezeichnete "Menüleiste" mit fünf Bildern:
--------------------------------------------


| Bild1 | Bild2 | Bild3 | Bild4 | Bild5 |


--------------------------------------------

Bei Klick auf eins der 5 bilder ändert sich der Mauscursor-> funktioniert auch!

Das Problem ich möcht Teil2 in Teil1 einfügen. Mein Lösungsvorschlag:

1)Die boolean-Methoden aus Teil 2 müssen in die klasse Moorhuhn von Teil 1 eingefügt werden, wo auch der
boolean erschossen ist.

2)Die if-Verzweigung im MouseListener von Teil 2 muss in dem MouseListener der Klasse Schuss von Teil 1 eingefügt werden.

3)Parameterübergabe zwischen den klassen:
-In der Hauptklasse SplashShooter werden alle Bilder,Variablen erzeugt etc erzeugt und an Moorhuhn übergeben.
-> Die boolean-methoden in Moorhuhn brauchen Die Image-objekte, int x1-y5,
sowie die maus-Koordinaten(Klasse Schuss)

-Die klasse Schuss muss eine Anfrage besitzen in der die aktuellen Mauskoordinaten(bei Mausklick)
übergeben werden.

Es hapert an Punkt 3 denke ich, ich krieg es nicht hin das der Compiler nicht mäckert! :)

Vieleicht ist mein Problem jetzt klarer geworden, als nur mit Quelltext.

Ich hoffe ihr könnt helfen!

Mfg Halo_Player
 

The_S

Top Contributor
Für die Kommunikation zwischen zwei Applets kannst du dir mal getAppletContext() anschauen. (ohne deinen Code gelesen zu haben)

Was meckert der Compiler denn?
 

Halo_Player

Mitglied
So habs jetzt endlich geschaft die beiden Applets so zusammenzufügen, das der Compiler zufrieden ist.
Leider ändert sich der Cursor, aber nichts bei Click auf ein Bild.
Habt ihr vielleicht noch ne Idee wodrans happert?

Edit: Ich habe, weil der code jetzt ja schon recht kopmlex ist, mal n' paar neue Kommentare hinzugefügt. Sie sollen den Funktionsablauf der Cursuranimation(Bildermenü),die noch nicht so richtig funktioniert, erklären . Alles andere, also die Animation von fünf gleichen Bildern, die bei Anklicken den Counter um eins erhöhen, das angeklickte Bild löschen und ein neues Bild erstellen, funktioniert schon. Ich habe mich deswegen auf das einigermaßen Wichtige beschränkt.

Code:
import java.awt.*; 
import java.awt.event.*; 
import java.applet.*; 
import java.util.*; 
import java.awt.Toolkit.*;
import java.applet.AudioClip; 
import java.awt.Cursor; 
import java.awt.Font; 
import java.awt.Graphics; 
import java.awt.Image; 
import java.awt.Label; 
import java.awt.Point; 
import java.awt.event.MouseEvent; 
import java.awt.event.MouseListener; 

public class SplashShooter extends Applet { 
int x1; 
int y1; 
int x2; 
int y2; 
int x3; // Ganzahlvariablen 
int y3; 
int x4; 
int y4; 
int x5; 
int y5; 

private Image dbImage;  //DoubleBuffer 
private Graphics dbg; 

Image scheisse, flasche, dose, granate, tomate;  // Bildvariablen für das Menü(bzw. die Cursor)
Image hintergrund; //hintergrundbild


Cursor cursorFlasche, cursorDose, cursorGranate, cursorTomate,
         cursorScheisse;                      //Cursorvariablen
         
 Schuss curAnim=new Schuss();       //Objekt der Klasse Schuss(für Parameterübergabe)

int delay = 50; // timernoistartzeit(bewegung) 
javax.swing.Timer los = new javax.swing.Timer(delay, new starterAlle()); // timer 

Image huhn; // image für das bild das über den Hintergrund wandert 

Moorhuhn[] hennen = new Moorhuhn[5]; //Array [ max. moorhuhnzahl ] // Bilder Array (für die Moorhühner)
AudioClip schuss, anfang; // ton 
int bodycount = 0; 
Label counter = new Label("Los geht's!!! - Wähle deine Waffe aus: ");  // Counter

public void init() { 
	
	

anfang = getAudioClip(getCodeBase(), "doomsday.au");     //Hintergrundmelodie
anfang.play(); 

huhn = getImage(getCodeBase(), "huhn2.gif"); // bild für das Array wird geladen

setSize(1024, 768); // appletgröße 

setBackground(Color.black); 
setForeground(Color.white); 

hintergrund = getImage(getCodeBase(), "stage.gif"); // hintergrundbild wird geladen(imageobjekt)

scheisse = getImage(getCodeBase(), "Scheisshaufen.gif");
flasche = getImage(getCodeBase(), "flasche.gif");          // Bilder für das Bildermenü wird geladen(imageobjekt)
tomate = getImage(getCodeBase(), "Tomate.gif"); 
granate = getImage(getCodeBase(), "Granate.gif"); 
dose = getImage(getCodeBase(), "Dose.gif"); 

cursorFlasche = getToolkit().createCustomCursor(flasche, new Point(0, 0), "Cursor");   
cursorScheisse = getToolkit().createCustomCursor(scheisse,new Point(0, 0), "Cursor");
cursorDose = getToolkit().createCustomCursor(dose, new Point(0, 0), "Cursor");            //Cursor mit den einzelnen
cursorGranate = getToolkit().createCustomCursor(granate, new Point(0, 0), "Cursor");   // einzelnen Bildern
cursorTomate = getToolkit().createCustomCursor(tomate, new Point(0, 0), "Cursor");

add(counter); 

for (int i = 0; i < hennen.length; i++) { 
hennen[i] = new Moorhuhn(huhn,scheisse, flasche, dose, granate, tomate);    // Parameterübergabe der Bilder an 
                                                                                          // Klasse Moorhuhn
} 

los.start(); 
addMouseListener(new Schuss()); 
} 

public void start() { 
} 

public void paint( Graphics g ) { 
  x1 = this.getWidth() * 1 / 5 - 100; 
y1 = this.getHeight() - 65; 
x2 = this.getWidth() * 2 / 5 - 125; 
y2 = this.getHeight() - 60; 
x3 = this.getWidth() * 3 / 5 - 135;           //Die jeweilige x und y-Koordinaten der Bilder(also der Punkt links oben)  
y3 = this.getHeight() - 68; 
x4 = this.getWidth() * 4 / 5 - 125; 
y4 = this.getHeight() - 60; 
x5 = this.getWidth() * 5 / 5 - 140; 
y5 = this.getHeight() - 70; 

counter.setBounds(this.getWidth() * 1 / 5 + 20, this.getHeight() - 100, 
250, 20); 

g.setFont(new Font("SansSerif", Font.BOLD | Font.ITALIC, 24));// font 
// erzeugen 
// + 
// erstellen 

g.drawString( "Du befindest dich auf dem Splash - Deine Lieblingsrapper sind auf der Bühne: ",45, 50); 

//Überschrift
 
g.drawLine(50, this.getHeight() - 10, this.getWidth() - 50, this 
.getHeight() - 10);                                                                     
g.drawLine(50, this.getHeight() - 80, this.getWidth() - 50, this 
.getHeight() - 80); 
g.drawLine(50, this.getHeight() - 10, 50, this.getHeight() - 80); 
g.drawLine(this.getWidth() - 50, this.getHeight() - 10, 
this.getWidth() - 50, this.getHeight() - 80); 
g.drawLine(this.getWidth() * 1 / 5, this.getHeight() - 10, this 
.getWidth() * 1 / 5, this.getHeight() - 105); 
g.drawLine(this.getWidth() * 2 / 5, this.getHeight() - 10, this 
.getWidth() * 2 / 5, this.getHeight() - 80); 
g.drawLine(this.getWidth() * 3 / 5, this.getHeight() - 10, this              // Rahmen für das Menü 
.getWidth() * 3 / 5, this.getHeight() - 80); 
g.drawLine(this.getWidth() * 4 / 5, this.getHeight() - 10, this 
.getWidth() * 4 / 5, this.getHeight() - 105); 
g.drawLine(this.getWidth() * 1 / 5, this.getHeight() - 105, this 
.getWidth() * 4 / 5, this.getHeight() - 105); 
                                                                       //                        _______              
g.drawImage(flasche, x1, y1, this);    // Bilder für das Menü                                   |Counter|           
g.drawImage(scheisse, x2, y2, this);                                          //   --------------------------------------------   
g.drawImage(tomate, x3, y3, this);                                            
g.drawImage(granate, x4, y4, this);                                           //    | Bild1 | Bild2 | Bild3 | Bild4 | Bild5 | 
g.drawImage(dose, x5, y5, this); 
                                                                      //            -------------------------------------------- 

g.drawImage(hintergrund, 130, 70, this);   // Hintergrungbild wrid gezeichnet

                                         




counter.setBounds(this.getWidth() * 1 / 5 + 20, this.getHeight() - 100, 250, 20); 


for (int i = 0; i < hennen.length; i++) {
hennen[i].paint(g); 
  }
     }

public void update( Graphics g ) { 
// Initialisierung des DoubleBuffers 
if (dbImage == null) { 
dbImage = createImage(this.getSize().width, this.getSize().height); 
dbg = dbImage.getGraphics(); 
} 

// Bildschirm im Hintergrund löschen 
dbg.setColor(getBackground()); 
dbg.fillRect(0, 0, this.getSize().width, this.getSize().height); 

// Auf gelöschten Hintergrund Vordergrund zeichnen 
dbg.setColor(getForeground()); 
paint(dbg); 

// Nun fertig gezeichnetes Bild Offscreen auf dem richtigen Bildschirm 
// anzeigen 
g.drawImage(dbImage, 0, 0, this); 



} 
public void cursorSet(){                                           // Der Cursor soll hier verändert werden

if(curAnim.random()==1){setCursor(cursorFlasche);}                   //Je nachdem welche zahl von der Anfrage
else if(curAnim.random()==2){setCursor(cursorGranate);}           //random(), in der Klasse Schuss() zurückgegeben
else if(curAnim.random()==3){setCursor(cursorDose);}               //wird, wird der Cursor geändert
else if(curAnim.random()==4){setCursor(cursorScheisse);}
else if(curAnim.random()==5){setCursor(cursorTomate);};




}

class starterAlle implements ActionListener { // timeraction 
public void actionPerformed( ActionEvent evt ) { 
for (int i = 0; i < hennen.length; i++) {hennen[i].move(); 
} 
repaint(); 
} 
} 

class Schuss implements MouseListener { 

  int cursorRandom;      
Moorhuhn booleans = new Moorhuhn(huhn,scheisse, flasche, dose, granate, tomate); 
// Objekt der klasse Moorhuhn       

       
public void mousePressed( MouseEvent e ) { 
int xg = e.getX();                             // Mauskoordinaten
int yg = e.getY();

booleans.flascheClick(xg, yg);
booleans.granateClick(xg, yg);
booleans.doseClick(xg, yg);                       //die Booleans in der Klasse Moohuhn werden aufgerufen
booleans.flascheClick(xg, yg);
booleans.scheisseClick(xg, yg);

 if (booleans.flascheClick(xg, yg) ) {   // wen der boolean wahr ist ....
  booleans = new Moorhuhn(huhn,scheisse, flasche, dose, granate, tomate); //Parameterübergabe an Moorhuhn
cursorRandom = 1;                                                       //Wert für anfrage random()                      

} else if (booleans.granateClick(xg, yg)) {                      // wen der boolean wahr ist ....
booleans = new Moorhuhn(huhn,scheisse, flasche, dose, granate, tomate); //Parameterübergabe an Moorhuhn
cursorRandom =2;                                                        //Wert für anfrage random()           


} else if (booleans.doseClick(xg, yg)) {                          // wen der boolean wahr ist ....
booleans = new Moorhuhn(huhn,scheisse, flasche, dose, granate, tomate); //Parameterübergabe an Moorhuhn
cursorRandom =3;                                                        //Wert für anfrage random()           


} else if (booleans.scheisseClick(xg, yg)) {                    // wen der boolean wahr ist ....
  booleans = new Moorhuhn(huhn,scheisse, flasche, dose, granate, tomate); //Parameterübergabe an Moorhuhn
cursorRandom =4;                                                       //Wert für anfrage random()           

} else if (booleans.tomateClick(xg, yg)) {                     // wen der boolean wahr ist ....
  booleans = new Moorhuhn(huhn,scheisse, flasche, dose, granate, tomate); //Parameterübergabe an Moorhuhn
cursorRandom =5; };                                                  //Wert für anfrage random()           


for (int i = 0; i < hennen.length; i++) {

if (hennen[i].erschossen(xg, yg)) { 
hennen[i] = new Moorhuhn(huhn,scheisse, flasche, dose, granate, tomate); 
bodycount++; 
counter.setText(bodycount + " Sidos"); 
if (bodycount >= 100) { 
counter.setText("100 Sidos- Ausrottung erfolgreich"); 
} 
; 
} 
} 
schuss.play(); 
} 

public void mouseReleased( MouseEvent e ) { 
} 

public void mouseEntered( MouseEvent e ) { 
} 

public void mouseExited( MouseEvent e ) { 
} 

public void mouseClicked( MouseEvent e ) {

 
 
 
}public int random(){ return cursorRandom;}// Die anfrage Random gibt einen Wert zurück,                        
}                                                                //  der dem jeweiligen Bild das angeklickt entspricht
                                                                  
class Moorhuhn extends Canvas implements ActionListener { 

static Random r = new Random(); 

javax.swing.Timer weiter; 

Image h2,zScheisse, zFlasche, zDose, zGranate, zTomate;   // neue Bildernamen

int x = -30; 

int y = 0; 
 int x1;
   int y1;
   int x2;
   int y2;
   int x3; // Ganzahlvariablen
   int y3;
   int x4;
   int y4;
   int x5;
   int y5;
int richtung; 

private Image dbImage;   //DoubleBuffer 
private Graphics dbg; 

public Moorhuhn( Image h,Image pScheisse,Image pFlasche,Image pDose,Image pGranate ,Image pTomate) { 
// Parmeterübergabe der Bilder 

 x1 = this.getWidth() * 1 / 5 - 100;   
      y1 = this.getHeight() - 65;
      x2 = this.getWidth() * 2 / 5 - 125;
      y2 = this.getHeight() - 60;
      x3 = this.getWidth() * 3 / 5 - 135;      //Die jeweilige x und y-Koordinaten der Bilder(also der Punkt links oben)
      y3 = this.getHeight() - 68;
      x4 = this.getWidth() * 4 / 5 - 125;
      y4 = this.getHeight() - 60;
      x5 = this.getWidth() * 5 / 5 - 140;
      y5 = this.getHeight() - 70;

h2 = h; 
zScheisse = pScheisse;
zFlasche = pFlasche;
zDose = pDose;                                         //Werte werden den neuen Bildervariablen zugeteilt
zGranate = pGranate;
zTomate = pTomate ;

y = zufall(380); 
richtung = zufall(2) % 2; 
if (richtung == 0) { 
x = (-30); 
} 
if (richtung == 1) { 
x = 530; 
} 
} 

public void paint( Graphics g2 ) { 
g2.drawImage(h2, x, y, this); 
} 

public void update( Graphics g2 ) { 
y = zufall(380); 
g2.drawImage(h2, x, y, this); 

// Initialisierung des DoubleBuffers 
if (dbImage == null) { 
dbImage = createImage(this.getSize().width, this.getSize().height); 
dbg = dbImage.getGraphics(); 
} 

// Bildschirm im Hintergrund löschen 
dbg.setColor(getBackground()); 
dbg.fillRect(0, 0, this.getSize().width, this.getSize().height); 

// Auf gelöschten Hintergrund Vordergrund zeichnen 
dbg.setColor(getForeground()); 
paint(dbg); 

// Nun fertig gezeichnetes Bild Offscreen auf dem richtigen Bildschirm 
// anzeigen 
g2.drawImage(dbImage, 0, 0, this); 

} 

public static int zufall( int grenze ) {return r.nextInt(grenze); 
} 

public void move() { 
if (richtung == 0) { 
x = x + 5; 
} 
if (richtung == 1) { 
x = x - 5; 
} 

y = y + zufall(10) - 5; 
if (x > 530) { 
x = -30; 
} 
if (x < -30) { 
x = 500; 
} 
if (y > 399) { 
y = 0; 
} 
if (y < -20) { 
y = 399; 
} 
}                                               
                                      //Booleans für die Abfrage, ob ein Bild angeklickt wurde
public boolean flascheClick(int xs, int ys) {  
if (x1 <= xs &&xs <= (x1 + zFlasche.getWidth(this))       // Wenn x-Koordinate vom bild <= Maus-X und Maus-X
&& y1 <= ys && ys <= (y1 + zFlasche.getHeight(this))) { // <= x-Koordinate vom bild + Bildbreite und
                                                        // Wenn y-Koordinate vom bild <= Maus-Y und Maus-Y
                                                       // <= x-Koordinate vom bild + Bildbreite 
return true; 
} else { 
return false; 
} 
} 

public boolean scheisseClick(int xs, int ys) { 
if (x2 <= xs && xs <= (x2 + zScheisse.getWidth(this))
&& y2 <= ys && ys <= (y2 + zScheisse.getHeight(this))) {
return true; 
} else { 
return false; 
} 
} 

public boolean tomateClick(int xs, int ys) { 
if (x3 <= xs && xs <= (x3 + zTomate.getWidth(this)) && y3 <= ys
&&ys <= (y3 + zTomate.getHeight(this))) { 
return true; 
} else { 
return false; 
} 
 }

public boolean granateClick(int xs, int ys) { 
if (x4 <= xs&& xs <= (x4 + zGranate.getWidth(this)) 
&& y4 <=ys&& ys <= (y4 + zGranate.getHeight(this))) { 
return true; 
} else { 
return false; 
} 
} 

public boolean doseClick(int xs, int ys) { 
if (x5 <= xs &&xs<= (x5 + zDose.getWidth(this)) && y5 <= ys 
&&ys <= (y5 + zDose.getHeight(this))) { 
return true; 
} 

else { 
return false; 
} 
  }
public boolean erschossen( int xs, int ys ) { 
if (x <= xs && xs <= (x + h2.getWidth(this)) && y <= ys 
&& ys <= (y + h2.getHeight(this))) { 
return true; 
} else { 
return false; 
}
} 

public void noi() { 
weiter = new javax.swing.Timer(zufall(10000), this); 
weiter.start(); 
} 

public void actionPerformed( ActionEvent e ) { 
move(); 
weiter.stop(); 
} 
}
 

Halo_Player

Mitglied
Is jetzt zwar nicht mehr richtig objektorientiert, aber es funktioniert endlich!
Wenn ihr trotzdem noch ne Lösung wisst, wie man's besser machen kann,also objektorientiert,
dann postet sie bitte noch!

Mfg Halo_Player

Code:
import java.applet.AudioClip; 
import java.awt.Cursor; 
import java.awt.Font; 
import java.awt.Graphics; 
import java.awt.Image; 
import java.awt.Label; 
import java.awt.Point; 
import java.awt.event.MouseEvent; 
import java.awt.event.MouseListener; 
import java.awt.*; 
import java.awt.event.*; 
import java.applet.*; 
import java.util.*; 

public class SplashShooter extends Applet implements MouseListener { 
int x,y;
int mausX, mausY; 
int x1; 
int y1; 
int x2; 
int y2; 
int x3; // Ganzahlvariablen 
int y3; 
int x4; 
int y4; 
int x5; 
int y5; 

private Image dbImage; 
private Graphics dbg; 
Image scheisse, flasche, dose, granate, tomate; 
Image hintergrund; // Bildvariablen 
Image bilder; 
Cursor cursorFlasche, cursorDose, cursorGranate, cursorTomate, 
cursorScheisse;


int delay = 50; // timernoistartzeit(bewegung) 
javax.swing.Timer los = new javax.swing.Timer(delay, new starterAlle());// macht 

// nen 
// timer 

Image huhn; // imageobjekt für huhn 
Moorhuhn[] hennen = new Moorhuhn[5]; // max. moorhuhnzahl 
AudioClip schuss, anfang; // ton 
int bodycount = 0; 
Label counter = new Label("Los geht's!!! - Wähle deine Waffe aus: "); 


public void init() { 
x1 = this.getWidth() * 1 / 5 - 100; 
y1 = this.getHeight() - 65; 
x2 = this.getWidth() * 2 / 5 - 125; 
y2 = this.getHeight() - 60; 
x3 = this.getWidth() * 3 / 5 - 135; 
y3 = this.getHeight() - 68; 
x4 = this.getWidth() * 4 / 5 - 125; 
y4 = this.getHeight() - 60; 
x5 = this.getWidth() * 5 / 5 - 140; 
y5 = this.getHeight() - 70; 



anfang = getAudioClip(getCodeBase(), "doomsday.au"); 
anfang.loop(); 
huhn = getImage(getCodeBase(), "huhn2.gif"); // bild vom huhn 
setSize(1024, 768); // appletgröße 
setBackground(Color.black); 
setForeground(Color.white); 

scheisse = getImage(getCodeBase(), "Scheisshaufen.gif");// laden einer 
// Imagedatei 
hintergrund = getImage(getCodeBase(), "stage.gif"); 
flasche = getImage(getCodeBase(), "flasche.gif"); 
tomate = getImage(getCodeBase(), "Tomate.gif"); 
granate = getImage(getCodeBase(), "Granate.gif"); 
dose = getImage(getCodeBase(), "Dose.gif"); 

cursorFlasche = getToolkit().createCustomCursor(flasche, 
new Point(0, 0), "Cursor");// laden 
// von 
// CursorDateien 
cursorScheisse = getToolkit().createCustomCursor(scheisse, 
new Point(0, 0), "Cursor"); 
cursorDose = getToolkit().createCustomCursor(dose, new Point(0, 0), 
"Cursor"); 
cursorGranate = getToolkit().createCustomCursor(granate, 
new Point(0, 0), "Cursor"); 
cursorTomate = getToolkit().createCustomCursor(tomate, new Point(0, 0), 
"Cursor"); 



add(counter); 
addMouseListener(this);
for (int i = 0; i < hennen.length; i++) {

hennen[i] = new Moorhuhn(huhn); 

} 

los.start(); // starte den timer 
addMouseListener(new schuss()); 
} 
public void paint( Graphics g ) { 
		x1 = this.getWidth() * 1 / 5 - 100; 
y1 = this.getHeight() - 65; 
x2 = this.getWidth() * 2 / 5 - 125; 
y2 = this.getHeight() - 60; 
x3 = this.getWidth() * 3 / 5 - 135; 
y3 = this.getHeight() - 68; 
x4 = this.getWidth() * 4 / 5 - 125; 
y4 = this.getHeight() - 60; 
x5 = this.getWidth() * 5 / 5 - 140; 
y5 = this.getHeight() - 70; 

counter.setBounds(this.getWidth() * 1 / 5 + 20, this.getHeight() - 100, 
250, 20); 

g.setFont(new Font("SansSerif", Font.BOLD | Font.ITALIC, 24));// font 
// erzeugen 
// + 
// erstellen 
g 
.drawString( 
"Du befindest dich auf dem Splash - Deine Lieblingsrapper sind auf der Bühne: ", 
45, 50); 
// text schreiben 
g.drawLine(50, this.getHeight() - 10, this.getWidth() - 50, this 
.getHeight() - 10);// line zeichnen 
g.drawLine(50, this.getHeight() - 80, this.getWidth() - 50, this 
.getHeight() - 80); 
g.drawLine(50, this.getHeight() - 10, 50, this.getHeight() - 80); 
g.drawLine(this.getWidth() - 50, this.getHeight() - 10, 
this.getWidth() - 50, this.getHeight() - 80); 
g.drawLine(this.getWidth() * 1 / 5, this.getHeight() - 10, this 
.getWidth() * 1 / 5, this.getHeight() - 105); 
g.drawLine(this.getWidth() * 2 / 5, this.getHeight() - 10, this 
.getWidth() * 2 / 5, this.getHeight() - 80); 
g.drawLine(this.getWidth() * 3 / 5, this.getHeight() - 10, this 
.getWidth() * 3 / 5, this.getHeight() - 80); 
g.drawLine(this.getWidth() * 4 / 5, this.getHeight() - 10, this 
.getWidth() * 4 / 5, this.getHeight() - 105); 
g.drawLine(this.getWidth() * 1 / 5, this.getHeight() - 105, this 
.getWidth() * 4 / 5, this.getHeight() - 105); 
g.drawImage(flasche, x1, y1, this);// Bild positionieren 
g.drawImage(scheisse, x2, y2, this); 
g.drawImage(tomate, x3, y3, this); 
g.drawImage(granate, x4, y4, this); 
g.drawImage(dose, x5, y5, this); 
g.drawImage(hintergrund, 130, 70, this); 


for (int i = 0; i < hennen.length; i++) {  
hennen[i].paint(g); 
}

} 


public void update( Graphics g ) { 


// Initialisierung des DoubleBuffers 
if (dbImage == null) { 
dbImage = createImage(this.getSize().width, this.getSize().height); 
dbg = dbImage.getGraphics(); 
} 

// Bildschirm im Hintergrund löschen 
dbg.setColor(getBackground()); 
dbg.fillRect(0, 0, this.getSize().width, this.getSize().height); 

// Auf gelöschten Hintergrund Vordergrund zeichnen 
dbg.setColor(getForeground()); 
paint(dbg); 

// Nun fertig gezeichnetes Bild Offscreen auf dem richtigen Bildschirm 
// anzeigen 
g.drawImage(dbImage, 0, 0, this); 

}
public boolean flascheClick() { 
if (x1 <= mausX && mausX <= (x1 + flasche.getWidth(this)) 
&& y1 <= mausY && mausY <= (y1 + flasche.getHeight(this))) { 
return true; 
} else { 
return false; 
} 
} 

public boolean scheisseClick() { 
if (x2 <= mausX && mausX <= (x2 + scheisse.getWidth(this)) 
&& y2 <= mausY && mausY <= (y2 + scheisse.getHeight(this))) { 
return true; 
} else { 
return false; 
} 
} 

public boolean tomateClick() { 
if (x3 <= mausX && mausX <= (x3 + tomate.getWidth(this)) && y3 <= mausY 
&& mausY <= (y3 + tomate.getHeight(this))) { 
return true; 
} else { 
return false; 
} 
} 

public boolean granateClick() { 
if (x4 <= mausX && mausX <= (x4 + granate.getWidth(this)) 
&& y4 <= mausY && mausY <= (y4 + granate.getHeight(this))) { 
return true; 
} else { 
return false; 
} 
} 

public boolean doseClick() { 
if (x5 <= mausX && mausX <= (x5 + dose.getWidth(this)) && y5 <= mausY 
&& mausY <= (y5 + dose.getHeight(this))) { 
return true; 
} 

else { 
return false; 
} 
} 

public void mousePressed( MouseEvent e ) { 
} 

public void mouseReleased( MouseEvent e ) { 
} 

public void mouseEntered( MouseEvent e ) { 
} 

public void mouseExited( MouseEvent e ) { 
} 

public void mouseClicked( MouseEvent e ) { 
mausX = e.getX(); 
mausY = e.getY(); 

if (flascheClick() == true) { 
setCursor(cursorFlasche); 
} else if (granateClick() == true) { 
setCursor(cursorGranate); 
} else if (doseClick() == true) { 
setCursor(cursorDose); 
} else if (scheisseClick() == true) { 
setCursor(cursorScheisse); 
} else if (tomateClick() == true) { 
setCursor(cursorTomate); 
} 
; 
} 

 
public void start() { 
} 


class starterAlle implements ActionListener { // timeraction 
public void actionPerformed( ActionEvent evt ) { 
for (int i = 0; i < hennen.length; i++) { // alle hennen 
// fliegenlassen 
hennen[i].move(); 
} 
repaint(); 

} 

} 

class schuss implements MouseListener { 

public void mousePressed( MouseEvent e ) { 
int xg = e.getX(); 
int yg = e.getY(); 
for (int i = 0; i < hennen.length; i++) { // hennen fliegenlassen 

if (hennen[i].erschossen(xg, yg)) { 
hennen[i] = new Moorhuhn(huhn); 
bodycount++; 
counter.setText(bodycount + " Sidos"); 
if (bodycount >= 100) { 
counter.setText("100 Sidos- Ausrottung erfolgreich"); 
} 
; 
} 
} 
schuss.play(); 
} 

public void mouseReleased( MouseEvent e ) { 
} 

public void mouseEntered( MouseEvent e ) { 
} 

public void mouseExited( MouseEvent e ) { 
} 

public void mouseClicked( MouseEvent e ) { 
} 
} 

} 

class Moorhuhn extends Canvas implements ActionListener { 

static Random r = new Random(); 

javax.swing.Timer weiter; 

Image h2; 

int x = -30; 

int y = 0; 

int richtung; 

private Image dbImage; 

private Graphics dbg; 

public Moorhuhn( Image h ) { 

h2 = h; 

y = zufall(380); 
richtung = zufall(2) % 2; 
if (richtung == 0) { 
x = (-30); 
} 
if (richtung == 1) { 
x = 530; 
} 
} 

public void paint( Graphics g2 ) { 
g2.drawImage(h2, x, y, this); 
} 

public void update( Graphics g2 ) { 
y = zufall(380); 
g2.drawImage(h2, x, y, this); 

// Initialisierung des DoubleBuffers 
if (dbImage == null) { 
dbImage = createImage(this.getSize().width, this.getSize().height); 
dbg = dbImage.getGraphics(); 
} 

// Bildschirm im Hintergrund löschen 
dbg.setColor(getBackground()); 
dbg.fillRect(0, 0, this.getSize().width, this.getSize().height); 

// Auf gelöschten Hintergrund Vordergrund zeichnen 
dbg.setColor(getForeground()); 
paint(dbg); 

// Nun fertig gezeichnetes Bild Offscreen auf dem richtigen Bildschirm 
// anzeigen 
g2.drawImage(dbImage, 0, 0, this); 

} 

public static int zufall( int grenze ) { // zufallszahl zw. 0 und grenze 
return r.nextInt(grenze); 
} 

public void move() { 
if (richtung == 0) { 
x = x + 5; 
} 
if (richtung == 1) { 
x = x - 5; 
} 

y = y + zufall(10) - 5; 
if (x > 530) { 
x = -30; 
} 
if (x < -30) { 
x = 500; 
} 
if (y > 399) { 
y = 0; 
} 
if (y < -20) { 
y = 399; 
} 
} 

public boolean erschossen( int xs, int ys ) { 
if (x <= xs && xs <= (x + h2.getWidth(this)) && y <= ys 
&& ys <= (y + h2.getHeight(this))) { 
return true; 
} else { 
return false; 
} 
} 

public void noi() { 
weiter = new javax.swing.Timer(zufall(10000), this); 
weiter.start(); 
} 

public void actionPerformed( ActionEvent e ) { 
move(); 
weiter.stop(); 
} 
}
 
Status
Nicht offen für weitere Antworten.
Ähnliche Java Themen
  Titel Forum Antworten Datum
W Dringende Hilfe bei applet notinied benötigt Tools - Maven, Gradle, Ant & mehr 7
M Sternenhimmel Applet Hilfe! Tools - Maven, Gradle, Ant & mehr 8
A Hilfe! Java Applet Lake von Anfy - wie in HP einbinden? Tools - Maven, Gradle, Ant & mehr 25
G Hilfe! Java Applet Tools - Maven, Gradle, Ant & mehr 6
S in Applet "umwandeln" - HILFE! Tools - Maven, Gradle, Ant & mehr 14
4 Hilfe bei einem BB Code formatierer Tools - Maven, Gradle, Ant & mehr 4
A Buckminster hilfe Tools - Maven, Gradle, Ant & mehr 18
Chris81T Maven Hilfe bei EAR packaging mit maven-ear-plugin Tools - Maven, Gradle, Ant & mehr 1
D Maven, Cargo, Selenium - brauche Hilfe bei Konfiguration Tools - Maven, Gradle, Ant & mehr 4
N im JAR läufts nicht :( hilfe Tools - Maven, Gradle, Ant & mehr 2
J Online Shop mit Hilfe eines Applets Tools - Maven, Gradle, Ant & mehr 17
S Vorschläge/Hilfe: Tunierbaum bis der Arzt kommt. Tools - Maven, Gradle, Ant & mehr 2
M JavaApplet Projekt und clien-side read/write.Bitte um Hilfe. Tools - Maven, Gradle, Ant & mehr 6
B Java neuling, brauche hilfe Tools - Maven, Gradle, Ant & mehr 4
G Hilfe bei Bildgröße in Java [dekompilierter Bytecode] Tools - Maven, Gradle, Ant & mehr 5
G timer erstellen dringend hilfe Tools - Maven, Gradle, Ant & mehr 9
P Hilfe - Seltsame Fehlermeldung nach Signatur eines Applets! Tools - Maven, Gradle, Ant & mehr 12
F Hilfe, wie programmiert man einen Packer mit Java? Tools - Maven, Gradle, Ant & mehr 2
G Hilfe bitte bitte Tools - Maven, Gradle, Ant & mehr 2
L Mittelwertberechnung Hilfe Tools - Maven, Gradle, Ant & mehr 2
G [HILFE!]Dezimalzahl Umwandler in frei wählbares Zahlensystem Tools - Maven, Gradle, Ant & mehr 3
B Applet: com.sun.deploy.security.BlockedException :-( Tools - Maven, Gradle, Ant & mehr 0
M Applet Applet legt Browser lahm Tools - Maven, Gradle, Ant & mehr 3
J Applet Aus anderer Browserinstanz Applet abfragen Tools - Maven, Gradle, Ant & mehr 2
P Linux Applet/Webstart Schriftunterschiede Tools - Maven, Gradle, Ant & mehr 3
E JMol -Applet Einbindung Tools - Maven, Gradle, Ant & mehr 0
T Applet Applet und IText wirft Incompatible magic value 1008813135 Fehler Tools - Maven, Gradle, Ant & mehr 6
P Applet Java Applet läuft im Browser nicht mehr (HTTPClient - NoClassDefFoundError) Tools - Maven, Gradle, Ant & mehr 3
P Applet Applet Signatur auf Server mit SSL-Zertifikat? Tools - Maven, Gradle, Ant & mehr 7
H Applet Applet wird nicht angezeigt Tools - Maven, Gradle, Ant & mehr 2
M Applet Applet funktioniert in Google Chrome nicht Tools - Maven, Gradle, Ant & mehr 2
O Applet "Anwendung kann nicht ausgeführt werden" Tools - Maven, Gradle, Ant & mehr 6
Q Applet Fehlermeldung bei Applet-Wechsel Tools - Maven, Gradle, Ant & mehr 4
T Daten per POST-Methode aus Java-Applet nach php-Script senden Tools - Maven, Gradle, Ant & mehr 3
R Applet friert Adresszeile des Firefox ein Tools - Maven, Gradle, Ant & mehr 2
K Applet als Jar-Datei in HTML einbinden Tools - Maven, Gradle, Ant & mehr 14
H Applet-Fehlermeldung Tools - Maven, Gradle, Ant & mehr 10
H Applet läuft nicht im Browser Tools - Maven, Gradle, Ant & mehr 3
Q Applet Applet läuft nicht im Browser Tools - Maven, Gradle, Ant & mehr 14
J Applet URL mittels TTS als Applet lesen lassen Tools - Maven, Gradle, Ant & mehr 40
F Applet verwischt, wenn Seite gescrollt wird Tools - Maven, Gradle, Ant & mehr 16
S Applet Applet mit C# öffnen: java.lang.SecurityException: Permission denied (WinXP) Tools - Maven, Gradle, Ant & mehr 8
J Applet-Quellcode einsehen Tools - Maven, Gradle, Ant & mehr 6
E Applet Applet und Datenbank Konzept Tools - Maven, Gradle, Ant & mehr 4
A Applet: Html Datei und Class Datei nicht im selben Verzeichnis Tools - Maven, Gradle, Ant & mehr 2
S Applet soll Textdatei von fremdem Server öffnen Tools - Maven, Gradle, Ant & mehr 8
E Java Applet bearbeiten Tools - Maven, Gradle, Ant & mehr 8
Quasar Wie signiere ich mein Applet richtig? Tools - Maven, Gradle, Ant & mehr 6
M mit Applet Javascript Aufrufen Tools - Maven, Gradle, Ant & mehr 2
S Applet and stop() method und gui blocked Tools - Maven, Gradle, Ant & mehr 4
A Applet Applet startet nach Einbinden auf Website nicht Tools - Maven, Gradle, Ant & mehr 4
A Applet, xxx.jar und hsqldb Tools - Maven, Gradle, Ant & mehr 4
T Webstart oder Applet Tools - Maven, Gradle, Ant & mehr 2
H Applet applet neu laden im browser Tools - Maven, Gradle, Ant & mehr 10
M Applet neustart Tools - Maven, Gradle, Ant & mehr 5
S Applet request unter Linux Tools - Maven, Gradle, Ant & mehr 14
S Applet GUI nicht im Webbrowser sichtbar Tools - Maven, Gradle, Ant & mehr 5
S Mittel Applet Datei an ein Webserver übertragen Tools - Maven, Gradle, Ant & mehr 2
M Applet in ClientServer J2EE Anwendung debugen Tools - Maven, Gradle, Ant & mehr 6
H Java Applet Problem beim einbinden in HTML Tools - Maven, Gradle, Ant & mehr 3
M Java3D Applet flackert wenn ein Button(HTML) gedrückt wird Tools - Maven, Gradle, Ant & mehr 11
S Policy mit Signiertem Applet verteilen Tools - Maven, Gradle, Ant & mehr 9
F Applet findet include nicht Tools - Maven, Gradle, Ant & mehr 15
L PHP + Java Applet Kommunikation Tools - Maven, Gradle, Ant & mehr 9
C Probleme mit Applet mit SQL im Browser Tools - Maven, Gradle, Ant & mehr 4
G Java-Applet Probleme beim Browser Tools - Maven, Gradle, Ant & mehr 14
G Textfile in Applet laden möglich? Tools - Maven, Gradle, Ant & mehr 2
A Java-Applet Sandbox deaktiviren? Tools - Maven, Gradle, Ant & mehr 2
B Java-Applet geht nicht (auf dem Webserver) Tools - Maven, Gradle, Ant & mehr 9
P Applet läuft nicht in Browser Tools - Maven, Gradle, Ant & mehr 21
V JAR-Datei eines (J)Applet funktioniert nicht - Help! Tools - Maven, Gradle, Ant & mehr 19
S Java Applet per Klick starten? Tools - Maven, Gradle, Ant & mehr 6
S Applet geht nicht Tools - Maven, Gradle, Ant & mehr 25
J Applet signieren Tools - Maven, Gradle, Ant & mehr 2
H Applet - Geschicklichkeitsspiel programmieren Tools - Maven, Gradle, Ant & mehr 16
U Jar funktioniert nicht als Applet Tools - Maven, Gradle, Ant & mehr 3
C Applet Frage Tools - Maven, Gradle, Ant & mehr 4
M Java Applet - enforce use of older JRE Tools - Maven, Gradle, Ant & mehr 3
N Wie Java-Programm zu Applet machen?! Tools - Maven, Gradle, Ant & mehr 2
W Webseite aus Applet öffnen Tools - Maven, Gradle, Ant & mehr 3
lumo Applet - resize Tools - Maven, Gradle, Ant & mehr 7
Icewind Applet reagiert nach neu laden der Webseite nicht mehr verlässlich auf KeyEvents Tools - Maven, Gradle, Ant & mehr 6
R Applet mit MySQL Tools - Maven, Gradle, Ant & mehr 3
A jar datei trotz zertifikat nich aus applet ausführbar Tools - Maven, Gradle, Ant & mehr 4
F Fehlende Applet Rechte Tools - Maven, Gradle, Ant & mehr 12
N [Applet] Button wir nach 5 secs Unsichtbar Tools - Maven, Gradle, Ant & mehr 2
N jar -> applet wie setzt man das am leichtesten um Tools - Maven, Gradle, Ant & mehr 7
V applet Java 1.6 -> 1.5 Problem ... wie mit Ant zu lösen? Tools - Maven, Gradle, Ant & mehr 7
F applet als JAR -> AccessControlException Tools - Maven, Gradle, Ant & mehr 3
grudge File in Applet laden Tools - Maven, Gradle, Ant & mehr 4
E Java Applet - Double Buffering Problem (Flackern) Tools - Maven, Gradle, Ant & mehr 6
R Applet mit bestimmter JRE ausführen Tools - Maven, Gradle, Ant & mehr 9
traysa Wie binde ich ein applet in eine jsp Tools - Maven, Gradle, Ant & mehr 3
D Mit dem Applet das DOM manipulieren? Tools - Maven, Gradle, Ant & mehr 3
ABstraCT Applet getCodeBase() Zugriff auf darüberliegendenden Ordner ? Tools - Maven, Gradle, Ant & mehr 1
S Java-Applet Steuerung IO Karte am Drucker-Port Tools - Maven, Gradle, Ant & mehr 4
P URL aus Applet öffnen? Tools - Maven, Gradle, Ant & mehr 7
ABstraCT Mit Applet in ne Datei auf seinem Server schreiben. Tools - Maven, Gradle, Ant & mehr 10
E Verzögerung beim Refresh (F5) mit einem Applet verursachen Tools - Maven, Gradle, Ant & mehr 16
deetee Applet Frage Tools - Maven, Gradle, Ant & mehr 2

Ähnliche Java Themen

Neue Themen


Oben