This site requires JavaScript, please enable it in your browser!
Greenfoot back
matttic97
matttic97 wrote ...

2016/1/5

Exporting to .jar problems

1
2
matttic97 matttic97

2016/1/5

#
Hi I have a problem with exporting. On tutorial it says that you need to copy some .dll files in scenario folder but in my scenario folder doesn't contain any of those files. It only contains folders(doc,images,sound) and class files. When I launch the .jar file, only the stop,run and refresh buttons appear.Pleas help..
matttic97 matttic97

2016/1/6

#
anyone?
danpost danpost

2016/1/6

#
matttic97 wrote...
anyone?
It would help if you provided a link to the tutorial referenced.
matttic97 matttic97

2016/1/6

#
it's this one on greenfoot site: http://www.greenfoot.org/doc/gamepad_export
danpost danpost

2016/1/6

#
First, did you download then GamePad Template zip folder? The files included need to be extracted and a copy of them needs to be included in any project folder you wish to program the use of a game pad in.
matttic97 matttic97

2016/1/6

#
yeah I did now but is this only if you want to control the game with gamepads?I have a simple game which is controlled by keyboard.
danpost danpost

2016/1/6

#
matttic97 wrote...
yeah I did now but is this only if you want to control the game with gamepads?I have a simple game which is controlled by keyboard.
Yes, it is only if you want it controlled by game pads -- otherwise you do not need any of the template files. A simple game controlled by keyboard does not need any added files to the greenfoot project.
matttic97 matttic97

2016/1/6

#
Well I tried normally export project into jar file but when I open it only the run,stop and refresh button apear.
danpost danpost

2016/1/6

#
matttic97 wrote...
Well I tried normally export project into jar file but when I open it only the run,stop and refresh button apear.
Please show the code to the subclass of World that creates your initial world.
matttic97 matttic97

2016/1/6

#
1
2
3
4
5
6
7
8
9
10
11
super(800, 400, 1, false);
 
setPaintOrder(GameOver.class, FlappyBird.class, Točke.class, BottomPipe.class, TopPipe.class);
 
FlappyBird flappy = new FlappyBird();
 
addObject(flappy, 100, getHeight()/2);
 
točke = new Točke();
točke.nastaviTočke(0);
addObject(točke, 50, 25);
btw yes I'm making flappy bird haha I am beginner in this and I am in phase of learning basics
matttic97 matttic97

2016/1/6

#
the picture of the background is actually chosed in greenfoot by right clicking on subclass and then Set image ...is this wrong?
danpost danpost

2016/1/6

#
matttic97 wrote...
the picture of the background is actually chosed in greenfoot by right clicking on subclass and then Set image ...is this wrong?
That is one way. I would not suggest you do a flappy bird type scenario as a starter. You should start with Wombat and Crab type scenarios to build your knowledge of both java and greenfoot, first. You would not try to do multiplication without first learning what a number system is (then learning how to add).
matttic97 matttic97

2016/1/6

#
well actually I know java I'm just beginner in greenfoot and game does work and i have done some amendments myself.I only don't know how to export it right or is it harder because of a game type?
danpost danpost

2016/1/6

#
matttic97 wrote...
well actually I know java I'm just beginner in greenfoot and game does work and i have done some amendments myself.I only don't know how to export it right or is it harder because of a game type?
You should still build your knowledge of greenfoot. Get used to what methods are available in the various classes of the greenfoot package and get experience in their purposes and limitations. From that, you will be better equipped to produce something more elaborate.
matttic97 matttic97

2016/1/6

#
Yes I agree with that and flappy wasn't first game I was trying to make I started with wombat and that stuff so I learned how move and use methods and than i wanted to learn something where i can use gravity and counting scores methods and improving logic.So every sentence that is in my code i know why is there and on what does it affect.Now only thing that i have problem with is exporting and running it outside Greenfoot,
There are more replies on the next page.
1
2