how to import Universal tween engine in IntelliJ with lib gdx
Asked Answered
W

1

1

okay.. I'm trying to create a splash screen for my mobile game. im using lib gdx library to create my game. i have a problem with importing the universal tween engine for my sprite splash. what should I do.

I've downloaded the universal tween engine and extracted it in the "libs" folder in the ios, android, core, and root of my project.. and i copied and paste these lines for each dependencies:

project(":core") {

fileTree(dir: 'D:/game/core/libs', include: 'tween-engine-api.jar')

compile fileTree(dir: 'D:/game/core/libs', include: 'tween-engine-api->sources.jar')

project(":desktop") {

compile fileTree(dir: 'D:/game/desktop/libs', include: 'tween-engine-api.jar')

compile fileTree(dir: 'D:/game/desktop/libs', include: 'tween-engine-api->sources.jar')

project(":ios") {

compile fileTree(dir: 'D:/game/ios/libs', include: 'tween-engine-api.jar')

compile fileTree(dir: 'D:/game/ios/libs', include: 'tween-engine-api->sources.jar')

project(":android") {

compile fileTree(dir: 'D:/game/android/libs', include: 'tween-engine-api.jar')

compile fileTree(dir: 'D:/game/android/libs', include: 'tween-engine-api->sources.jar')

the code in my Spite accessor class :

   package com.game.test;

   import aurelienribon.tweenengine.TweenAccessor;

   public class SpriteAccessor implements TweenAccessor{

   }

the error:

  1. Error:(3, 33) java: package aurelienribon.tweenengine does not exist

  2. Error:(5, 40) java: cannot find symbol symbol: class TweenAccessor

P.S.

Im following a video tutorial by dermetfan and I also put in th terminal these lines:

gradlew --refresh-dependencies

Weaks answered 25/8, 2015 at 11:27 Comment(7)
You only need to add the appropriate 'compile fileTree' entries to the Core and Android project sections in your build.gradle. See github.com/libgdx/libgdx/wiki/Universal-Tween-EngineCaseate
And in your code paste, you're missing a 'compile' from the beginning of your first example fileTree entryCaseate
still does not work....Weaks
I'm not sure what to suggest, other than try following the wiki instructions to a tee, on a new, bare bones project. Those instructions work absolutely fine for me, in existing projects and on a new one I've just tested.Caseate
nothing works for me.. this sucksWeaks
Did you try starting with a fresh, blank project, created by gdx-setup.jar?Caseate
ill try not using the tween engine.. maybe next time.. ive wasted too much time for this import thingWeaks
H
0

LibGdx uses gradle for dependency management.

You can inject dependency from repository. add these lines in your core module of root build.gradle file.

repositories {
  maven { url "https://jitpack.io" }
}

compile 'com.github.arcnor:universal-tween-engine:6.3.4'
compile 'com.github.arcnor:universal-tween-engine:6.3.4:sources'
Hufford answered 2/1, 2017 at 12:20 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.