Thread: 718 Farming patch (objectDef.containsOption)

Page 1 of 2 12 LastLast
Results 1 to 10 of 11
  1. #1 718 Farming patch (objectDef.containsOption) 
    Registered Member
    Join Date
    Mar 2012
    Posts
    88
    Thanks given
    4
    Thanks received
    3
    Rep Power
    36
    I am currently adding farming (trees) to my server but for some reason the "objectDef.containsOption"
    won't read the options of the tree.

    probly cause the object is null


    Code:
    if (id == 8389) {
    					if (objectDef.containsOption(0, "Rake")) {
    						Farming.Raking(player, id);
    					} else if (objectDef.containsOption(0, "Chop down")) {
    						Farming.chopTree(player, id, player.getTreePatch());
    					} else if (objectDef.containsOption(0, "Check-Health")) {
    						Farming.checkHealth(player, id, player.getTreePatch());
    					} else {
    						player.getPackets().sendGameMessage("Use a seed on the patch.");
    					}
    				}
    Any ideas?
    Reply With Quote  
     

  2. #2  
    Registered Member

    Join Date
    Jul 2011
    Posts
    808
    Thanks given
    448
    Thanks received
    250
    Rep Power
    126
    because the options are null.
    Reply With Quote  
     

  3. #3  
    Registered Member
    Join Date
    Mar 2012
    Posts
    88
    Thanks given
    4
    Thanks received
    3
    Rep Power
    36
    So how woud that be fixed?
    like sending new options to that object after growing?
    Reply With Quote  
     

  4. #4  
    48 0x69

    Pax M's Avatar
    Join Date
    Oct 2013
    Posts
    2,012
    Thanks given
    36
    Thanks received
    488
    Discord
    View profile
    Rep Power
    2245
    Quote Originally Posted by Zephyrr View Post
    because the options are null.
    No, the object is null*
    Reply With Quote  
     

  5. #5  
    Registered Member
    Join Date
    Mar 2012
    Posts
    88
    Thanks given
    4
    Thanks received
    3
    Rep Power
    36
    Quote Originally Posted by Pax_ View Post
    No, the object is null*
    Yeah indeed, but how coud i fix that? I'm using configs for growing
    Reply With Quote  
     

  6. #6  
    Registered Member

    Join Date
    Jul 2011
    Posts
    808
    Thanks given
    448
    Thanks received
    250
    Rep Power
    126
    Quote Originally Posted by Pax_ View Post
    No, the object is null*
    wich make the option null.
    Reply With Quote  
     

  7. #7  
    48 0x69

    Pax M's Avatar
    Join Date
    Oct 2013
    Posts
    2,012
    Thanks given
    36
    Thanks received
    488
    Discord
    View profile
    Rep Power
    2245
    Quote Originally Posted by Zephyrr View Post
    wich make the option null.
    No... The option is NOT null.
    Reply With Quote  
     

  8. #8  
    Registered Member
    Join Date
    Mar 2012
    Posts
    88
    Thanks given
    4
    Thanks received
    3
    Rep Power
    36
    so how do i need to use the configs so the tree and its options aren't a null?
    Reply With Quote  
     

  9. #9  
    Success is the worst teacher

    Santa Hat's Avatar
    Join Date
    Oct 2012
    Age
    24
    Posts
    3,337
    Thanks given
    801
    Thanks received
    1,185
    Rep Power
    189
    Quote Originally Posted by Pax_ View Post
    No... The option is NOT null.
    If the object is null then the object would have no options, thus giving the object "null" options. More to the point how is the object null? The object exists lol

    Quote Originally Posted by Coinflipper View Post
    so how do i need to use the configs so the tree and its options aren't a null?
    When I made my old farming system I just handled it with a boolean as the selecting an option wouldnt work

    [Only registered and activated users can see links. ]
    Reply With Quote  
     

  10. #10  
    Registered Member
    Join Date
    Mar 2012
    Posts
    88
    Thanks given
    4
    Thanks received
    3
    Rep Power
    36
    Quote Originally Posted by Santa Hat View Post
    When I made my old farming system I just handled it with a boolean as the selecting an option wouldnt work
    I rather fix the null then using a cheap fix so it woud work with a null
    Reply With Quote  
     

Page 1 of 2 12 LastLast

Thread Information
Users Browsing this Thread

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


User Tag List

Similar Threads

  1. Replies: 10
    Last Post: 09-02-2013, 05:34 PM
  2. [718] Farming Patch
    By unitedpkz in forum Snippets
    Replies: 8
    Last Post: 07-24-2013, 03:13 AM
  3. Farming Patch
    By Adam™ in forum Requests
    Replies: 2
    Last Post: 05-28-2010, 11:10 PM
  4. [508] Farming patch
    By The Lizard King in forum Show-off
    Replies: 8
    Last Post: 01-30-2010, 02:41 AM
  5. Farming patch - Centering
    By Ayton in forum Help
    Replies: 2
    Last Post: 12-16-2009, 09:56 PM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •