Thread: Summoning

Results 1 to 6 of 6
  1. #1 Summoning 
    Banned
    Join Date
    Oct 2011
    Posts
    85
    Thanks given
    16
    Thanks received
    0
    Rep Power
    0
    Code:
    		if (inWilderness() && (getMask().getSwitchId() == originalId || getMask().getSwitchId() == -1)) {
    			getMask().setSwitchId(getId() + 1);
    		} else if (getMask().getSwitchId() != originalId) {
    			getMask().setSwitchId(originalId);
    		}
    Whenever this code is used the familar keeps modifying it's id by 1 and never stops, any idea how to fix?
    Reply With Quote  
     

  2. #2  
    Registered Member
    Join Date
    Nov 2011
    Posts
    5
    Thanks given
    0
    Thanks received
    2
    Rep Power
    0
    Is it because of the (getid)+1); ? :l
    Reply With Quote  
     

  3. #3  
    Banned
    Join Date
    Oct 2011
    Posts
    85
    Thanks given
    16
    Thanks received
    0
    Rep Power
    0
    Quote Originally Posted by Tyrell View Post
    Is it because of the (getid)+1); ? :l
    Yes, but when it's in wilderness it should change it's id by one to become attackable
    Reply With Quote  
     

  4. #4  
    Registered Member

    Join Date
    Aug 2011
    Posts
    2,760
    Thanks given
    297
    Thanks received
    534
    Rep Power
    1596
    Because you're looping it, every time when this code occurs it'll do the id +1.
    Quote Originally Posted by Aj View Post
    This is not even a tutorial. It's fail for rep. It's fail for life.
    Reply With Quote  
     

  5. #5  
    Banned
    Join Date
    Apr 2011
    Posts
    500
    Thanks given
    3
    Thanks received
    40
    Rep Power
    0
    make it so once it increases one, it stops. Otherwise the value increase to an amount you won't want it too.
    Reply With Quote  
     

  6. #6  
    Banned
    Join Date
    Oct 2011
    Posts
    85
    Thanks given
    16
    Thanks received
    0
    Rep Power
    0
    Quote Originally Posted by Knox View Post
    make it so once it increases one, it stops. Otherwise the value increase to an amount you won't want it too.
    Mmk, thanks
    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: 1
    Last Post: 01-03-2012, 10:48 PM
  2. Replies: 20
    Last Post: 09-15-2011, 05:31 AM
  3. Replies: 7
    Last Post: 08-06-2008, 01:06 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
  •