我在哪里可以找到单词库或 Scratch 中此代码中所有可能的单词以重制 Wordle
基本上,我正在尝试从头开始创建自己的单词游戏,但我陷入了需要列出可能的单词列表的位置,因此他们不能只输入所有随机字母,因此他们必须输入的所有单词都必须是真实的话。因此,我调出了其他人的代码,但我找不到他们在哪里列出了可以输入的可能单词列表。我试图查找单词列表的代码是 https://scratch.mit.edu/projects/ 624796156/ 并单击“查看内部”以查看其代码。如果有人回复并告诉我他们在代码中添加了单词列表的位置,那将会非常有帮助。谢谢!
Basically, I am trying to create my own game of wordle in scratch but I got stuck on where I need to make a list of possible words, so they cannot just type in all random letters, so all words they have to type in have to be real words. So, I pulled up someone else code but I cannot find where they made their list of possible words to be able to input. The code I am trying to find the word list is https://scratch.mit.edu/projects/624796156/ and click see inside to view their code. It would be really helpful if someone were to reply and tell me where they added a wordlist in their code. Thanks!
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
这个临时项目有一个名为“Valid Words”的列表变量。在块菜单的橙色“变量”部分中,您将看到浅橙色标量变量和对标量变量进行操作的浅橙色块,然后是深橙色列表变量和对列表变量进行操作的深橙色块。选中变量旁边的框以使其出现在编辑器的图形显示上,从而更轻松地查看或编辑变量的初始值。
This scratch project has a list variable named "Valid Words". In the orange "Variables" section of the blocks menu, you'll see light orange scalar variables and light orange blocks which operate on scalar variables, followed by dark orange list variables and dark orange blocks which operate on list variables. Check the box next to a variable to make it appear on the editor's graphical display, making it easier to view or edit the variable's initial value(s).
可以预先填写一份清单。此内容成为项目的一部分,并且任何访问该项目的人都可以立即使用。
首先,在可用列表中找到列表块块(代码区域左侧的面板)。
打开列表块前面的复选框。这将使列表在舞台上可见。 (完成后,您可以再次将其关闭。)
现在有两种方法可以填充列表。
+
。输入一个词。根据需要经常重复此操作。鉴于 5 个字母的单词数量(您链接到的项目中为 10,658 个),我建议使用方法 #2。
提示:您可以从链接到的项目中导出单词列表,然后将该列表导入到您自己的项目中。请不要忘记给予信任。
It is possible to pre-fill a list. This content becomes part of the project, and will be instantly available to anyone visiting the project.
First of all, find the list block in the list of available blocks (the panel to the left of the code area).
Turn on the checkbox in front of the list block. This will make the list visible on the stage. (Once we are done, you can turn this off again.)
Now there are two ways to populate the list.
+
at the bottom left corner of the list. Enter a word. Repeat this as often as necessary.Given the number of 5-letter words (10,658 in the project you linked to), I'd recommend approach #2.
Tip: you could export the list of words from the project you linked to, and import that list into your own project. Please do not forget to give credit.