bevilacqua / rajola Goto Github PK
View Code? Open in Web Editor NEWA Slick2D Tiling Pipeline with camera assistance
A Slick2D Tiling Pipeline with camera assistance
The mapcolor i defined for tiles in the example do not correspond to the colors that appear.
Example:
Hex value should be: 0xff0000
Value the program reads from file: -65536
Hardcoded value for value:
animatedTile = new BasicTile(0 , animatedSprite , -65536); //Red (#FF0000)
TileLevel renders all tiles even those not on the screen
In TileLevel tiles with multiple frames stay in the first frame with no way to update.
I have been working on this for a while now and i can see whats wrong. The method is attempting to access pixels outside of the image. I was hoping you could take a look at it when you get the chance. You can use the test i added to the repository to help you debug it.
Thank You!
While the color bug is finally fixed and the TileLevel class technically works it allows for no flexibility because the Image must be 256 X 256. I am not sure why this is because the class takes the width and height directly from the image:
Seen here[TileLevel.java | line# 57-61]
try {
this.mapImage = ImageTools.toSlickImage(ImageIO.read(new File(path)));
this.width = this.mapImage.getWidth();
this.height = this.mapImage.getHeight();
tiles = new int[width * height];
I am not sure why this is occurring if you have a chance please take a look, if not i should be able to put some more time into it a little bit later.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.