Thread: 317 [PI] Help Needed

Page 1 of 2 12 LastLast
Results 1 to 10 of 11
  1. #1 317 [PI] Help Needed 
    Registered Member Defective's Avatar
    Join Date
    Dec 2011
    Age
    29
    Posts
    466
    Thanks given
    20
    Thanks received
    3
    Rep Power
    62
    ok so i made some code that when clicked will open a tab where you get some info and teleport to donator zone... but my super donators and extreme donator cant get into this as there "isDonator" is 2 for super and 3 for extreme

    this is code:
    Code:
    				case 108003:
    				if (c.isDonator == 1) {
    				c.setSidebarInterface(4, 27620);
    				} else {
    				c.sendMessage("You must be an donator to view this tab!");
    				return;				
    				}
    				break;
    the isDonator == 1 how do i make it so it can apply to == 2 and == 3?
    i hope i explained myself enough

    thanks,
    Dragonmaidon
    Reply With Quote  
     

  2. #2  
    Renown Programmer

    Join Date
    Dec 2010
    Posts
    2,876
    Thanks given
    508
    Thanks received
    1,898
    Rep Power
    5000
    isDonator > 0

    how old are you, 5?
    never talk to me or my wife's son ever again
    Reply With Quote  
     

  3. Thankful user:


  4. #3  
    GANGNAM STYLE!

    Ohad's Avatar
    Join Date
    Aug 2011
    Posts
    3,179
    Thanks given
    152
    Thanks received
    352
    Rep Power
    1671
    Quote Originally Posted by Thee End View Post
    isDonator > 0

    how old are you, 5?
    he is learning...everybody starts somewere
    Reply With Quote  
     

  5. #4  
    Boom Boom

    Kakapo's Avatar
    Join Date
    Aug 2010
    Posts
    1,030
    Thanks given
    358
    Thanks received
    218
    Rep Power
    365
    Use the greater than operator like Thee End said


    Reply With Quote  
     

  6. #5  
    Registered Member Nouish's Avatar
    Join Date
    Jun 2011
    Posts
    822
    Thanks given
    142
    Thanks received
    177
    Rep Power
    282
    Quote Originally Posted by Xtinctionx View Post
    he is learning...everybody starts somewere
    I think he posted it because OP has an 317 hamachi server online ...
    Reply With Quote  
     

  7. #6  
    Renown Programmer

    Join Date
    Dec 2010
    Posts
    2,876
    Thanks given
    508
    Thanks received
    1,898
    Rep Power
    5000
    Quote Originally Posted by Xtinctionx View Post
    he is learning...everybody starts somewere
    comparing numbers isn't exactly advanced programming............
    never talk to me or my wife's son ever again
    Reply With Quote  
     

  8. Thankful user:


  9. #7  
    Donator

    Jason's Avatar
    Join Date
    Aug 2009
    Posts
    6,092
    Thanks given
    2,402
    Thanks received
    2,823
    Rep Power
    4550
    You could also use the or opperand which is pretty convenient if you only want certain levels of donators to enter that area

    Code:
    				case 108003:
    				if (c.isDonator == 1 || c.isDonator == 2 || c.isDonator == 3) {
    				c.setSidebarInterface(4, 27620);
    				} else {
    				c.sendMessage("You must be an donator to view this tab!");
    				return;				
    				}
    				break;
    Reply With Quote  
     

  10. #8  
    Registered Member Defective's Avatar
    Join Date
    Dec 2011
    Age
    29
    Posts
    466
    Thanks given
    20
    Thanks received
    3
    Rep Power
    62
    Quote Originally Posted by Gohan View Post
    You could also use the or opperand which is pretty convenient if you only want certain levels of donators to enter that area

    Code:
    				case 108003:
    				if (c.isDonator == 1 || c.isDonator == 2 || c.isDonator == 3) {
    				c.setSidebarInterface(4, 27620);
    				} else {
    				c.sendMessage("You must be an donator to view this tab!");
    				return;				
    				}
    				break;
    thanks man, repped. seeing as your the only one that actually did as the thread was asking
    Reply With Quote  
     

  11. Thankful user:


  12. #9  
    Donator

    Jason's Avatar
    Join Date
    Aug 2009
    Posts
    6,092
    Thanks given
    2,402
    Thanks received
    2,823
    Rep Power
    4550
    Quote Originally Posted by dragonmaidon View Post
    thanks man, repped. seeing as your the only one that actually did as the thread was asking
    You're very welcome mate.
    Reply With Quote  
     

  13. #10  
    Registered Member Turbo X Repz's Avatar
    Join Date
    Oct 2011
    Posts
    75
    Thanks given
    1
    Thanks received
    3
    Rep Power
    6
    instead of doing that other thing above you can simply add this
    Code:
    case 108003:
    				if (c.isDonator >= 1) {
    				c.setSidebarInterface(4, 27620);
    				} else {
    				c.sendMessage("You must be an donator to view this tab!");
    				return;				
    				}
    				break;
    Last edited by Turbo X Repz; 01-11-2012 at 02:57 AM. Reason: Miss spelled... -.-
    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. 317 PI Int's needed
    By im an 0 in forum Models
    Replies: 8
    Last Post: 10-12-2011, 11:07 PM
  2. [317] Horror Scape (Updated daily!) Staff needed [317]
    By 317HorrorScape317 in forum Advertise
    Replies: 4
    Last Post: 04-20-2011, 07:41 AM
  3. 317 Coder NEEDED
    By stormpker in forum Requests
    Replies: 2
    Last Post: 10-17-2010, 12:35 AM
  4. 317 hoster needed
    By melad khoury in forum Hosting
    Replies: 0
    Last Post: 05-21-2010, 09:13 PM
  5. 317 hoster needed
    By Rolfkip in forum Hosting
    Replies: 0
    Last Post: 03-28-2009, 08:22 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
  •