Java-Gaming.org    
Featured games (81)
games approved by the League of Dukes
Games in Showcase (483)
Games in Android Showcase (110)
games submitted by our members
Games in WIP (550)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1] 2 3 ... 10
 1 
 on: 2014-08-23 18:36:52 
Started by SauronWatchesYou - Last post by BurntPizza
I figured as much, but there was the possibility that that was not Sprite.rotate(), so I thought I'd ask.

 2 
 on: 2014-08-23 18:34:30 
Started by SauronWatchesYou - Last post by SauronWatchesYou
Fixed Grin love you, Troll xD

@Pizza The parameters asks for degrees as it's parameter Smiley



 3 
 on: 2014-08-23 18:29:18 
Started by Endos - Last post by Endos
Hi all! Here is the new trailer! Hope you like it!

<a href="http://www.youtube.com/v/0WpgnHq77n8?version=3&amp;hl=en_US&amp;start=" target="_blank">http://www.youtube.com/v/0WpgnHq77n8?version=3&amp;hl=en_US&amp;start=</a>

 4 
 on: 2014-08-23 18:25:45 
Started by SauronWatchesYou - Last post by BurntPizza
Math.atan2(x-x,y-y)

You put wrong coordinates.

He has it right. http://docs.oracle.com/javase/7/docs/api/java/lang/Math.html#atan2(double,%20double)

That said, note that in libGDX, mouse events are in a top-left origin coordinate system, but everything else is bottom left.
Also, what is the rotate method? Is it designed to accepts it's parameter in degrees?

EDIT:
EDIT--
Also, .rotate probably adds to the current rotation. You need to do something like .setAngle or .setRotation or something like that.

That's almost definitely what it is.

 5 
 on: 2014-08-23 18:19:38 
Started by SauronWatchesYou - Last post by trollwarrior1
Math.atan2(x-x,y-y)

You put wrong coordinates.

EDIT--
Also, .rotate probably adds to the current rotation. You need to do something like .setAngle or .setRotation or something like that.

 6 
 on: 2014-08-23 18:17:16 
Started by SauronWatchesYou - Last post by SauronWatchesYou
Hi guys

I've been looking into rotating my player sprite to face the mouse cursor and I've hit an issue. The rotation works but it spins out of control.

This is the first time I've tried doing this and quickly read some guides but I likely missed something. Below is the code i'm using for the rotation along with a gif of the problem(The other ship you see if where the mouse is):

1  
2  
3  
4  
5  
6  
    
      float angle = (float) Math.atan2(Gdx.input.getY() - player.getPlayerSprite().getY(), Gdx.input.getX() - player.getPlayerSprite().getX());
     
      angle = (float) Math.toDegrees(angle);
           
      player.getPlayerSprite().rotate(angle);


Sorry that the gif is so small

Click to Play


Like I said, I've not done this before or actually anything with rotations so i'm still trying to learn and hopefully someone can help me out Pointing

 7 
 on: 2014-08-23 18:07:49 
Started by kevglass - Last post by Herjan
It's kinda make to be a successor to Legends of Yore, so I'm thinking mobile is where I like to play best.

It's really where the question came from, I love the free movement but on mobiles past experience makes me think it's not as nice as infrequent tapping.

There is a certain difference between turn-based games and infrequent tapping...
It's not like free movement can't have that infrequent tapping, moving tile by tile, the difference is kind of that other objects in the world keep moving whether you do something or not.

 8 
 on: 2014-08-23 18:03:38 
Started by kevglass - Last post by kevglass
It's kinda make to be a successor to Legends of Yore, so I'm thinking mobile is where I like to play best.

It's really where the question came from, I love the free movement but on mobiles past experience makes me think it's not as nice as infrequent tapping.

Kev

 9 
 on: 2014-08-23 17:52:08 
Started by kevglass - Last post by Rayvolution
Thanks guys, and I'm really looking for subjective opinions, I'll boil it down afterwards.

Cheers,

Kev

mhmm, I just realized I focused way too much on the actual controls, missing the point of the post. I got wrapped up in "how would I make this guy move?" more than the overall feel of the game. Tongue

Whats the primary market? If you're going the PC route as the main target, this game would probably benefit most from free moving/free flowing platformer. But if your main market is mobile, tile based/turn based would be best so the player can play at his own pace and not get clobbered by bad guys because someone distracted him in real life. I guess it's been my experience that in a mobile game, turn based seems to work better, because when you're playing typically you find yourself in situations where someone will come up and start talking to you or distracting you in some way, with a turn based game you can simply just stop playing and give them your attention and then return to the game when they leave, but in a free flowing/live game, you can't do that so much. Where as, at home you usually have a game's complete attention and you can have a live game.

As far as overall quality, I think a live/free flowing game would be best, it'll give the world you're making the most "life/atmosphere", but if mobile is your primary target, I think you'd still benefit more from turn based based on what I said above.

 10 
 on: 2014-08-23 17:34:55 
Started by kevglass - Last post by kevglass
Thanks guys, and I'm really looking for subjective opinions, I'll boil it down afterwards.

Cheers,

Kev

Pages: [1] 2 3 ... 10
 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

CopyableCougar4 (18 views)
2014-08-22 19:31:30

atombrot (28 views)
2014-08-19 09:29:53

Tekkerue (25 views)
2014-08-16 06:45:27

Tekkerue (23 views)
2014-08-16 06:22:17

Tekkerue (15 views)
2014-08-16 06:20:21

Tekkerue (22 views)
2014-08-16 06:12:11

Rayexar (63 views)
2014-08-11 02:49:23

BurntPizza (39 views)
2014-08-09 21:09:32

BurntPizza (31 views)
2014-08-08 02:01:56

Norakomi (38 views)
2014-08-06 19:49:38
List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06

List of Learning Resources
by SilverTiger
2014-07-31 11:54:12

HotSpot Options
by dleskov
2014-07-08 01:59:08
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!