Eufloria > Eufloria HD Mods
Map Editor HELP
(1/1)
Aino:
Since there has been so much asking for a map editor, I'm going to make one. I just need help with one thing:
How do you calculate the positions in the game? This meaning how do you calculate the mouse position and make the entities rendered orient themselves around the middle of your screen?
I've been trying around for 4 hours. I wanted to keep it secret, but it's inevitable :/
Solved(this is java codes!):
--- Code: ---public int findX(float x) {
return (int) (x * mng.camera.zoom - mng.camera.x * mng.camera.zoom + mng.frameObj.getWidth()/2);
}
public int findY(float y) {
return (int) (y * mng.camera.zoom - mng.camera.y * mng.camera.zoom + mng.frameObj.getHeight()/2);
}
public int findXR(float x) {
return (int) ((x-mng.frameObj.getWidth()/2) / mng.camera.zoom + mng.camera.x);
}
public int findYR(float y) {
return (int) ((y-mng.frameObj.getHeight()/2) / mng.camera.zoom + mng.camera.y);
}
--- End code ---
sillytuna:
Is this for HD?
If so, pm me your best email (if not the one used to register here) and I'll answer anything you want to know and keep you informed of plans.
Breakord:
--- Quote from: Aino on November 25, 2012, 11:50:47 AM ---Since there has been so much asking for a map editor, I'm going to make one. I just need help with one thing:
How do you calculate the positions in the game? This meaning how do you calculate the mouse position and make the entities rendered orient themselves around the middle of your screen?
I've been trying around for 4 hours. I wanted to keep it secret, but it's inevitable :/
--- End quote ---
well,there truely exist some editors for classic mod ,not work very well though...
Timeroute:
So is this going to be a standalone map editor application, or another Lua "level" that you load that lets you load and edit other maps?
Aino:
--- Quote from: Timeroute on November 26, 2012, 05:14:37 AM ---So is this going to be a standalone map editor application, or another Lua "level" that you load that lets you load and edit other maps?
--- End quote ---
This is going to be a standalone Java application which you can run from a .jar file. This should also make it compatible with all operating systems(unless you're running a very special one).
Navigation
[0] Message Index
Go to full version