Thread: woodcutting 6 errors

Results 1 to 7 of 7
  1. #1 woodcutting 6 errors 
    Registered Member Andrew's Avatar
    Join Date
    Nov 2008
    Posts
    2,890
    Thanks given
    612
    Thanks received
    207
    Rep Power
    551
    so im working on woodcutting and i converted my mining to woodcutting exept i get these 6 erros?

    Code:
    Client.java:55: cannot find symbol
    symbol  : variable trees
    location: class WoodCutting
                                                    for(int i = 0; i < Server.WoodCu
    tting.trees.length; i++){
    
         ^
    Client.java:60: cannot find symbol
    symbol  : variable trees
    location: class WoodCutting
                                                                    ReplaceObject(Se
    rver.WoodCutting.treeX[i], Server.WoodCutting.treeY[i], Server.WoodCutting.trees
    [i], 0, 10);
    
                                                                              ^
    Client.java:61: cannot find symbol
    symbol  : variable trees
    location: class WoodCutting
                                                                    Server.WoodCutti
    ng.trees[i] = 0;
    
      ^
    WoodCutting.java:83: cannot find symbol
    symbol  : variable trees
    location: class WoodCutting
                                            for(int i = 0; i < trees.length; i++){
                                                               ^
    WoodCutting.java:84: cannot find symbol
    symbol  : variable trees
    location: class WoodCutting
                                                    if(trees[i] == 0){
                                                       ^
    WoodCutting.java:85: cannot find symbol
    symbol  : variable trees
    location: class WoodCutting
                                                            trees[i] = objectIDT;
                                                            ^
    6 errors
    Press any key to continue . . .
    Reply With Quote  
     

  2. #2  
    なぜこのテキストは日本語で書かれている ?

    Kenneh's Avatar
    Join Date
    Dec 2009
    Age
    30
    Posts
    2,753
    Thanks given
    63
    Thanks received
    296
    Rep Power
    478
    You dont have a "trees" variable in your woodcutting class.


    Reply With Quote  
     

  3. #3  
    Registered Member Andrew's Avatar
    Join Date
    Nov 2008
    Posts
    2,890
    Thanks given
    612
    Thanks received
    207
    Rep Power
    551
    umm yes i do?

    Code:
    	public int[] tree = new int[100];
    				public int[] treesTimer = new int[100];
    				public int[] treeX = new int[100];
    				public int[] treeY = new int[100];
    Reply With Quote  
     

  4. #4  
    Registered Member
    Ant-Man's Avatar
    Join Date
    Aug 2010
    Posts
    1,018
    Thanks given
    277
    Thanks received
    177
    Rep Power
    452
    Make sure its not inter-twined with a constructor, I think it is called. and its trees[] not tree[]

    ex.


    void

    boolean()

    Reply With Quote  
     

  5. #5  
    なぜこのテキストは日本語で書かれている ?

    Kenneh's Avatar
    Join Date
    Dec 2009
    Age
    30
    Posts
    2,753
    Thanks given
    63
    Thanks received
    296
    Rep Power
    478
    Quote Originally Posted by andrewert View Post
    umm yes i do?

    Code:
    	public int[] tree = new int[100];
    				public int[] treesTimer = new int[100];
    				public int[] treeX = new int[100];
    				public int[] treeY = new int[100];
    That says tree, ur code says trees


    Reply With Quote  
     

  6. #6  
    Registered Member Andrew's Avatar
    Join Date
    Nov 2008
    Posts
    2,890
    Thanks given
    612
    Thanks received
    207
    Rep Power
    551
    wait so would i add another one saying trees?
    Reply With Quote  
     

  7. #7  
    Registered Member Andrew's Avatar
    Join Date
    Nov 2008
    Posts
    2,890
    Thanks given
    612
    Thanks received
    207
    Rep Power
    551
    oka yifeel stupid fixed
    Reply With Quote  
     


Thread Information
Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)


User Tag List

Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •