Thread: Only certain items stakeable?

Results 1 to 3 of 3
  1. #1 Only certain items stakeable? 
    Middle Finger is Here


    Join Date
    Feb 2012
    Age
    27
    Posts
    2,557
    Thanks given
    377
    Thanks received
    502
    Rep Power
    162
    how do i make it so u can only stake certain items?

    i've tried so far

    if (itemID == idhere)
    return true;

    any suggestions?
    Hi
    Reply With Quote  
     

  2. #2  
    Donator


    Join Date
    Jan 2010
    Age
    25
    Posts
    3,985
    Thanks given
    257
    Thanks received
    470
    Rep Power
    536
    Just copy and change the code of untradeable items but then make it with tradeable items.
    Reply With Quote  
     

  3. #3  
    Banned

    Join Date
    Mar 2011
    Posts
    4,069
    Thanks given
    194
    Thanks received
    688
    Rep Power
    0
    Code:
    	private static final int[] UNSTAKEABLES = {
    		{4151}, {11697}
    	};
    
    	private static boolean isStakeable(int id) {
    		for (int i : UNSTAKEABLES) {
    			if (id == i) {
    				return false;
    			}
    		}
    		return true;
    	}
    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

Similar Threads

  1. Replies: 7
    Last Post: 07-26-2011, 05:18 AM
  2. Replies: 7
    Last Post: 04-06-2011, 11:05 PM
  3. Replies: 7
    Last Post: 02-09-2011, 10:14 AM
  4. Replies: 2
    Last Post: 11-28-2009, 06:30 PM
  5. Replies: 39
    Last Post: 11-29-2008, 10:31 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
  •