Thread: Make Magic Chest Animate

Page 1 of 2 12 LastLast
Results 1 to 10 of 11
  1. #1 Make Magic Chest Animate 
    Registered Member
    Join Date
    Sep 2013
    Posts
    882
    Thanks given
    43
    Thanks received
    57
    Rep Power
    58
    Alright, I have a magic chest that's not animating like its suppose to. I know the animation id is 3117, was just wondering how i would make it animate like it should.

    This is how it's suppose to look/do



    This is what i currently have, but its not animating, just a chest sitting there like every other object

    Reply With Quote  
     

  2. #2  
    Registered Member
    Join Date
    Sep 2013
    Posts
    882
    Thanks given
    43
    Thanks received
    57
    Rep Power
    58
    bump.
    Reply With Quote  
     

  3. #3  
    Registered Member
    Join Date
    Sep 2013
    Posts
    882
    Thanks given
    43
    Thanks received
    57
    Rep Power
    58
    Bump.
    Reply With Quote  
     

  4. #4  
    Registered Member Arth's Avatar
    Join Date
    May 2011
    Posts
    753
    Thanks given
    29
    Thanks received
    39
    Rep Power
    9
    You have to have a method for object Animation,

    You'll need these in player assistant
    public void createPlayersObjectAnim(int X, int Y, int animationID, int tileObjectType, int orientation) {
    try{
    c.getOutStream().createFrame(85);
    c.getOutStream().writeByteC(Y - (c.mapRegionY * 8));
    c.getOutStream().writeByteC(X - (c.mapRegionX * 8));
    int x = 0;
    int y = 0;
    c.getOutStream().createFrame(160);
    c.getOutStream().writeByteS(((x&7) << 4) + (y&7));//tiles away - could just send 0
    c.getOutStream().writeByteS((tileObjectType<<2) +(orientation&3));
    c.getOutStream().writeWordA(animationID);// animation id
    } catch(Exception e){
    e.printStackTrace();
    }
    }

    public void objectAnim(int X, int Y, int animationID, int tileObjectType, int orientation) {
    for (Player p : PlayerHandler.players) {
    if(p != null) {
    Player players = (Player)p;
    if(players.distanceToPoint(X, Y) <= 25) {
    players.getPA().createPlayersObjectAnim(X, Y, animationID, tileObjectType, orientation);
    }
    }
    }
    }

    This is how you use it
    player.getPA().objectAnim(Xcoord, Ycoord, ANIMID, 10,-1);
    break;
    In that snippet, 10 = TileObjectType and -1 = Orientation

    That should work
    Reply With Quote  
     

  5. #5  
    Registered Member
    Join Date
    Sep 2013
    Posts
    882
    Thanks given
    43
    Thanks received
    57
    Rep Power
    58
    Quote Originally Posted by x1 att ftw x View Post
    You have to have a method for object Animation,

    You'll need these in player assistant



    This is how you use it


    In that snippet, 10 = TileObjectType and -1 = Orientation

    That should work
    where does it get called? im completely mind****ed atm.
    Reply With Quote  
     

  6. #6  
    Registered Member Arth's Avatar
    Join Date
    May 2011
    Posts
    753
    Thanks given
    29
    Thanks received
    39
    Rep Power
    9
    i spawned the object id 13291 and i was already animated.
    are you sure you have the right object id?
    Reply With Quote  
     

  7. #7  
    Registered Member
    Join Date
    Sep 2013
    Posts
    882
    Thanks given
    43
    Thanks received
    57
    Rep Power
    58
    Quote Originally Posted by x1 att ftw x View Post
    i spawned the object id 13291 and i was already animated.
    are you sure you have the right object id?
    yes i have the correct object id. this might be a client issue as i've used other clients and ive seen it animate
    Reply With Quote  
     

  8. #8  
    Registered Member Arth's Avatar
    Join Date
    May 2011
    Posts
    753
    Thanks given
    29
    Thanks received
    39
    Rep Power
    9
    Yes then its a client sided issue, theres no point in using that method i gave you sorry
    Reply With Quote  
     

  9. #9  
    Registered Member Arth's Avatar
    Join Date
    May 2011
    Posts
    753
    Thanks given
    29
    Thanks received
    39
    Rep Power
    9
    Hey man, im not completely sure about this but you might be able to animate an object through objectDef.

    Code:
    					if (i == 13291) {
    			class46.anInt781 = 3117;
    			}
    i think thats the animation variable im not sure.
    Can someone confirm if anInt781 = AnimationID?
    Reply With Quote  
     

  10. Thankful user:


  11. #10  
    Registered Member
    Join Date
    Sep 2013
    Posts
    882
    Thanks given
    43
    Thanks received
    57
    Rep Power
    58
    Quote Originally Posted by x1 att ftw x View Post
    Hey man, im not completely sure about this but you might be able to animate an object through objectDef.

    Code:
    					if (i == 13291) {
    			class46.anInt781 = 3117;
    			}
    i think thats the animation variable im not sure.
    Can someone confirm if anInt781 = AnimationID?
    worked thanks
    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. Replies: 1
    Last Post: 04-12-2010, 12:58 PM
  2. How would I make magic without...
    By doobie in forum Help
    Replies: 10
    Last Post: 07-06-2009, 07:02 PM
  3. [525] Make magic bow shoot rune arrows.
    By 'Hunter in forum Snippets
    Replies: 12
    Last Post: 04-11-2009, 04:39 PM
  4. How To Make A Flash Animation/siggy/banner
    By Torag in forum Tutorials
    Replies: 30
    Last Post: 09-08-2008, 01:08 PM
  5. A way to make magic hit better with better bonuses
    By bmxxscape in forum Tutorials
    Replies: 5
    Last Post: 06-27-2008, 09:59 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
  •