Search:

Type: Posts; User: captain

Search: Search took 0.07 seconds.

  1. Replies
    11
    Views
    2,166

    [SOLVED] Re: Random Colors Problem

    I got it guys! I kinda worked through it my own way. It may not be the most efficient but tell me what ya think. I ended up avoiding 2D arrays altogether and just used the gridlayout.

    Thanks for...
  2. Replies
    11
    Views
    2,166

    [SOLVED] Re: Random Colors Problem

    Sorry about this guys but I'm still having trouble. I just can't seem to get it to color only a certain amount of tiles. It either colors them all one color or gives me a nullpointer at
  3. Replies
    11
    Views
    2,166

    [SOLVED] Re: Random Colors Problem

    so you're basically saying something like this

    public void setColor() {
    for(int i = 0; i < tiles.length; i++)
    if(tiles[i] == null){
    setBackground(Color.YELLOW);...
  4. Replies
    11
    Views
    2,166

    [SOLVED] Random Colors Problem

    Alright so basically what I'm trying to do is create a 16x16 square board of tiles (256 total) and when I run the program I need it to set up the tiles randomly into the following colors
    39...
Results 1 to 4 of 4