Thread: [MATRIX] Simple IF Statement

Results 1 to 5 of 5
  1. #1 [MATRIX] Simple IF Statement 
    Registered Member
    Join Date
    Apr 2013
    Posts
    18
    Thanks given
    9
    Thanks received
    1
    Rep Power
    0
    Solved
    Reply With Quote  
     

  2. #2  
    Registered Member
    Join Date
    Nov 2013
    Posts
    28
    Thanks given
    7
    Thanks received
    2
    Rep Power
    11
    if (NPC.getName().equals("name")) {
    ...
    }

    Should be something like that.
    Reply With Quote  
     

  3. Thankful user:


  4. #3  
    Registered Member
    Join Date
    Apr 2013
    Posts
    18
    Thanks given
    9
    Thanks received
    1
    Rep Power
    0
    Wouldn't this also use shop controller? or what? because its making all npc's that have the trade option open general store and ignoring their normal shop if set.
    Reply With Quote  
     

  5. #4  
    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
    npchandler.java

    else if (npc.getId() == 551)
    ShopsHandler.openShop(player, 1);//1 = shop number

    put it under option2 so thats the trade option

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

  6. Thankful user:


  7. #5  
    Banned

    Join Date
    Jan 2012
    Age
    22
    Posts
    2,705
    Thanks given
    907
    Thanks received
    628
    Rep Power
    0
    else if (NPC.getName().equals("shop")) {
    ShopsHandler.openShop(player, Shopnumberhere);

    }
    Reply With Quote  
     

  8. Thankful user:



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. Explaining simple if and else statements for beginners
    By The Situationist in forum Application Development
    Replies: 9
    Last Post: 04-16-2010, 11:43 PM
  2. [508] Simple if statement problem
    By ToonshortyX in forum Help
    Replies: 1
    Last Post: 02-20-2009, 07:57 PM
  3. Using the 'IF' Statement
    By Concious in forum Tutorials
    Replies: 9
    Last Post: 01-26-2009, 03:41 AM
  4. A closer look at the if... Statement
    By Jay Dawg in forum Application Development
    Replies: 0
    Last Post: 05-31-2008, 12:09 AM
  5. Replacing lots of if statements with switch's.
    By Stanyer in forum Tutorials
    Replies: 6
    Last Post: 02-07-2008, 03:08 AM
Posting Permissions
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •