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

2014/6/16

Open a .HTML page when the user clicks a JButton?

Mint_Greenie Mint_Greenie

2014/6/16

#
Hello, I have a game called 'Infinity', the colour picker for the game is kinda complicated because you have to enter a non-visual RGB code... About 50% of the users who will play my game won't know how to do that. I decided for now to show them a RGB color chart. I went ahead and searched DuckDuckGo for charts, and I found one so I went on my keyboard and went 'CMD-S' that saved the page to my desktop. I want Greenfoot to open up that .HTML page when I click a JButton in the main menu. That JButton already directs to a different world. I appreciate any help! Thank you! Mint_Green
Mint_Greenie Mint_Greenie

2014/6/16

#
Please help
erdelf erdelf

2014/6/16

#
it's not possible on the site as far as i know, java has restrictions for applets
Mint_Greenie Mint_Greenie

2014/6/16

#
Oh, thanks anyways @erdelf!
Upupzealot Upupzealot

2014/6/16

#
Why you want to use a JButton? In Greenfoot we use Actor for anything that is displayed on the screen. And your html file, is it a local file or a webpage?
danpost danpost

2014/6/16

#
Upupzealot wrote...
In Greenfoot we use Actor for anything that is displayed on the screen
And the world canvas (the background image of the world).
danpost danpost

2014/6/18

#
I have created an Actor class that creates an object that allows the user to select a color. It is included in my most recent scenario, ColorSelector and DropDown Options. It is a self-contained class called ColorPanel that comes with color box that becomes a drop-down of various default colors as well as bars to modify the color parts. Maybe you can make use of it.
You need to login to post a reply.