Java proxy and client 16.2
I don't think he actually changed anything about the code other than make the main loop unreadable and creating a basic spam filter in the proxy. It's actually missing a lot of current stuff.
Also, @krazyshank was updating the wrong code the other night, which would explain why it was such a bear to even get remotely close to working. It was confusing the hell out of me why there was some stuff that just didn't look right, as it was really old. Time well spent...
Also, @krazyshank was updating the wrong code the other night, which would explain why it was such a bear to even get remotely close to working. It was confusing the hell out of me why there was some stuff that just didn't look right, as it was really old. Time well spent...

watch the youtube video, its all java code controing the wizards in the realm i could have 50 bots following me
the code is all still there is just commented out, or disabled, you have to work out how to enable it
the ikulip's source code, wasn’t capable of entering any realm, I did that my self
the code is all still there is just commented out, or disabled, you have to work out how to enable it
the ikulip's source code, wasn’t capable of entering any realm, I did that my self
Strange. I updated Ikulip's myself and it handled realm reconnects fine. It also came with multiboxlistener which allowed bots to follow me around (which detected realm changes and followed appropriately).
Just took a look at that video of yours. That is pretty cool how you have the bots following, in a formation of sorts. They seem to be firing also which cool. Do they auto aim or just aim at the direction your leader fires at?
Just took a look at that video of yours. That is pretty cool how you have the bots following, in a formation of sorts. They seem to be firing also which cool. Do they auto aim or just aim at the direction your leader fires at?
Taken from his source (check BasicListener), they check the ALLYSHOOT packet and check to see if the owner is him (seemingly "SomeFrog" or "Dbsdbajdbj"), and if so, fire at the same angle he was firing at. Looking at the code, it seems as if that only works for Wizard's starting gear or only if both leader and followers have the same weapon, of which shoots two shots (Staff, dblade, coral bow), as he has that hard coded in. Same for the ability usage, that's hard coded in as the Wizard starting spell and seems to use it where they are standing (they being the connected bot).
Not sure where the movement code is where they move in a circle around him, but it's kinda cool.
I'm not sure how hit detection is working either, although looking at the code, it seems as if the server will decide if you hit from you sending the SHOOTACK packet, leaving us with less work. That's just an assumption though, if @Botmaker would elaborate, that would be helpful.
I'm just being honest with the things that I say though, @Botmaker, I have looked at furymaker's source and all of the other sources that have been posted and I don't see many differences, aside from what I pointed out here. If you'd elaborate on the things that you changed other than repeating "look at the youtube video", that would be helpful. It's a big project, you can't expect people to know exactly what you've changed underneath it all.
Not sure where the movement code is where they move in a circle around him, but it's kinda cool.
I'm not sure how hit detection is working either, although looking at the code, it seems as if the server will decide if you hit from you sending the SHOOTACK packet, leaving us with less work. That's just an assumption though, if @Botmaker would elaborate, that would be helpful.
I'm just being honest with the things that I say though, @Botmaker, I have looked at furymaker's source and all of the other sources that have been posted and I don't see many differences, aside from what I pointed out here. If you'd elaborate on the things that you changed other than repeating "look at the youtube video", that would be helpful. It's a big project, you can't expect people to know exactly what you've changed underneath it all.
my first ever thread, never work on rotmg packets and it's system before then
http://www.mpgh.net/forum/731-realm-...er-please.html
http://www.mpgh.net/forum/731-realm-...rsion-4-a.html
http://www.mpgh.net/forum/731-realm-...er-please.html
http://www.mpgh.net/forum/731-realm-...rsion-4-a.html
you are so wrong, go get the original source code and implement everything in my youtube video, then come back and see what you have to say, instead of being a judgemental asshole.
For one almost every single one of the packet id as changed, there are 19 packets that will need updating (from 123 to 16.2), and them you will need to implement everything i have in my you tube video, none of witch was there before
Not even touching on the server that I updated with 20+ new features
What a prick
For one almost every single one of the packet id as changed, there are 19 packets that will need updating (from 123 to 16.2), and them you will need to implement everything i have in my you tube video, none of witch was there before
Not even touching on the server that I updated with 20+ new features
What a prick
Am I doing something wrong? I have everything working but this stupid MyClass thing error. "main class MyClass not found"
@Botmaker your source is missing nearly half of the statdata tags, is there a reason?
I also was updating the other one on purpose - I learned so much so i'd say time well spent.
I also was updating the other one on purpose - I learned so much so i'd say time well spent.
alright i think you might be right(it was 3-4 months ago), but dwdude is being ahole,
it took me a month to build that java server and to learn and understand rotmg packets.
Not to mention I had never program in java before then.
The bots listen for the ally shoot packet etc (spells), then check to see who the owner id is, if it matches the leader id, it takes the angle of the shot packet and use it to shot in the same direction as the leader
it took me a month to build that java server and to learn and understand rotmg packets.
Not to mention I had never program in java before then.
The bots listen for the ally shoot packet etc (spells), then check to see who the owner id is, if it matches the leader id, it takes the angle of the shot packet and use it to shot in the same direction as the leader
Oh, so you did some code in the rotmgserver area? Well, if so, I didn't even look there, so my apologies if that's the case, but even if you did, that section isn't used at all for the proxy or the client, so why does that matter?
Edit: @nilly pls halp, i cant computer, mah dubble post makes me sad
Edit: @nilly pls halp, i cant computer, mah dubble post makes me sad
@dwdude
You are right dwdude, the hit packet doesn’t work, but I already have the code to implement that now(in euphoria, i havent programmed in java for 3-4 months) , in fact am close to a release with wizards starting gear to kill enemies in the realms, I just need the correct way to calculate the dex stat and spd stat, as they level up.
You are right dwdude, the hit packet doesn’t work, but I already have the code to implement that now(in euphoria, i havent programmed in java for 3-4 months) , in fact am close to a release with wizards starting gear to kill enemies in the realms, I just need the correct way to calculate the dex stat and spd stat, as they level up.
/* jOryx - A Realm of the Mad God client.
* Copyright (C) 2011-2012 Furyhunter <furyhunter600@gmail.com>
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package com.joryx.control;
import java********Exception;
import java.util.List;
import com.jme3.audio.AudioNode;
import com.jme3.collision.CollisionResults;
import com.jme3.math.ColorRGBA;
import com.jme3.math.FastMath;
import com.jme3.math.Quaternion;
import com.jme3.math.Ray;
import com.jme3.math.Vector3f;
import com.jme3.renderer.RenderManager;
import com.jme3.renderer.ViewPort;
import com.jme3.scene.Spatial;
import com.jme3.scene.control.AbstractControl;
import com.jme3.scene.control.Control;
import com.joryx.JOryx;
import com.joryx.appstate.DatabaseState;
import com.joryx.appstate.WorldState;
import com.joryx.db.ObjectType;
import com.joryx.db.ProjectileDefinition;
import com.joryx.object.CharacterControl;
import com.joryx.object.ObjectControl;
import com.joryx.object.PlayerControl;
import com.oryxhatesjava.net.EnemyHitPacket;
import com.oryxhatesjava.net.PlayerHitPacket;
import com.oryxhatesjava.net.SquareHitPacket;
import com.oryxhatesjava.net.data.StatData;
public class ProjectileControl extends AbstractControl {
private ProjectileDefinition projectile;
private ObjectType containerType;
private Spatial owner;
private boolean ally;
private Vector3f incrementVector;
private Vector3f directionVector;
private float lifeTime;
private float life;
private float angle;
private int bulletId;
private boolean initialized;
private static boolean reverseOscillation;
private float phase;
private float frequency;
private float amplitude;
private Vector3f location;
private boolean player;
private Vector3f amplitudeVector;
public ProjectileControl(ProjectileDefinition projectile, Spatial owner, ObjectType containerType, boolean ally, int bulletId, float angle, boolean player) {
this.projectile = projectile;
this.containerType = containerType;
this.ally = ally;
this.bulletId = bulletId;
this.angle = angle;
this.player = player;
this.owner = owner;
}
@Override
public Control cloneForSpatial(Spatial spatial) {
// TODO Auto-generated method stub
return null;
}
@Override
protected void controlUpdate(float tpf) {
if (!initialized) {
incrementVector = new Vector3f(((float)projectile.speed / 10f), 0, 0);
Quaternion rot = new Quaternion();
rot.fromAngleNormalAxis(-angle, Vector3f.UNIT_Z);
incrementVector = rot.multLocal(incrementVector);
lifeTime = projectile.lifetimeSeconds;
directionVector = incrementVector.normalize();
location = spatial.getLocalTranslation().clone();
if (projectile.amplitude != 0) {
if (!reverseOscillation) {
amplitudeVector = new Vector3f(0, projectile.amplitude, 0);
amplitudeVector = rot.multLocal(amplitudeVector);
reverseOscillation = true;
} else {
amplitudeVector = new Vector3f(0, -projectile.amplitude, 0);
amplitudeVector = rot.multLocal(amplitudeVector);
reverseOscillation = false;
}
} else {
amplitudeVector = new Vector3f(0, 0, 0);
}
if (projectile.frequency != 0) {
frequency = projectile.frequency;
} else {
frequency = 1;
}
initialized = true;
}
life += tpf;
Vector3f inc = incrementVector.mult(tpf);
location.addLocal(inc);
location.subtractLocal(amplitudeVector.mult(FastMa th.sin(phase)));
phase += tpf * frequency * 10;
location.addLocal(amplitudeVector.mult(FastMath.si n(phase)));
spatial.setLocalTranslation(location);
// collisions
Ray ray = new Ray(spatial.getWorldTranslation(), directionVector);
CollisionResults cr = new CollisionResults();
List<Spatial> children = spatial.getParent().getChildren();
for (Spatial s : children) {
if (s == spatial) {
continue;
}
if (s == null) {
continue;
}
if (s == owner) {
continue;
}
if (s.getControl(NoMoveControl.class) == null && s.getControl(PlayerControl.class) == null && s.getControl(CharacterControl.class) == null) {
continue;
}
float distance = s.getLocalTranslation().distance(spatial.getLocalT ranslation());
if (distance < 0.5f) {
// collided!
CharacterControl cc = s.getControl(CharacterControl.class);
PlayerControl pc = s.getControl(PlayerControl.class);
NoMoveControl nmc = s.getControl(NoMoveControl.class);
WorldState ws = JOryx.getSingleton().getStateManager().getState(Wo rldState.class);
// ignore if it's an ally bullet hitting a player
if (ally && pc != null) {
continue;
}
// ignore if it's an enemy bullet hitting a character
if (!ally && cc != null) {
continue;
}
// hit if player and hit is CC
if (player && cc != null && cc.isEnemy()) {
int damage = calculateDamage();
EnemyHitPacket php = new EnemyHitPacket();
php.bulletId = bulletId;
php.objectId = cc.getStatus().data.objectId;
php.time = ws.getClient().getTime();
ObjectType type = DatabaseState.getSingleton().getObjectType(cc.getS tatus().objectType);
int hp = cc.getStatus().data.getStat(StatData.HP).value;
if (hp - damage <= 0) {
if (type.deathSound != null) {
AudioNode an = new AudioNode(JOryx.getSingleton().getAssetManager(), "Sounds/" + type.deathSound + ".wav");
an.play();
}
php.kill = true;
} else {
if (type.hitSound != null) {
AudioNode an = new AudioNode(JOryx.getSingleton().getAssetManager(), "Sounds/" + type.hitSound + ".wav");
an.play();
}
php.kill = false;
}
ws.makeNotification(cc.getStatus().data.objectId, "-" + damage, ColorRGBA.Red.asIntABGR());
try {
ws.getClient().sendSyncPacket(php);
} catch (IOException e) {
e.printStackTrace();
}
} else if (pc != null && pc.isPlayer()) {
// hit if unfriendly and hit local player
PlayerHitPacket ehp = new PlayerHitPacket();
ehp.bulletId = bulletId;
ehp.objectId = owner.getControl(ObjectControl.class).getStatus(). data.objectId;
ObjectType type = DatabaseState.getSingleton().getObjectType(pc.getS tatus().objectType);
AudioNode an = new AudioNode(JOryx.getSingleton().getAssetManager(), "Sounds/" + type.hitSound + ".wav");
an.play();
try {
ws.getClient().sendSyncPacket(ehp);
} catch (IOException e) {
e.printStackTrace();
}
} else if (nmc != null && player) {
// hit if square
SquareHitPacket shp = new SquareHitPacket();
shp.bulletId = bulletId;
shp.objectId = owner.getControl(ObjectControl.class).getStatus(). data.objectId;
try {
ws.getClient().sendSyncPacket(shp);
} catch (IOException e) {
e.printStackTrace();
}
}
spatial.removeFromParent();
return;
}
}
if (life > lifeTime) {
spatial.removeFromParent();
}
}
@Override
protected void controlRender(RenderManager rm, ViewPort vp) {
// TODO Auto-generated method stub
}
public int getBulletId() {
return bulletId;
}
private int calculateDamage() {
float ret = 0;
if (projectile.damage != 0) {
return projectile.damage;
}
ret = FastMath.rand.nextFloat() * (projectile.maxDamage - projectile.minDamage);
ret += projectile.minDamage;
if (player) {
ObjectControl oc = owner.getControl(ObjectControl.class);
int att = oc.getStatus().data.getStat(StatData.ATT).value + oc.getStatus().data.getStat(StatData.ATTBONUS).val ue;
float mult = 0.5f + ((float)att / 50f);
ret *= mult;
}
return Math****und(ret);
}
}
* Copyright (C) 2011-2012 Furyhunter <furyhunter600@gmail.com>
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package com.joryx.control;
import java********Exception;
import java.util.List;
import com.jme3.audio.AudioNode;
import com.jme3.collision.CollisionResults;
import com.jme3.math.ColorRGBA;
import com.jme3.math.FastMath;
import com.jme3.math.Quaternion;
import com.jme3.math.Ray;
import com.jme3.math.Vector3f;
import com.jme3.renderer.RenderManager;
import com.jme3.renderer.ViewPort;
import com.jme3.scene.Spatial;
import com.jme3.scene.control.AbstractControl;
import com.jme3.scene.control.Control;
import com.joryx.JOryx;
import com.joryx.appstate.DatabaseState;
import com.joryx.appstate.WorldState;
import com.joryx.db.ObjectType;
import com.joryx.db.ProjectileDefinition;
import com.joryx.object.CharacterControl;
import com.joryx.object.ObjectControl;
import com.joryx.object.PlayerControl;
import com.oryxhatesjava.net.EnemyHitPacket;
import com.oryxhatesjava.net.PlayerHitPacket;
import com.oryxhatesjava.net.SquareHitPacket;
import com.oryxhatesjava.net.data.StatData;
public class ProjectileControl extends AbstractControl {
private ProjectileDefinition projectile;
private ObjectType containerType;
private Spatial owner;
private boolean ally;
private Vector3f incrementVector;
private Vector3f directionVector;
private float lifeTime;
private float life;
private float angle;
private int bulletId;
private boolean initialized;
private static boolean reverseOscillation;
private float phase;
private float frequency;
private float amplitude;
private Vector3f location;
private boolean player;
private Vector3f amplitudeVector;
public ProjectileControl(ProjectileDefinition projectile, Spatial owner, ObjectType containerType, boolean ally, int bulletId, float angle, boolean player) {
this.projectile = projectile;
this.containerType = containerType;
this.ally = ally;
this.bulletId = bulletId;
this.angle = angle;
this.player = player;
this.owner = owner;
}
@Override
public Control cloneForSpatial(Spatial spatial) {
// TODO Auto-generated method stub
return null;
}
@Override
protected void controlUpdate(float tpf) {
if (!initialized) {
incrementVector = new Vector3f(((float)projectile.speed / 10f), 0, 0);
Quaternion rot = new Quaternion();
rot.fromAngleNormalAxis(-angle, Vector3f.UNIT_Z);
incrementVector = rot.multLocal(incrementVector);
lifeTime = projectile.lifetimeSeconds;
directionVector = incrementVector.normalize();
location = spatial.getLocalTranslation().clone();
if (projectile.amplitude != 0) {
if (!reverseOscillation) {
amplitudeVector = new Vector3f(0, projectile.amplitude, 0);
amplitudeVector = rot.multLocal(amplitudeVector);
reverseOscillation = true;
} else {
amplitudeVector = new Vector3f(0, -projectile.amplitude, 0);
amplitudeVector = rot.multLocal(amplitudeVector);
reverseOscillation = false;
}
} else {
amplitudeVector = new Vector3f(0, 0, 0);
}
if (projectile.frequency != 0) {
frequency = projectile.frequency;
} else {
frequency = 1;
}
initialized = true;
}
life += tpf;
Vector3f inc = incrementVector.mult(tpf);
location.addLocal(inc);
location.subtractLocal(amplitudeVector.mult(FastMa th.sin(phase)));
phase += tpf * frequency * 10;
location.addLocal(amplitudeVector.mult(FastMath.si n(phase)));
spatial.setLocalTranslation(location);
// collisions
Ray ray = new Ray(spatial.getWorldTranslation(), directionVector);
CollisionResults cr = new CollisionResults();
List<Spatial> children = spatial.getParent().getChildren();
for (Spatial s : children) {
if (s == spatial) {
continue;
}
if (s == null) {
continue;
}
if (s == owner) {
continue;
}
if (s.getControl(NoMoveControl.class) == null && s.getControl(PlayerControl.class) == null && s.getControl(CharacterControl.class) == null) {
continue;
}
float distance = s.getLocalTranslation().distance(spatial.getLocalT ranslation());
if (distance < 0.5f) {
// collided!
CharacterControl cc = s.getControl(CharacterControl.class);
PlayerControl pc = s.getControl(PlayerControl.class);
NoMoveControl nmc = s.getControl(NoMoveControl.class);
WorldState ws = JOryx.getSingleton().getStateManager().getState(Wo rldState.class);
// ignore if it's an ally bullet hitting a player
if (ally && pc != null) {
continue;
}
// ignore if it's an enemy bullet hitting a character
if (!ally && cc != null) {
continue;
}
// hit if player and hit is CC
if (player && cc != null && cc.isEnemy()) {
int damage = calculateDamage();
EnemyHitPacket php = new EnemyHitPacket();
php.bulletId = bulletId;
php.objectId = cc.getStatus().data.objectId;
php.time = ws.getClient().getTime();
ObjectType type = DatabaseState.getSingleton().getObjectType(cc.getS tatus().objectType);
int hp = cc.getStatus().data.getStat(StatData.HP).value;
if (hp - damage <= 0) {
if (type.deathSound != null) {
AudioNode an = new AudioNode(JOryx.getSingleton().getAssetManager(), "Sounds/" + type.deathSound + ".wav");
an.play();
}
php.kill = true;
} else {
if (type.hitSound != null) {
AudioNode an = new AudioNode(JOryx.getSingleton().getAssetManager(), "Sounds/" + type.hitSound + ".wav");
an.play();
}
php.kill = false;
}
ws.makeNotification(cc.getStatus().data.objectId, "-" + damage, ColorRGBA.Red.asIntABGR());
try {
ws.getClient().sendSyncPacket(php);
} catch (IOException e) {
e.printStackTrace();
}
} else if (pc != null && pc.isPlayer()) {
// hit if unfriendly and hit local player
PlayerHitPacket ehp = new PlayerHitPacket();
ehp.bulletId = bulletId;
ehp.objectId = owner.getControl(ObjectControl.class).getStatus(). data.objectId;
ObjectType type = DatabaseState.getSingleton().getObjectType(pc.getS tatus().objectType);
AudioNode an = new AudioNode(JOryx.getSingleton().getAssetManager(), "Sounds/" + type.hitSound + ".wav");
an.play();
try {
ws.getClient().sendSyncPacket(ehp);
} catch (IOException e) {
e.printStackTrace();
}
} else if (nmc != null && player) {
// hit if square
SquareHitPacket shp = new SquareHitPacket();
shp.bulletId = bulletId;
shp.objectId = owner.getControl(ObjectControl.class).getStatus(). data.objectId;
try {
ws.getClient().sendSyncPacket(shp);
} catch (IOException e) {
e.printStackTrace();
}
}
spatial.removeFromParent();
return;
}
}
if (life > lifeTime) {
spatial.removeFromParent();
}
}
@Override
protected void controlRender(RenderManager rm, ViewPort vp) {
// TODO Auto-generated method stub
}
public int getBulletId() {
return bulletId;
}
private int calculateDamage() {
float ret = 0;
if (projectile.damage != 0) {
return projectile.damage;
}
ret = FastMath.rand.nextFloat() * (projectile.maxDamage - projectile.minDamage);
ret += projectile.minDamage;
if (player) {
ObjectControl oc = owner.getControl(ObjectControl.class);
int att = oc.getStatus().data.getStat(StatData.ATT).value + oc.getStatus().data.getStat(StatData.ATTBONUS).val ue;
float mult = 0.5f + ((float)att / 50f);
ret *= mult;
}
return Math****und(ret);
}
}
That information is sent to you all the time, it's one of the statdatas. Every time a person loads into the nexus, that information is sent to you. Their name, fame, inventory, stats, pet information, you name it. It is sent to you the same way when you level. It's been a while since I've done anything specific, but I believe it is sent in UPDATE packets, but it could be NEW_TICK.
I do hope that your audio clip is for testing only, that would be incredibly annoying with 4+ bots at once :P
Lol dude, that was 5 months ago in a section I never frequent and you didn't say anything in any of your OP about it and you expect me to just know. I'm sorry I don't study all of your posts, including old ones, you aren't my idol or something haha.
I do hope that your audio clip is for testing only, that would be incredibly annoying with 4+ bots at once :P
Lol dude, that was 5 months ago in a section I never frequent and you didn't say anything in any of your OP about it and you expect me to just know. I'm sorry I don't study all of your posts, including old ones, you aren't my idol or something haha.
This thread is closed for replies.
Similar Threads
Spammers CornerProxies And Wordlists
13 Realm of the Mad God Hacks & Cheats[RELEASE][SRC] Java ROTMG classes for Server, Client, Proxy and BaseIK 59 CrossFire HelpMy proxy and ************...DO 2 General HackingPokemon Cyrus (Open Source Server and Client) But Need Encryption Lock HelpVA 0 Trade Accounts/Keys/Items{Selling}RS Working Pass Cracker+Site to get all the proxys and read etc... 19


