如何使用IntelliJ设置libdgx? [英] How to set up libdgx with IntelliJ?

查看:133
本文介绍了如何使用IntelliJ设置libdgx?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我遵循了这个教程,但它似乎已经过时了?我不确定。

不幸的是我对Java不是很有经验(但是使用C#,Python,...)所以也许有一些我不明白的事情。

I followed this tutorial but it seems that it is kind out of date? I'm not sure.
Unfortunately I'm not very experienced with Java (but with C#, Python, ..) so maybe there is something obvious I did not regard.

IntelliJ给我从com.badlogic.gdx包中的库导入错误

IntelliJ is giving me import errors for libraries from the com.badlogic.gdx package

import com.badlogic.gdx.ApplicationAdapter;
import com.badlogic.gdx.Gdx;
import com.badlogic.gdx.graphics.GL20;
import com.badlogic.gdx.graphics.Texture;
import com.badlogic.gdx.graphics.g2d.SpriteBatch;




java:package com.badlogic.gdx不存在
等..

java: package com.badlogic.gdx does not exist etc..

实际上我会说有一些缺失的依赖,但是这个gdx-setup.jar应该已经解决了这个问题? / p>

Actually I would say there are some missing dependencies but this gdx-setup.jar should solve this problems already?

推荐答案

我遇到了同样的问题,我找到了适合我的答案。

I had the same problem and just found the answer that worked for me.

从你放置android sdks的工具目录中打开你的android skd管理器

Open your android skd manager from the tools directory of where ever you put the android sdks

确保安装了Android SDK build-tools 19.03

make sure that Android SDK build-tools 19.03 is installed

如果没有安装它

然后转到intelliJ并从菜单栏打开
查看 - >工具Windows - > gradle

then go to intelliJ and from the menu bar open View->Tool Windows->gradle

然后点击刷新(两个绿色箭头)

then hit the refresh (two green arrow)

无论如何为我工作。

这篇关于如何使用IntelliJ设置libdgx?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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