简体   繁体   English

为 Ursina Engine 设置 window 尺寸为 Python

[英]Set window size for Ursina Engine for Python

I'm using Ursina Engine to make a game.我正在使用 Ursina Engine 制作游戏。 However I can't figure out a way how to set a specific size for the window. I need to figure this out, because I can't see part of it, because it's bigger than my screen.但是我想不出如何为 window 设置特定大小的方法。我需要弄清楚这一点,因为我看不到它的一部分,因为它比我的屏幕大。

I tried to use other posts on StackOverflow, but couldn't find anything.我尝试使用 StackOverflow 上的其他帖子,但找不到任何东西。 I also tried to use ChatGPT , however it didn't help.我也尝试使用ChatGPT ,但没有用。

A google search led me to the documentation of the engine, where I found this: https://www.ursinaengine.org/api_reference.html谷歌搜索让我找到了引擎的文档,在那里我找到了这个: https://www.ursinaengine.org/api_reference.html

As I understand it your main app class Ursina() , can accept various arguments, including amongst others 'size'.据我了解,您的主要应用程序 class Ursina()可以接受各种 arguments,其中包括“大小”。

Scrolling further down to the part named 'ASCIIEditor' there's an example usage:进一步向下滚动到名为“ASCIIEditor”的部分,有一个示例用法:

app = Ursina(size=(1920,1080))

My experience with Ursina is limited to some introductory videos, so take this for what it is.我对 Ursina 的体验仅限于一些介绍性视频,因此请按原样使用。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM