egal.. html is richtig xd findet wer den fehler im php part? lg
lol man kann keinen html Code einfügen .-.
wie willst du ein bild das du eingebunden hast ne andere farbe geben.. hä??
Emo und schwarzer Nagellack <- 👌
Also ich habe einen Charakter und der läuft. Und ich möchte dass wenn der Typ nach rechts läuft, das Bild eben sozusagen nach links mitläuft. Und wenn es zu Ende ist es wiederholt gezeichnet wird sodass es sozusagen endlos geht.. hoffe das war verständlicher..
LG ^^
Der Code nochmal:
https://pastebin.com/7WzGHSJH
In eclipse startet alles perfekt (schon mit Applet und japplet probiert)
lg
Das hier ist die Hauptklasse:
package Pong;
import java.awt.Color;
import java.awt.Graphics;
import java.awt.Image;
import java.awt.event.KeyEvent;
import java.awt.event.KeyListener;
import javax.swing.JApplet;
public class Tennis extends JApplet implements Runnable, KeyListener {
/**
*
*/
private static final long serialVersionUID = 1L;
double xVel, yVel, x, y;
final int WIDTH = 700, HEIGHT = 500;
Thread thread;
HumanPaddle p1;
AIPaddle p2;
Ball b1;
boolean gameStarted;
Graphics gfx;
Image img;
public void init() {
x = 350;
y = 250;
xVel = getRandomSpeed() * getRandomDirection();
yVel = getRandomSpeed() * getRandomDirection();
this.resize(WIDTH, HEIGHT);
gameStarted = false;
this.addKeyListener(this);
p1 = new HumanPaddle(1);
b1 = new Ball();
p2 = new AIPaddle(2, b1);
img = createImage(WIDTH, HEIGHT);
gfx = img.getGraphics();
thread = new Thread(this);
thread.start();
}
public double getRandomSpeed(){
return (Math.random() * 3 + 2);
}
public int getRandomDirection() {
int rand = (int) (Math.random() * 2);
if(rand ==1){
return 1;
}else{
return -1;
}
}
public void paint(Graphics g) {
gfx.setColor(Color.black);
gfx.fillRect(0, 0, WIDTH, HEIGHT);
if(b1.getX() < -10 || b1.getX() > 710){
gfx.setColor(Color.RED);
gfx.drawString("Game Over", 350, 250);
}else{
p1.draw(gfx);
b1.Draw(gfx);
p2.draw(gfx);
}
if(!gameStarted){
gfx.setColor(Color.white);
gfx.drawString("Pong V. 3", 340, 100);
gfx.drawString("Press Enter to Begin..", 310, 130);
}
//gfx.drawString("Score: " + counter, 10, 20);
g.drawImage(img, 0, 0, this);
}
public void update(Graphics g) {
paint(g);
}
public void run() {
for (;;) {
if(gameStarted){
p1.move();
b1.move();
p2.move();
b1.checkPaddleCollision(p1, p2);
}
repaint();
try {
Thread.sleep(10);
} catch (InterruptedException e) {
e.printStackTrace();
}
}
}
@Override
public void keyPressed(KeyEvent e) {
if (e.getKeyCode() == KeyEvent.VK_UP) {
p1.setUpAccel(true);
} else if (e.getKeyCode() == KeyEvent.VK_DOWN) {
p1.setDownAccel(true);
}else if(e.getKeyCode() == KeyEvent.VK_ENTER){
gameStarted = true;
}
}
@Override
public void keyReleased(KeyEvent e) {
if (e.getKeyCode() == KeyEvent.VK_UP) {
p1.setUpAccel(false);
} else if (e.getKeyCode() == KeyEvent.VK_DOWN) {
p1.setDownAccel(false);
}
}
@Override
public void keyTyped(KeyEvent e) {
}
}
Sie sind noch nicht richtig kaufbar. Aber Google arbeitet im Moment daran. Ich denke es wird das können was die Brille auch kann. Google Maps bildlich mit Pfeilen dargestellt in welche Richtung du laufen musst usw. Allerdings wäre ich mit den ersten Versionen vorsichtig. Werden sehr teuer werden und noch nicht perfekt funktionieren.... E-Mails usw wirst du darauf auch lesen können.. eine antwortfunktion wirst du aber sicher nicht bekommen höchstens sprachgesteuert mit einem extra Tool.
Ich kann Plugins machen.
Add Skype: derdeederdee
Log Fehler:
[12:28:13 ERROR]: [PermissionsEx]
========== UNABLE TO LOAD PERMISSIONS BACKEND =========
Your configuration must be fixed before PEX will enable
Details: Error loading permissions file!
=======================================================
ru.tehkode.permissions.exceptions.PermissionBackendException: Error loading permissions file!
at ru.tehkode.permissions.backends.file.FileBackend.reload(FileBackend.java:321) ~[PermissionsEx.jar:?]
at ru.tehkode.permissions.backends.file.FileBackend.(FileBackend.java:120) ~[PermissionsEx.jar:?]
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) ~[?:1.7.0_111]
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) ~[?:1.7.0_111]
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) ~[?:1.7.0_111]
at java.lang.reflect.Constructor.newInstance(Constructor.java:526) ~[?:1.7.0_111]
at ru.tehkode.permissions.backends.PermissionBackend.getBackend(PermissionBackend.java:392) ~[PermissionsEx.jar:?]
at ru.tehkode.permissions.backends.PermissionBackend.getBackend(PermissionBackend.java:367) ~[PermissionsEx.jar:?]
at ru.tehkode.permissions.PermissionManager.createBackend(PermissionManager.java:624) ~[PermissionsEx.jar:?]
at ru.tehkode.permissions.PermissionManager.setBackend(PermissionManager.java:606) ~[PermissionsEx.jar:?]
at ru.tehkode.permissions.PermissionManager.initBackend(PermissionManager.java:693) ~[PermissionsEx.jar:?]
at ru.tehkode.permissions.PermissionManager.(PermissionManager.java:67) ~[PermissionsEx.jar:?]
at ru.tehkode.permissions.bukkit.PermissionsEx.onEnable(PermissionsEx.java:164) [PermissionsEx.jar:?]
at org.bukkit.plugin.java.JavaPlugin.setEnabled(JavaPlugin.java:321) [spigot.jar:git-Spigot-db6de12-18fbb24]
at org.bukkit.plugin.java.JavaPluginLoader.enablePlugin(JavaPluginLoader.java:340) [spigot.jar:git-Spigot-db6de12-18fbb24]
at org.bukkit.plugin.SimplePluginManager.enablePlugin(SimplePluginManager.java:405) [spigot.jar:git-Spigot-db6de12-18fbb24]
at org.bukkit.craftbukkit.v1_8_R3.CraftServer.loadPlugin(CraftServer.java:357) [spigot.jar:git-Spigot-db6de12-18fbb24]
at org.bukkit.craftbukkit.v1_8_R3.CraftServer.enablePlugins(CraftServer.java:317) [spigot.jar:git-Spigot-db6de12-18fbb24]
at org.bukkit.craftbukkit.v1_8_R3.CraftServer.reload(CraftServer.java:741) [spigot.jar:git-Spigot-db6de12-18fbb24]
at org.bukkit.Bukkit.reload(Bukkit.java:535) [spigot.jar:git-Spigot-db6de12-18fbb24]
at org.bukkit.command.defaults.ReloadCommand.execute(ReloadCommand.java:25) [spigot.jar:git-Spigot-db6de12-18fbb24]
at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:141) [spigot.jar:git-Spigot-db6de12-18fbb24]
at org.bukkit.craftbukkit.v1_8_R3.CraftServer.dispatchCommand(CraftServer.java:641) [spigot.jar:git-Spigot-db6de12-18fbb24]
at net.minecraft.server.v1_8_R3.PlayerConnection.handleCommand(PlayerConnection.java:1162) [spigot.jar:git-Spigot-db6de12-18fbb24]
at net.minecraft.server.v1_8_R3.PlayerConnection.a(PlayerConnection.java:997) [spigot.jar:git-Spigot-db6de12-18fbb24]
at net.minecraft.server.v1_8_R3.PacketPlayInChat.a(PacketPlayInChat.java:45) [spigot.jar:git-Spigot-db6de12-18fbb24]
at net.minecraft.server.v1_8_R3.PacketPlayInChat.a(PacketPlayInChat.java:1) [spigot.jar:git-Spigot-db6de12-18fbb24]
at net.minecraft.server.v1_8_R3.PlayerConnectionUtils$1.run(SourceFile:13) [spigot.jar:git-Spigot-db6de12-18fbb24]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) [?:1.7.0_111]
at java.util.concurrent.FutureTask.run(FutureTask.java:262) [?:1.7.0_111]
at net.minecraft.server.v1_8_R3.SystemUtils.a(SourceFile:44) [spigot.jar:git-Spigot-db6de12-18fbb24]
at net.minecraft.server.v1_8_R3.MinecraftServer.B(MinecraftServer.java:715) [spigot.jar:git-Spigot-db6de12-18fbb24]
at net.minecraft.server.v1_8_R3.DedicatedServer.B(DedicatedServer.java:374) [spigot.jar:git-Spigot-db6de12-18fbb24]
at net.minecraft.server.v1_8_R3.MinecraftServer.A(MinecraftServer.java:654) [spigot.jar:git-Spigot-db6de12-18fbb24]
at net.minecraft.server.v1_8_R3.MinecraftServer.run(MinecraftServer.java:557) [spigot.jar:git-Spigot-db6de12-18fbb24]
at java.lang.Thread.run(Thread.java:745) [?:1.7.0_111]
Caused by: org.bukkit.configuration.InvalidConfigurationException: while parsing a block mapping
in 'string', line 2, column 3:
default:
^
expected , but found BlockMappingStart
in 'string', line 147, column 4:
Emerald:
^
at org.bukkit.configuration.file.YamlConfiguration.loadFromString(YamlConfiguration.java:57) ~[spigot.jar:git-Spigot-db6de12-18fbb24]
at ru.tehkode.permissions.backends.file.FileConfig.loadFromString(FileConfig.java:68) ~[PermissionsEx.jar:?]
at org.bukkit.configuration.file.FileConfiguration.load(FileConfiguration.java:226) ~[spigot.jar:git-Spigot-db6de12-18fbb24]
at org.bukkit.configuration.file.FileConfiguration.load(FileConfiguration.java:169) ~[spigot.jar:git-Spigot-db6de12-18fbb24]
at ru.tehkode.permissions.backends.file.FileConfig.load(FileConfig.java:38) ~[PermissionsEx.jar:?]
at ru.tehkode.permissions.backends.file.FileBackend.reload(FileBackend.java:309) ~[PermissionsEx.jar:?]
... 35 more
Caused by: org.yaml.snakeyaml.parser.ParserException: while parsing a block mapping
in 'string', line 2, column 3:
default:
^
expected , but found BlockMappingStart
in 'string', line 147, column 4:
Emerald:
^
at org.yaml.snakeyaml.parser.ParserImpl$ParseBlockMappingKey.produce(ParserImpl.java:570) ~[spigot.jar:git-Spigot-db6de12-18fbb24]
at org.yaml.snakeyaml.parser.ParserImpl.peekEvent(ParserImpl.java:158) ~[spigot.jar:git-Spigot-db6de12-18fbb24]
at org.yaml.snakeyaml.parser.ParserImpl.checkEvent(ParserImpl.java:143) ~[spigot.jar:git-Spigot-db6de12-18fbb24]
at org.yaml.snakeyaml.composer.Composer.composeMappingNode(Composer.java:224) ~[spigot.jar:git-Spigot-db6de12-18fbb24]
at org.yaml.snakeyaml.composer.Composer.composeNode(Composer.java:155) ~[spigot.jar:git-Spigot-db6de12-18fbb24]
at org.yaml.snakeyaml.composer.Composer.composeMappingNode(Composer.java:229) ~[spigot.jar:git-Spigot-db6de12-18fbb24]
at org.yaml.snakeyaml.composer.Composer.composeNode(Composer.java:155) ~[spigot.jar:git-Spigot-db6de12-18fbb24]
at org.yaml.snakeyaml.composer.Composer.composeDocument(Composer.java:122) ~[spigot.jar:git-Spigot-db6de12-18fbb24]
at org.yaml.snakeyaml.composer.Composer.getSingleNode(Composer.java:105) ~[spigot.jar:git-Spigot-db6de12-18fbb24]
at org.yaml.snakeyaml.constructor.BaseConstructor.getSingleData(BaseConstructor.java:120) ~[spigot.jar:git-Spigot-db6de12-18fbb24]
at org.yaml.snakeyaml.Yaml.loadFromReader(Yaml.java:450) ~[spigot.jar:git-Spigot-db6de12-18fbb24]
at org.yaml.snakeyaml.Yaml.load(Yaml.java:369) ~[spigot.jar:git-Spigot-db6de12-18fbb24]
at org.bukkit.configuration.file.YamlConfiguration.loadFromString(YamlConfiguration.java:55) ~[spigot.jar:git-Spigot-db6de12-18fbb24]
at ru.tehkode.permissions.backends.file.FileConfig.loadFromString(FileConfig.java:68) ~[PermissionsEx.jar:?]
at org.bukkit.configuration.file.FileConfiguration.load(FileConfiguration.java:226) ~[spigot.jar:git-Spigot-db6de12-18fbb24]
at org.bukkit.configuration.file.FileConfiguration.load(FileConfiguration.java:169) ~[spigot.jar:git-Spigot-db6de12-18fbb24]
at ru.tehkode.permissions.backends.file.FileConfig.load(FileConfig.java:38) ~[PermissionsEx.jar:?]
at ru.tehkode.permissions.backends.file.FileBackend.reload(FileBackend.java:309) ~[PermissionsEx.jar:?]
... 35 more
groups:
default:
prefix: '&8||&bStone&8||'
default: true
permissions:
- chestcommands.open.example.yml
- chestcommands.open.settings.yml
- chestcommands.open.mobshophead.yml
- chestcommands.open.arrowshop.yml
- chestcommands.open.mobh.yml
- chestcommands.open.cabezas.yml
- chestcommands.open.lobbies.yml
- chestcommands.open.vanity.yml
- chestcommands.open.shop-ng.yml
- chestcommands.open.challenge.yml
- myhub.use
- essentials.balance
- lobby.use
options:
build: true
rank: '200'
Premium:
prefix: '&a&k||&7Premium&a&k||&c'
inheritance:
- default
permissions:
- essentials.chat.color
- chestcommands.open.example.yml
- chestcommands.open.settings.yml
- chestcommands.open.mobshophead.yml
- chestcommands.open.arrowshop.yml
- chestcommands.open.mobh.yml
- chestcommands.open.cabezas.yml
- chestcommands.open.lobbies.yml
- chestcommands.open.vanity.yml
- chestcommands.open.shop-ng.yml
- chestcommands.open.challenge.yml
- essentials.balance
- lobby.use
- myhub.use
- my.head.chicken
- my.head.wolf
- my.head.pigzombie
- my.head.spider
- my.head.cavespider
- my.head.enderman
- my.head.ghast
- my.head.blaze
- my.head.slime
- my.head.magmaslime
- my.head.witherboss
- my.head.irongolem
- my.head.villager
- my.head.cow
- my.head.mushroomcow
- my.head.sheep
- my.head.squid
- my.head.pig
- my.head.ocelot
- discoarmor.toggle
- lobby.rank.premium
options:
rank: '600'
Premium+:
prefix: '&6&k||&1Premium+&6&k||&e'
inheritance:
- default
permissions:
- essentials.chat.color
- chestcommands.open.example.yml
- chestcommands.open.settings.yml
- chestcommands.open.mobshophead.yml
- chestcommands.open.arrowshop.yml
- chestcommands.open.mobh.yml
- chestcommands.open.cabezas.yml
- chestcommands.open.lobbies.yml
- chestcommands.open.vanity.yml
- chestcommands.open.shop-ng.yml
- chestcommands.open.challenge.yml
- essentials.balance
- lobby.use
- myhub.use
- my.head.chicken
- my.head.wolf
- my.head.pigzombie
- my.head.spider
- my.head.cavespider
- my.head.enderman
- my.head.ghast
- my.head.blaze
- my.head.slime
- my.head.magmaslime
- my.head.witherboss
- my.head.irongolem
- my.head.villager
- my.head.cow
- my.head.mushroomcow
- my.head.sheep
- my.head.squid
- my.head.pig
- my.head.ocelot
- discoarmor.toggle
options:
rank: '600'
Gold:
prefix: '&9&k||&eGold&9&k||&6'
inheritance:
- default
permissions:
- essentials.chat.color
- chestcommands.open.example.yml
- chestcommands.open.settings.yml
- chestcommands.open.mobshophead.yml
- chestcommands.open.arrowshop.yml
- chestcommands.open.mobh.yml
- chestcommands.open.cabezas.yml
- chestcommands.open.lobbies.yml
- chestcommands.open.vanity.yml
- chestcommands.open.shop-ng.yml
- chestcommands.open.challenge.yml
- essentials.balance
- lobby.use
- myhub.use
- discoarmor.toggle
- my.head.chicken
- my.head.wolf
- my.head.pigzombie
- my.head.spider
- my.head.cavespider
- my.head.enderman
- my.head.ghast
- my.head.blaze
- my.head.slime
- my.head.magmaslime
- my.head.witherboss
- my.head.irongolem
- my.head.villager
- my.head.cow
- my.head.mushroomcow
- my.head.sheep
- lobby.rank.premium
- my.head.squid
- my.head.pig
- my.head.ocelot
options:
rank: '600'
Emerald:
prefix: '&2&k||&aEmerald&2&k||&6'
inheritance:
- default
permissions:
- essentials.chat.color
- chestcommands.open.example.yml
- chestcommands.open.settings.yml
- chestcommands.open.mobshophead.yml
- chestcommands.open.arrowshop.yml
- chestcommands.open.mobh.yml
- lobby.rank.premium
- chestcommands.open.cabezas.yml
- chestcommands.open.lobbies.yml
- chestcommands.open.vanity.yml
- chestcommands.open.shop-ng.yml
- chestcommands.open.challenge.yml
- essentials.balance
- lobby.use
- myhub.use
- discoarmor.toggle
- my.head.chicken
- my.head.wolf
- my.head.pigzombie
- my.head.spider
- my.head.cavespider
- my.head.enderman
- my.head.ghast
- my.head.blaze
- my.head.slime
- my.head.magmaslime
- my.head.witherboss
- my.head.irongolem
- my.head.villager
- my.head.cow
- my.head.mushroomcow
- my.head.sheep
- my.head.squid
- my.head.pig
- my.head.ocelot
options:
rank: '600'
Youtuber:
prefix: '&0&k||&c&lYou&f&lTuber&0&k||&c'
inheritance:
- default
permissions:
- essentials.chat.color
- essentials.fly
- chestcommands.open.example.yml
- lobby.rank.premium
- chestcommands.open.settings.yml
- chestcommands.open.mobshophead.yml
- chestcommands.open.arrowshop.yml
- chestcommands.open.mobh.yml
- chestcommands.open.cabezas.yml
- chestcommands.open.lobbies.yml
- chestcommands.open.vanity.yml
- chestcommands.open.shop-ng.yml
- chestcommands.open.challenge.yml
- essentials.balance
- lobby.use
- myhub.use
- discoarmor.toggle
- my.head.chicken
- my.head.wolf
- my.head.pigzombie
- my.head.spider
- my.head.cavespider
- my.head.enderman
- my.head.ghast
- my.head.blaze
- my.head.slime
- my.head.magmaslime
- my.head.witherboss
- my.head.irongolem
- my.head.villager
- my.head.cow
- my.head.mushroomcow
- my.head.sheep
- my.head.squid
- my.head.pig
- my.head.ocelot
options:
rank: '600'
Obsidian:
prefix: '&c&k||&5Obsidian&c&k||&3'
inheritance:
- default
permissions:
- lobby.rank.premium
- essentials.chat.color
- essentials.fly
- chestcommands.open.example.yml
- chestcommands.open.settings.yml
- chestcommands.open.mobshophead.yml
- chestcommands.open.arrowshop.yml
- chestcommands.open.mobh.yml
- chestcommands.open.cabezas.yml
- chestcommands.open.lobbies.yml
- chestcommands.open.vanity.yml
- chestcommands.open.shop-ng.yml
- chestcommands.open.challenge.yml
- essentials.balance
- lobby.use
- myhub.use
- discoarmor.toggle
- my.head.chicken
- my.head.wolf
- my.head.pigzombie
- my.head.spider
- my.head.cavespider
- my.head.enderman
- my.head.ghast
- my.head.blaze
- my.head.slime
- my.head.magmaslime
- my.head.witherboss
- my.head.irongolem
- my.head.villager
- my.head.cow
- my.head.mushroomcow
- my.head.sheep
- my.head.squid
- my.head.pig
- my.head.ocelot
options:
rank: '600'
Owner:
permissions:
- '*'
- lobby.rank.owner
prefix: '&c&k||&5Owner&c&k||&3'
users:
TeamAnym:
group:
- Owner
worlds:
all:
group:
- Owner
MenoxHD:
group:
- Builder
worlds:
all:
group:
- Builder
_DarkJojo_:
group:
- Stone
_DarkChrissi_:
group:
- Stone
Yannick_456:
group:
- Obsidian