Thread: little help plz

Results 1 to 5 of 5
  1. #1 little help plz 
    Registered Member g0d 0f war's Avatar
    Join Date
    Mar 2011
    Posts
    711
    Thanks given
    10
    Thanks received
    15
    Rep Power
    20
    ok im making a spawn pk server and i was woundering how to make curses only used when you have 5k pkpoints here's my case

    case 411:
    if(c.pkPoints == 0) {
    c.sendMessage("You must have 5k pkPoints to activate curses!");
    } else {
    if(c.altarPrayed == 0) {
    c.altarPrayed = 1;
    c.setSidebarInterface(5, 22500);
    c.startAnimation(645);
    c.sendMessage("You sense a surge of power flow through your body!");
    c.getCombat().resetPrayers();
    } else {
    c.altarPrayed = 0;
    c.setSidebarInterface(5, 5608);
    c.startAnimation(645);
    c.sendMessage("You sense a surge of purity flow through your body!");
    c.getCurse().resetCurse();
    }
    }

    break;
    Reply With Quote  
     

  2. #2  
    Donator


    Join Date
    Jun 2011
    Posts
    2,549
    Thanks given
    539
    Thanks received
    402
    Rep Power
    683
    Use code tags next time please.

    May not be right, but hey why not.

    Code:
    case 411:
    if(c.pkPoints == 0) {
    return;
    c.sendMessage("You must have 5k pkPoints to activate curses!");
    }
    All the best,
    Nirvana

    Reply With Quote  
     

  3. #3  
    Registered Member Pakku's Avatar
    Join Date
    Mar 2010
    Posts
    1,234
    Thanks given
    127
    Thanks received
    111
    Rep Power
    47
    Code:
    c.pkPoints == 0
    ???????

    Code:
    c.pkPoints < 5000


    Reply With Quote  
     

  4. #4  
    Banned

    Join Date
    Mar 2011
    Posts
    4,062
    Thanks given
    194
    Thanks received
    689
    Rep Power
    0
    just put

    if (c.pkPoints < 5000) {
    c.sendMessage("You need atleast 5000 Pk Points to use curses.");
    return;
    }
    Reply With Quote  
     

  5. #5  
    Registered Member Instigator's Avatar
    Join Date
    Sep 2011
    Posts
    102
    Thanks given
    1
    Thanks received
    8
    Rep Power
    0
    Quote Originally Posted by g0d 0f war View Post
    ok im making a spawn pk server and i was woundering how to make curses only used when you have 5k pkpoints here's my case

    case 411:
    if(c.pkPoints == 0) {
    c.sendMessage("You must have 5k pkPoints to activate curses!");
    } else {
    if(c.altarPrayed == 0) {
    c.altarPrayed = 1;
    c.setSidebarInterface(5, 22500);
    c.startAnimation(645);
    c.sendMessage("You sense a surge of power flow through your body!");
    c.getCombat().resetPrayers();
    } else {
    c.altarPrayed = 0;
    c.setSidebarInterface(5, 5608);
    c.startAnimation(645);
    c.sendMessage("You sense a surge of purity flow through your body!");
    c.getCurse().resetCurse();
    }
    }

    break;
    Code:
    case 411:
    if(c.pkPoints < 5000){
      c.sendMessage("You must have 5k pkPoints to activate curses!");
    }else if(c.altarPrayed == 0){
      c.altarPrayed = 1;
      c.setSidebarInterface(5, 22500);
      c.startAnimation(645);
      c.sendMessage("You sense a surge of power flow through your body!");
      c.getCombat().resetPrayers();
    }else{
      c.altarPrayed = 0;
      c.setSidebarInterface(5, 5608);
      c.startAnimation(645);
      c.sendMessage("You sense a surge of purity flow through your body!");
      c.getCurse().resetCurse();
    }
    		break;
    The only reason this wasn't done properly is due to laziness otherwise you could have done it without help ...
    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
  •