Thread: Castle Wars Catapult!

Page 1 of 2 12 LastLast
Results 1 to 10 of 11
  1. #1 Castle Wars Catapult! 
    Registered Member
    Polaroid's Avatar
    Join Date
    Jul 2009
    Posts
    936
    Thanks given
    1,088
    Thanks received
    63
    Rep Power
    94
    Code:
    case 671: //By Bill 2010!
    if(actionTimer <= 1){
    if(playerHasItemAmount(968, 1)){
    deleteItem(968, getItemSlot(968), 1);
    attackPlayersWithin(300, 40, 10);
    attackPlayersWithin(300, 40, 10);
    attackPlayersWithin(500, 40, 10);
    attackPlayersWithin(400, 40, 10);
    staticAnimation(2109, absX, absY, 100);
    stillgfx(567, absY, absX);
    hitDiff = 8 + misc.random(20);
    inCombat();
    sendMessage("You shot the catapult at a player...");
    sendMessage("Hopefully it didn't hit YOUR team!");
    txt4 = "I shot the cannon - move, team!";
    string4UpdateRequired = true;
    actionTimer = 45;
    } else {
    sendMessage("Don't click so fast!");
    }
    }
    break;
    Will need changing according to server
    Reply With Quote  
     

  2. #2  
    Registered Member

    Join Date
    Feb 2009
    Age
    24
    Posts
    2,851
    Thanks given
    90
    Thanks received
    216
    Discord
    View profile
    Rep Power
    675
    Good job!
    Reply With Quote  
     

  3. #3  
    Super Donator


    Join Date
    Mar 2009
    Age
    25
    Posts
    1,393
    Thanks given
    316
    Thanks received
    408
    Rep Power
    608
    Nope.
    Reply With Quote  
     

  4. #4  
    Banned

    Join Date
    May 2008
    Posts
    2,327
    Thanks given
    55
    Thanks received
    67
    Rep Power
    0
    wrong, bad, and leeched (saw this on some thing from 2007 as i recall)

    edit: btw, this is how u make it more realistic

    Code:
    if (objectID == CATAPULT) {
    showInterface(11169);
    }
    wow, already 173% better then wat u posted
    Reply With Quote  
     

  5. #5  
    Registered Member
    Polaroid's Avatar
    Join Date
    Jul 2009
    Posts
    936
    Thanks given
    1,088
    Thanks received
    63
    Rep Power
    94
    Quote Originally Posted by silabgarza View Post
    wrong, bad, and leeched (saw this on some thing from 2007 as i recall)

    edit: btw, this is how u make it more realistic

    Code:
    if (objectID == CATAPULT) {
    showInterface(11169);
    }
    wow, already 173% better then wat u posted
    edit it so it fits and stop crying you nob
    Reply With Quote  
     

  6. #6  
    I don't take you serious
    Kastro's Avatar
    Join Date
    Nov 2008
    Posts
    2,504
    Thanks given
    92
    Thanks received
    389
    Rep Power
    604
    The fuck is this horrible shit?

    Code:
    	case 671:
    	if(actionTimer <= 1) {
    		if(!playerHasItemAmount(968, 1)) {
    			sendMessage("You don't have anything to load the catapault with!");
    		} else {
    			deleteItem(968, getItemSlot(968), 1);
    			int X = misc.random(zamorakDamageAreaX.length-1);
    			int Y = misc.random(zamorakDamageAreaY.length-1);
    			dealDamageTo(zamorakDamageAreaX[X], ZamorakDamageAreaY[Y], delay); //you'll need to add this yourself, I hope you're not to stupid to not know how to use arrays
    			staticAnimation(2109, absX, absY, 100);
    			stillgfx(567, absY, absX);
    			hitDiff = 8 + misc.random(20);
    			sendMessage("You shot the catapult at a player...");
    			actionTimer = 45;
    		} else {
    			sendMessage("Don't click so fast!");
    		}
    	}
    	break;
    My version is nothing more than fixing your disgusting shit. I do not suggest using this programming style at all for this.

    Reply With Quote  
     

  7. #7  
    Registered Member
    Polaroid's Avatar
    Join Date
    Jul 2009
    Posts
    936
    Thanks given
    1,088
    Thanks received
    63
    Rep Power
    94
    kthkzbi
    Reply With Quote  
     

  8. #8  
    Registered Member Scary Kid's Avatar
    Join Date
    Apr 2010
    Age
    26
    Posts
    49
    Thanks given
    0
    Thanks received
    1
    Rep Power
    22
    Quote Originally Posted by cows1471 View Post
    Code:
    case 671: //By Bill 2010!
    if(actionTimer <= 1){
    if(playerHasItemAmount(968, 1)){
    deleteItem(968, getItemSlot(968), 1);
    attackPlayersWithin(300, 40, 10);
    attackPlayersWithin(300, 40, 10);
    attackPlayersWithin(500, 40, 10);
    attackPlayersWithin(400, 40, 10);
    staticAnimation(2109, absX, absY, 100);
    stillgfx(567, absY, absX);
    hitDiff = 8 + misc.random(20);
    inCombat();
    sendMessage("You shot the catapult at a player...");
    sendMessage("Hopefully it didn't hit YOUR team!");
    txt4 = "I shot the cannon - move, team!";
    string4UpdateRequired = true;
    actionTimer = 45;
    } else {
    sendMessage("Don't click so fast!");
    }
    }
    break;
    Will need changing according to server
    Learn to use Arrays my friend. it makes things so much cleaner.
    Reply With Quote  
     

  9. #9  
    Registered Member
    sadgrills's Avatar
    Join Date
    Dec 2009
    Age
    25
    Posts
    1,418
    Thanks given
    119
    Thanks received
    194
    Rep Power
    315
    This attacks people on your team.


    Reply With Quote  
     

  10. #10  
    Registered Member
    G0nzo's Avatar
    Join Date
    Feb 2009
    Posts
    4,961
    Thanks given
    514
    Thanks received
    546
    Rep Power
    1735
    This is horrible.

    I would have expected code like this is 08.
    Computer Science Graduate, Java Expert
    Need help with something? PM me
    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

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