Java-Gaming.org    
Featured games (79)
games approved by the League of Dukes
Games in Showcase (477)
Games in Android Showcase (106)
games submitted by our members
Games in WIP (533)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
   Home   Help   Search   Login   Register   
  Show Posts
Pages: [1]
1  Games Center / WIP games, tools & toy projects / Re: Java tower defense game on: 2012-01-24 11:17:50
So I kinda gave up on the rotation for now, I'll come back to it, its not working no matter what I do. But i posted a new screen shot of stuff I did today. Check it out there will be a new video up later. Thanks!
2  Games Center / WIP games, tools & toy projects / Re: Java tower defense game on: 2012-01-23 09:29:15
alright so here is the whole class let me know if you see anything, thanks for checking it out!

1  
hidden
3  Games Center / WIP games, tools & toy projects / Re: Java tower defense game on: 2012-01-23 07:09:20
That doesn't help its something wrong with my calculations. Its not rotating toward the enemies its more just a random spinning and then the second tower placed down spins randomly around the first so on an so on. I can post the whole class if you want to take a look otherwise ill keep trying.
4  Games Center / WIP games, tools & toy projects / Re: Java tower defense game on: 2012-01-23 06:41:16
ok so i have some rotation but its very random and all over the place, and when i place a second tower it rotates around the first one. Anyone see why?

1  
2  
3  
4  
5  
6  
7  
8  
9  
10  
11  
//Tower
           double rot;
            Graphics2D g2d = (Graphics2D) g;
            for(int i = 0; i < tower.length; i++){
               
               rot = Math.atan2(mobs[i].y - tower[i].y, mobs[i].x - tower[i].y);
               if(towerID[i] != air) {
                  g2d.rotate(rot, tower[i].x + tower[i].width / 2, tower[i].y + tower[i].height / 2);
                  g.drawImage(aa.f.bp.tower[towerID[i]], tower[i].x, tower[i].y, tower[i].width, tower[i].height, null);
            }
            }
5  Games Center / WIP games, tools & toy projects / Re: Java tower defense game on: 2012-01-23 06:09:39
Ok so here is my code and its getting an error,

1  
2  
3  
4  
5  
6  
7  
8  
9  
//Tower
     double rot;
      for(int i = 0; i < tower.length; i++){
         rot = Math.atan2(mobs[i].y - tower[i].y, mobs[i].x - tower[i].y);
         if(towerID[i] != air) {
            g.drawImage(aa.f.bp.tower[towerID[i]], tower[i].x, tower[i].y, tower[i].width, tower[i].height, null);
            g.rotate(rot, tower[i].x + tower.length / 2, tower[i].y + tower.height / 2);
      }
      }
6  Games Center / WIP games, tools & toy projects / Re: Java tower defense game on: 2012-01-23 05:35:50
i really cant figure out how to make the tower rotate toward enemies, anyone have any ideas?
7  Games Center / WIP games, tools & toy projects / Re: Java tower defense game on: 2012-01-22 10:30:39
One comment: "public class ad ... " Really?! Shocked

haha just laziness. But thanks for checking it out! I'm trying to get the image to follow the line right now.
8  Games Center / WIP games, tools & toy projects / Re: Java tower defense game on: 2012-01-22 10:16:50
New Video: http://www.youtube.com/watch?v=Ymww6vpgndA

Put up the new video showing the towers firing, I'm gonna try and get the towers to rotate with the line in order to get 3D feel.
9  Games Center / WIP games, tools & toy projects / Re: Java tower defense game on: 2012-01-22 06:59:03
im gonna do the shooting system tonight, and ill put up a video of it, if anyone can suggest how i do the image animation after you see it let me know. I have some ideas but i really dont know if they are going to work!
10  Games Center / WIP games, tools & toy projects / Re: Java tower defense game on: 2012-01-22 06:39:01
Considering i have very little java experience this sounds quite complicated. Basically if i understand correctly i have to have the tower target the enemy then depending on its location choose an image that accurately depicts where is should be facing?

and to make this smooth ill need at least 20 images that each are slightly rotated in order to get a smooth rotating image?
11  Games Center / WIP games, tools & toy projects / Re: Java tower defense game on: 2012-01-22 06:25:06
animation is simply change sprite in constant time. Target an enemy and calculate the rotation for tower so it looks like following, and shoot in desired rate.

wont i need multiple images for that though? otherwise the whole tower image is going to shift instead of just the barrel of the tower.
12  Games Center / WIP games, tools & toy projects / Re: Java tower defense game on: 2012-01-22 01:58:50
So i want to make my towers and enemies like this:


Anyone have any ideas how i would make my characters/towers 3d like this and animated? Also anyone have an example code of a targeting system for the towers that makes towers pivot and follow the characters.
13  Games Center / WIP games, tools & toy projects / Re: Java tower defense game on: 2012-01-21 01:34:35
Does anyone know if i can use a 3d modeler with java? Like blender or something like that.
14  Games Center / WIP games, tools & toy projects / Re: Java tower defense game on: 2012-01-19 22:52:15
Now you put the images. The tower is cool, looks like helmet Grin

I was going for a kind of an Iron man looking tower haha, ill post more tonight either pictures or videos.
15  Games Center / WIP games, tools & toy projects / Re: Java tower defense game on: 2012-01-19 02:23:43
Nice artwork as I can see. Waitin for any version to try it Smiley

Thanks! its taken me forever to do all the art! Hopefully I can have a demo up soon!
16  Games Center / WIP games, tools & toy projects / Re: Java tower defense game on: 2012-01-17 05:54:40
You've only been programming in general....for 2 weeks... Shocked

It's looking good so far, keep up the good work Smiley

Thank you! I still have a lot to figure out though! Uploaded the new game over screen!
17  Games Center / WIP games, tools & toy projects / Re: Java tower defense game on: 2012-01-17 03:22:16
Any thoughts?
18  Games Center / WIP games, tools & toy projects / Java tower defense game on: 2012-01-15 01:22:41
So I'm very new to java I've been programming for only about 2 weeks. The past couple days I have been working on this tower defense game. Its in its very early stages many things don't work in it however for two days of work I'm pretty happy! Let me know what you think all feed back is welcome! I'll continue to post as I change things!

<youtube> http://www.youtube.com/watch?v=l4XrAnWxev4 VIDEO 1
               http://www.youtube.com/watch?v=Ymww6vpgndA VIDEO 2 UPDATE

New screen shot


New game over screen I've been working on:


New first wave zombie sprite:


New tower:




Pages: [1]
 

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

The first screenshot will be displayed as a thumbnail.

pw (24 views)
2014-07-24 01:59:36

Riven (22 views)
2014-07-23 21:16:32

Riven (18 views)
2014-07-23 21:07:15

Riven (21 views)
2014-07-23 20:56:16

ctomni231 (50 views)
2014-07-18 06:55:21

Zero Volt (45 views)
2014-07-17 23:47:54

danieldean (36 views)
2014-07-17 23:41:23

MustardPeter (39 views)
2014-07-16 23:30:00

Cero (54 views)
2014-07-16 00:42:17

Riven (54 views)
2014-07-14 18:02:53
HotSpot Options
by dleskov
2014-07-08 03:59:08

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:58:24

Java and Game Development Tutorials
by SwordsMiner
2014-06-14 00:47:22

How do I start Java Game Development?
by ra4king
2014-05-17 11:13:37

HotSpot Options
by Roquen
2014-05-15 09:59:54

HotSpot Options
by Roquen
2014-05-06 15:03:10

Escape Analysis
by Roquen
2014-04-29 22:16:43

Experimental Toys
by Roquen
2014-04-28 13:24:22
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!