Thread: [delta/richscape] fix logon death bug

Results 1 to 6 of 6
  1. #1 [delta/richscape] fix logon death bug 
    Registered Member

    Join Date
    Sep 2009
    Posts
    1,723
    Thanks given
    45
    Thanks received
    81
    Rep Power
    269
    okay this tut will show you how to fix the famous "deltascape random dieing upon log on glitch and will hopefully shop the threads on random dieing on deltascape
    Easy just go to NpcHandler.java,
    There search for:
    Code:
    AnnoyNpcs(int npcId)
    You'll see something like this

    Code:
    public void annoyNpcs(int npcId) {
            for(Player p : server.playerHandler.players) {
                if(p != null) {
                    client player = (client)p;
                    if (player.distanceToPoint(npcs[npcId].absX, npcs[npcId].absY) <= getDistanceForNpc(npcId) && p.heightLevel == npcs[npcId].heightLevel)  {
                        if(npcGetsAnnoyed(npcId) && (npcs[npcId] != null) && (npcs[npcId].StartKilling == 0)) {
                            npcs[npcId].StartKilling = player.playerId;                                            npcs[npcId].IsUnderAttack = true;
                            npcs[npcId].RandomWalk = false;
                            AttackPlayer(player.playerId);
                        }
                    }
                }
            }
        }
    Well in the line:
    Code:
    if (player.distanceToPoint(npcs[npcId].absX, npcs[npcId].absY) <= getDistanceForNpc(npcId) && p.heightLevel == npcs[npcId].heightLevel)
    Before the
    Code:
    )
    add this:
    Code:
    npcs[npcId].absX != 0 && npcs[npcId].absY != 0
    The entire void will be like this:
    Code:
    public void annoyNpcs(int npcId) {
            for(Player p : server.playerHandler.players) {
                if(p != null) {
                    client player = (client)p;
                    if (player.distanceToPoint(npcs[npcId].absX, npcs[npcId].absY) <= getDistanceForNpc(npcId) && p.heightLevel == npcs[npcId].heightLevel && npcs[npcId].absX != 0 && npcs[npcId].absY != 0)  {
                        if(npcGetsAnnoyed(npcId) && (npcs[npcId] != null) && (npcs[npcId].StartKilling == 0)) {
                            npcs[npcId].StartKilling = player.playerId;                                            npcs[npcId].IsUnderAttack = true;
                            npcs[npcId].RandomWalk = false;
                            AttackPlayer(player.playerId);
                        }
                    }
                }
            }
        }
    This mean that if jad is in the cords
    Code:
    absX 0, absY 0,
    the npc isn't aggressive so jad or any other of them will attack
    thus fixing your problem

    post if any errors
    Reply With Quote  
     

  2. Thankful user:


  3. #2  
    Registered Member
    Join Date
    Sep 2009
    Posts
    77
    Thanks given
    3
    Thanks received
    3
    Rep Power
    41
    Nice, dont need this but have seen alot of threads about it.

    Rep++ for good work.
    [Only registered and activated users can see links. ]
    Reply With Quote  
     

  4. #3  
    Registered Member
    Join Date
    Jun 2009
    Posts
    78
    Thanks given
    0
    Thanks received
    3
    Rep Power
    2
    rep++, i had this error today and this fixed it right up =)

    good work =)
    Reply With Quote  
     

  5. #4  
    Registered Member
    Alec_'s Avatar
    Join Date
    Aug 2009
    Posts
    274
    Thanks given
    3
    Thanks received
    9
    Rep Power
    111
    Why the fuck are you repping him, he copied word for word off another tutorial.
    [Only registered and activated users can see links. ]


    Quote Originally Posted by i say smd k View Post
    How about you stop flaming and understand the concept, my isp stops rsbot from working over here, when i go to my dad's house i bring my computer, and it works fine there, so..., if you have no fucking idea whats going on, and still talk shit, gtfo.
    Reply With Quote  
     

  6. #5  
    Want a b00b job? PM me.
    Unity's Avatar
    Join Date
    Jun 2008
    Age
    27
    Posts
    711
    Thanks given
    7
    Thanks received
    11
    Rep Power
    298
    Quote Originally Posted by Alec++ View Post
    Why the fuck are you repping him, he copied word for word off another tutorial.
    [Only registered and activated users can see links. ]
    That is his account man. He forgot the password for it and now uses this one. I should know..I'm his friend.
    Reply With Quote  
     

  7. #6  
    Registered Member

    Join Date
    Sep 2009
    Posts
    1,723
    Thanks given
    45
    Thanks received
    81
    Rep Power
    269
    atrix676 used to be mines but some 1 hacked it so i made this
    acc
    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
  •