如何使用javafx 1.3重新加载或刷新场景 [英] How can you reload or refresh a scene with javafx 1.3

查看:1749
本文介绍了如何使用javafx 1.3重新加载或刷新场景的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在用javafx 1.3制作一个memorie游戏。

i'm making a "memorie" game with javafx 1.3.

(我的英语不是很好,但我会试试。)

(I'm not really good in English but i will try it.)

主要问题是,如何在场景变化后重新加载场景。并且重新加载我的意思是代码将再次完成。因为我有四个场景,而且所有的场景都是假的,但我展示的场景仍然是真实的。但其中一个场景必须重新加载以使游戏正确。

The main question is, how can I reload a scene after a scene change. And with reload I mean the code will be done again. Because I've four scenes, and all the scenes stay on false but the scene I show stays on true. But one of the scenes have to reload again to make the game right.

所以游戏中有16个矩形,哪个是壁橱,在它们下面有8个不同的图片来自每个两次。
但是当你找到所有8对夫妇时,会显示下一个祝贺的场景。您可以选择进入菜单并重新开始游戏。但随着洗牌,他只是从图片中洗牌,而不是他们自己的图片。因此,当你再次玩游戏时,你会有相同的图片,但不同的名字,夫妻不再正确。
所以我想重新加载或刷新场景,以便程序再次读取代码并使其正确。我一直在互联网上看很多,但我找不到它,尤其是在javafx 1.3中。很多新的好功能来自2.2,我只能使用它,如果它可以与1.3竞争

So The game has 16 rectangles wich are closet, underneath them there are 8 different pictures from every are twice. But when you found all the 8 couples, and the next scene with congratulations is shown. You have the option to go to menu and restart the game again. But with the shuffle he only shuffles the names from the pictures and not the pictures them selfs. So when you play the game again you have the same pictures but different names en the couples aren't right anymore. So I want to reload or refres the scene so that the code will be read again by the programm and to make it right. I've been looking a lot on the internet but I couldn't find it and especially not in javafx 1.3. Al lot of new good functions are from 2.2 and I can only use that if it's comperable with the 1.3

我不知道是否有人可以帮助我更好地使用代码如果是的话,你可以告诉我,我会发布它。但变量名称和事物都是荷兰语,所以我不知道你能理解它。

I don't know if someone can help me better with the code, if it is, you can tell me and I will post it. But the variable names and things are in dutch, so I don't know that you can understand it.

谢谢你的阅读,我希望有人知道怎么做。

Thankyou for reading and I hope that someone knows how to do it.

推荐答案

好吧,我们无法帮助你了解你的想法。你还问了不止一个问题。关于排序的事情,我无法帮助你。

Well, we can not help you on an idea you have. You also asked more than one question. On the sorting thing I can't help you.

对于不同场景之间的过渡,你会在这里找到一个非常好用的教程不同阶段之间的转换

For the transition between different scenes you will find a very nice and handy tutorial here Transition between different stages

此外还有一个youtube教程文章,如果你喜欢它。

There is also a youtube tutorial to this article if you prefer it.

关于排序我无法帮助你。您可能希望在此处发布代码,并可能将变量名称更改为英语。

About the sorting I can't help you. You might want to to post your code here and maybe change your variablesnames to english.

为什么只能使用javafx1.3。你需要下载的只是一个罐子。你总是应该使用当前版本。

Why can you use only javafx1.3. All you need to download is a jar. You always should use the current version.

我希望我能帮助你一点 - 至少在教程中

I hope I could help you a little bit - at least with the tutorial

这篇关于如何使用javafx 1.3重新加载或刷新场景的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆