Update Info

This commit is contained in:
bigJIU 2023-03-07 19:33:30 +08:00
parent a9341aa158
commit 257936c3c2
5 changed files with 11 additions and 15 deletions

Binary file not shown.

File diff suppressed because one or more lines are too long

View File

@ -26,8 +26,8 @@ public class Play {
//FIXME: Debug Use
//playGameMain("lvl1");
//playJavaGame();
initialGame();
playJavaGame();
System.out.println("Java: Play Java Main Function Done");
}
public static boolean initialGame(){
@ -37,7 +37,7 @@ public class Play {
}
public static byte[] playJavaGame(){
MarioGame game = new MarioGame();
game.setLives(3);
String levelPath = "./levels/group0/lvl1.lvl"; // For local
String repPath = "./reps/f_l_sav.rep"; // For local

View File

@ -78,7 +78,7 @@ public class MarioRender extends JComponent implements FocusListener {
}
if (!renderOcuppied){
//System.out.println(renderBuffer);
if(world.deathBuffer > 999){
if(world.deathBuffer > 49){
renderBuffer = 100;
}
if(renderBuffer>0){
@ -90,10 +90,6 @@ public class MarioRender extends JComponent implements FocusListener {
renderBuffer--;
}
}
if (scale > 1) {

View File

@ -43,8 +43,8 @@ public class Assets {
private static Image getImage(GraphicsConfiguration gc, String imageName) throws IOException {
//FIXME: web/local
//File file = new File(System.getProperty("user.dir") + "/img/" + imageName); // Local test
File file = new File("/app/img/" + imageName); // For web
File file = new File(System.getProperty("user.dir") + "/img/" + imageName); // Local test
//File file = new File("/app/img/" + imageName); // For web
BufferedImage source = ImageIO.read(file);
Image image = gc.createCompatibleImage(source.getWidth(), source.getHeight(), Transparency.BITMASK);
Graphics2D g = (Graphics2D) image.getGraphics();