Sao nó cứ Dis hoài vậy

Thảo luận trong 'TS Online' bắt đầu bởi VisihaSasuke, 6/5/06.

  1. VisihaSasuke

    VisihaSasuke C O N T R A

    Tham gia ngày:
    19/4/06
    Bài viết:
    1,525
    Nơi ở:
    Kế bên GF
    PHP:
     double DisconnectFlag 0.3;     // Disconnect when current HP is below 30% 

    double hpFractionEat 0.8;    //Eat HP when current HP<= 80% 
    double spFractionEat 0.8
    double hpFraction 0.95;        //Eat until current HP >= 95 % 
    double spFraction 0.95

    byte DisconFai 00;        //    Faith of warrior to disconnect 

    byte battle_count 0
    byte NS_count 0
    byte myturn 0
    byte peturn 0

    byte pt1 0
    byte pt2 0
    byte pt3 0
    byte pt4 0

    //double mapid1 = 13000;  
    //double mapid2 = 21501; 
    //byte warpid1 = 27; 
    //byte warpid2 = 2; 

    /***** Chinh sua ID Member o day *****/ 

    uint idmem1 1026281
    uint idmem2 795655
    uint idmem3 1547963
    uint idmem4_sena 1796862

    /*************************************/ 

    /*********************** My Attack *************************/ 
    public override void MyAttack() 
    {    
    myturn++; 
    if (
    myturn == 1

    CharacterInfo MyChar ts.Character;  
    //NPCCombatObject Monster = findMonster();     
    ts.SendAttack(MyChar.RowMyChar.Col0117001);     

    if (
    myturn >=2

    CharacterInfo MyChar ts.Character;  
    //NPCCombatObject Monster = findMonster();     
    ts.SendAttack(MyChar.RowMyChar.Col0417001); 




    /******************* My Partner Attack *********************/ 
    public override void MyPartnerAttack() 

    peturn++; 
    if (
    peturn == 1

    CharacterInfo MyWarrior ts.CurrentPartner;  
    //NPCCombatObject Monster = findMonster();     
    ts.SendAttack(MyWarrior.RowMyWarrior.Col0217001); 

    if (
    peturn >= 2

    CharacterInfo MyWarrior ts.CurrentPartner;  
    //NPCCombatObject Monster = findMonster();     
    ts.SendAttack(MyWarrior.RowMyWarrior.Col0417001); 




    /********************* Battle Started **********************/ 
    public override void BattleStarted() 

    battle_count++; 
    myturn 0
    peturn 0



    /********************* Battle Stopped ***********************/ 
    public override void BattleStopped() 
    {     
    AutoEatFood(); 
    ProcessInventoryAction(); 
    CheckDisconnect();     
    ViewState(); 
    ts.SendEnd(); 



    /******************* Receive Question *********************/ 
    public override void doRecvQuestion() 

    NS_count++; 



    /******************** Response Answer **********************/ 
    public override void ResponseAnswer() 
    {         
    string tmp=ts.LastQuestion.Replace("=?",""); 
    int ans=ts.Eval(tmp); 
    byte ans_index=Convert.ToByte(ts.LastAnswers[ans.ToString()]);     
    ts.Answer(ans_index); 



    /******************** NPC Dialog Menu **********************/ 
    public override void NpcDialogMenu(ushort DialogId

    debug("Dialog Menu ID = "+DialogId.ToString()); 



    /********************* NPC Dialog ID ***********************/ 
    public override void NpcDialog(ushort DialogId
    {     
                
    debug("Dialog ID="+DialogId.ToString()); 
                             if(
    DialogId == 12249
                             { 
                                    
    ts.ClickOnNPC(50); 
                                    
    ts.ClickOnNPC(50); 
                                    
    ts.SendEnd(); 
                                    return;  
                             } 
                             
    ts.SendEnd(); 



    /********************* On NPC Appear ***********************/ 
    public override void onNPCAppear(ushort npcmapidint xint y
    {     



    /************************ On Timer *************************/ 
    public override void OnTimer() 

    if (
    pt1 == 0) {ts.AcceptParty(idmem1);} 
    if (
    pt2 == 0) {ts.AcceptParty(idmem2);} 
    if (
    pt3 == 0) {ts.AcceptParty(idmem3);} 
    if (
    pt4 == 0) {ts.AcceptParty(idmem4_sena);} 



    /********************* Accepted Party **********************/ 
    public override void AcceptedParty(uint playerid

    if (
    playerid == idmem1)       {debug(playerid "  Gia nh?p d?i ngu");pt1 1;} 
    if (
    playerid == idmem2)       {debug(playerid "  Gia nh?p d?i ngu");pt2 1;} 
    if (
    playerid == idmem3)       {debug(playerid "  Gia nh?p d?i ngu");pt3 1;} 
    if (
    playerid == idmem4_sena)  {debug(playerid "  Gia nh?p d?i ngu");pt4 1
                                   
    ts.Sena(idmem4_sena);debug(playerid "  Làm Quân Su");} 
    if (
    pt1 == && pt2 == && pt3 == && pt4 == 1) {ts.SetTimerOnOff(false);ts.delay(1000);debug("Ð?i ngu dã d?y -> Start");Start();} 



    /*********************** Party Stop ************************/ 
    public override void PartyStop(uint playerid

    if (
    playerid == idmem1)      {debug(playerid+"  R?i kh?i d?i ng? -> Disconnect !!!");ts.SetTimerOnOff(false);ts.delay(500);ts.Disconnect();} 
    if (
    playerid == idmem2)      {debug(playerid+"  R?i kh?i d?i ng? -> Disconnect !!!");ts.SetTimerOnOff(false);ts.delay(500);ts.Disconnect();} 
    if (
    playerid == idmem3)      {debug(playerid+"  R?i kh?i d?i ng? -> Disconnect !!!");ts.SetTimerOnOff(false);ts.delay(500);ts.Disconnect();} 
    if (
    playerid == idmem4_sena) {debug(playerid+"  R?i kh?i d?i ng? -> Disconnect !!!");ts.SetTimerOnOff(false);ts.delay(500);ts.Disconnect();} 



    /********************** Warp Finish ************************/ 
    public override void warpFinish() 

    Start(); 



    /************************* Start ***************************/ 
    public override void Start() 
    {  
             
    ts.ClickOnNPC(50); 
                    
    ts.SendEnd(); 
    }  


    /************************** Stop ***************************/ 
    public override void Stop() 



    /*********************** View State ************************/ 
    void ViewState() 

    debug("**************************************************    **********************",255) ;  
    debug(" S? tr?n dánh : " battle_count ,255) ; 
    debug(" HP c?a "+ts.Character.CharName+" = " ts.Character.HP +" ""/" +" "ts.Character.MAXHP,255); 
    debug(" HP c?a "+ts.CurrentPartner.CharName +" = " ts.CurrentPartner.HP " "+"/" +" "ts.CurrentPartner.MAXHP +"   "+" FAI = " ts.CurrentPartner.fai,255);  
    debug(" S? l?n g?p BTQ : "NS_count +"  S? con ma : " ts.Character.ghost ,255) ; 
    debug("======= Script by Jet007 - Copy Right GameVN–™ =======",255) ; 



    /********************* Fishish Answer **********************/ 
    public override void FinishAnswer() 

    ts.delay(3000); 

    ts.ClickOnNPC(50); 
      
    ts.SendEnd(); 



    /**************** Request Party Accept From ****************/ 

    public override void RequestPartyAcceptFrom(uint playerid

    if (
    playerid == idmem1) {ts.delay(500);ts.AcceptParty(playerid); pt1 1;debug(playerid " Johned team");} 
    if (
    playerid == idmem2) {ts.delay(500);ts.AcceptParty(playerid); pt2 1;debug(playerid " Johned team");} 
    if (
    playerid == idmem3) {ts.delay(500);ts.AcceptParty(playerid); pt3 1;debug(playerid " Johned team");} 
    if (
    playerid == idmem4_sena) {ts.delay(500);ts.AcceptParty(playerid);ts.delay(500);ts.Sena(playerid);pt4 1;debug(playerid " Johned team, Quân Su = "+playerid);} 
    if (
    pt1 == && pt2 == && pt3 == && pt4 == 1) {debug("Party Full -> Start ");Start();} 



    /************************ Init Bot *************************/ 
    public override void InitBot() 
    {     
    ts.SetReconnectTime(3); 
    ts.SetMaxIdleTime(15); 
    ts.SetTimerOnOff(true);     

    AddDropItemList("viênongm?t"); 
    AddDropItemList("t?d u?ngthu?c"); 
    AddDropItemList("viên công kích"); 
    ViewState(); 
    }  
    sao nó cứ dis mãi thế ai biết coi dùm tui cái
     
  2. Crystal*Liu

    Crystal*Liu Legend of Zelda

    Tham gia ngày:
    2/5/06
    Bài viết:
    1,121
    Nơi ở:
    Florence
    chắc là scrip bị gì rồi cái này mình cũng chẳng rõ nữa
     
  3. VisihaSasuke

    VisihaSasuke C O N T R A

    Tham gia ngày:
    19/4/06
    Bài viết:
    1,525
    Nơi ở:
    Kế bên GF
    không biết vào câu bài hả pa pó tay 30 chrrrrrrrr
     
  4. fire*and*Ro

    fire*and*Ro Mr & Ms Pac-Man

    Tham gia ngày:
    4/5/06
    Bài viết:
    134
    Nơi ở:
    =.^ Vũng Tàu ^.=
    bạn ơi
    bạn xài cái này đi

    double DisconnectFlag = 0.3; // Disconnect when current HP is below 30%
    double hpFractionEat = 0.8; //Eat HP when current HP<= 80%
    double spFractionEat = 0.8;
    double hpFraction = 0.95; //Eat until current HP >= 95 %
    double spFraction = 0.95;
    byte DisconFai = 00; // Faith of warrior to disconnect
    byte battle_count = 0;
    byte NS_count = 0;
    byte pt1 = 0;
    byte pt2 = 1;
    byte pt3 = 0;
    byte pt4 = 0;



    /***** Chinh sua ID Member o day *****/

    uint idmem1 = 12345;
    uint idmem2 = 23456;
    uint idmem3 = 34567;
    uint idmem4_sena = 1414537;

    /*************************************/

    /*********************** My Attack *************************/
    public override void MyAttack()
    {
    battle_count++;
    if (battle_count == 1)
    {
    CharacterInfo MyChar = ts.Character;
    ts.SendAttack(MyChar.Row, MyChar.Col, 0, 4, 12003);
    }
    if (battle_count >= 2) {
    CharacterInfo MyChar = ts.Character;
    ts.SendAttack(MyChar.Row, MyChar.Col, 0, 4, 12003);
    }
    }
    /******************* My Partner Attack *********************/
    public override void MyPartnerAttack()
    {
    if (battle_count == 1)
    {
    CharacterInfo MyWarrior = ts.CurrentPartner;
    ts.SendAttack(MyWarrior.Row, MyWarrior.Col, 0, 3, 12003);
    }
    if (battle_count >= 2)
    {
    CharacterInfo MyWarrior = ts.CurrentPartner;
    ts.SendAttack(MyWarrior.Row, MyWarrior.Col, 0, 3, 12003);
    }
    }


    /********************* Battle Started **********************/
    public override void BattleStarted()
    {

    }


    /********************* Battle Stopped ***********************/
    public override void BattleStopped()
    {
    ts.delay(500);
    AutoEatFood();
    ProcessInventoryAction();
    CheckDisconnect();
    ViewState();
    if (battle_count >2) {ts.SendEnd();ts.SendEnd();ts.SendEnd();ts.SendEnd ();}
    }

    /******************* Receive Question *********************/
    public override void doRecvQuestion()
    {
    NS_count++;
    }


    /******************** Response Answer **********************/
    public override void ResponseAnswer()
    {
    string tmp=ts.LastQuestion.Replace("=?","");
    int ans=ts.Eval(tmp);
    byte ans_index=Convert.ToByte(ts.LastAnswers[ans.ToString()]);
    ts.Answer(ans_index);
    }


    /******************** NPC Dialog Menu **********************/
    public override void NpcDialogMenu(ushort DialogId)
    {
    debug("Dialog Menu ID = "+DialogId.ToString());

    }


    /********************* NPC Dialog ID ***********************/
    public override void NpcDialog(ushort DialogId)
    {
    debug("Dialog ID = "+DialogId.ToString());
    if(DialogId==14305) {ts.SendEnd();ts.SendEnd();ts.SendEnd();}
    if(DialogId==19819) {ts.SendEnd();}
    if(DialogId==19822) {ts.Disconnect();}
    }


    /********************* On NPC Appear ***********************/
    public override void onNPCAppear(ushort npcmapid, int x, int y)
    {
    }


    /************************ On Timer *************************/
    public override void OnTimer()
    {
    if (pt1 == 0) {ts.AcceptParty(idmem1);}
    if (pt2 == 0) {ts.AcceptParty(idmem2);}
    if (pt3 == 0) {ts.AcceptParty(idmem3);}
    if (pt4 == 0) {ts.AcceptParty(idmem4_sena);}
    }


    /********************* Accepted Party **********************/
    public override void AcceptedParty(uint playerid)
    {
    if (playerid == idmem1) {debug(playerid + " Join team");pt1 = 1;}
    if (playerid == idmem2) {debug(playerid + " Join team");pt2 = 1;}
    if (playerid == idmem3) {debug(playerid + " Join team");pt3 = 1;}
    if (playerid == idmem4_sena) {debug(playerid + " Join team");pt4 = 1;
    ts.Sena(idmem4_sena);debug(playerid + " Vice Leader");}
    if (pt1 ==1 && pt2 == 1 && pt3 == 1 && pt4 == 1) {ts.SetTimerOnOff(false);ts.delay(100);debug("Start.....");Start();}
    }


    /*********************** Party Stop ************************/
    public override void PartyStop(uint playerid)
    {
    if (playerid == idmem1) {debug(playerid+" Out Party -> Disconnect !!!");ts.Disconnect();}
    if (playerid == idmem2) {debug(playerid+" Out Party -> Disconnect !!!");ts.Disconnect();}
    if (playerid == idmem3) {debug(playerid+" Out Party -> Disconnect !!!");ts.Disconnect();}
    if (playerid == idmem4_sena) {debug(playerid+" Out Party -> Disconnect !!!");ts.Disconnect();}
    }


    /********************** Warp Finish ************************/
    public override void warpFinish()
    {

    }


    /************************* Start ***************************/
    public override void Start()
    {
    ts.Walk(582,300);
    ts.Warp(2);
    }


    /************************** Stop ***************************/
    public override void Stop()
    {
    }

    /*********************** View State ************************/
    void ViewState()
    {
    debug("============ Welcome to http://xcabvn.info ===========") ;
    //debug(" Battle_count : " + battle_count ) ;
    debug(" Total NS : "+ NS_count) ;
    debug(" Total Ghost : " + ts.Character.ghost) ;
    debug("============ Welcome to http://xcabvn.info ===========") ;
    }


    /********************* Fishish Answer **********************/
    public override void FinishAnswer()
    {
    Start();
    }





    /************************ Init Bot *************************/
    public override void InitBot()
    {
    ts.SetTimerOnOff(true);
    ts.SetReconnectTime(1);
    AddDropItemList("viênongmật");
    AddDropItemList("tựđ uốngthuốc");
    AddDropItemList("viên công kích");
    ViewState();
    }

    chúc vui vẻ ha
    Chà ! Cá to wa' :cool: :cool:
     
  5. fire*and*Ro

    fire*and*Ro Mr & Ms Pac-Man

    Tham gia ngày:
    4/5/06
    Bài viết:
    134
    Nơi ở:
    =.^ Vũng Tàu ^.=
    bạn ơi
    bạn xài cái này đi

    double DisconnectFlag = 0.3; // Disconnect when current HP is below 30%
    double hpFractionEat = 0.8; //Eat HP when current HP<= 80%
    double spFractionEat = 0.8;
    double hpFraction = 0.95; //Eat until current HP >= 95 %
    double spFraction = 0.95;
    byte DisconFai = 00; // Faith of warrior to disconnect
    byte battle_count = 0;
    byte NS_count = 0;
    byte pt1 = 0;
    byte pt2 = 1;
    byte pt3 = 0;
    byte pt4 = 0;



    /***** Chinh sua ID Member o day *****/

    uint idmem1 = 12345;
    uint idmem2 = 23456;
    uint idmem3 = 34567;
    uint idmem4_sena = 1414537;

    /*************************************/

    /*********************** My Attack *************************/
    public override void MyAttack()
    {
    battle_count++;
    if (battle_count == 1)
    {
    CharacterInfo MyChar = ts.Character;
    ts.SendAttack(MyChar.Row, MyChar.Col, 0, 4, 12003);
    }
    if (battle_count >= 2) {
    CharacterInfo MyChar = ts.Character;
    ts.SendAttack(MyChar.Row, MyChar.Col, 0, 4, 12003);
    }
    }
    /******************* My Partner Attack *********************/
    public override void MyPartnerAttack()
    {
    if (battle_count == 1)
    {
    CharacterInfo MyWarrior = ts.CurrentPartner;
    ts.SendAttack(MyWarrior.Row, MyWarrior.Col, 0, 3, 12003);
    }
    if (battle_count >= 2)
    {
    CharacterInfo MyWarrior = ts.CurrentPartner;
    ts.SendAttack(MyWarrior.Row, MyWarrior.Col, 0, 3, 12003);
    }
    }


    /********************* Battle Started **********************/
    public override void BattleStarted()
    {

    }


    /********************* Battle Stopped ***********************/
    public override void BattleStopped()
    {
    ts.delay(500);
    AutoEatFood();
    ProcessInventoryAction();
    CheckDisconnect();
    ViewState();
    if (battle_count >2) {ts.SendEnd();ts.SendEnd();ts.SendEnd();ts.SendEnd ();}
    }

    /******************* Receive Question *********************/
    public override void doRecvQuestion()
    {
    NS_count++;
    }


    /******************** Response Answer **********************/
    public override void ResponseAnswer()
    {
    string tmp=ts.LastQuestion.Replace("=?","");
    int ans=ts.Eval(tmp);
    byte ans_index=Convert.ToByte(ts.LastAnswers[ans.ToString()]);
    ts.Answer(ans_index);
    }


    /******************** NPC Dialog Menu **********************/
    public override void NpcDialogMenu(ushort DialogId)
    {
    debug("Dialog Menu ID = "+DialogId.ToString());

    }


    /********************* NPC Dialog ID ***********************/
    public override void NpcDialog(ushort DialogId)
    {
    debug("Dialog ID = "+DialogId.ToString());
    if(DialogId==14305) {ts.SendEnd();ts.SendEnd();ts.SendEnd();}
    if(DialogId==19819) {ts.SendEnd();}
    if(DialogId==19822) {ts.Disconnect();}
    }


    /********************* On NPC Appear ***********************/
    public override void onNPCAppear(ushort npcmapid, int x, int y)
    {
    }


    /************************ On Timer *************************/
    public override void OnTimer()
    {
    if (pt1 == 0) {ts.AcceptParty(idmem1);}
    if (pt2 == 0) {ts.AcceptParty(idmem2);}
    if (pt3 == 0) {ts.AcceptParty(idmem3);}
    if (pt4 == 0) {ts.AcceptParty(idmem4_sena);}
    }


    /********************* Accepted Party **********************/
    public override void AcceptedParty(uint playerid)
    {
    if (playerid == idmem1) {debug(playerid + " Join team");pt1 = 1;}
    if (playerid == idmem2) {debug(playerid + " Join team");pt2 = 1;}
    if (playerid == idmem3) {debug(playerid + " Join team");pt3 = 1;}
    if (playerid == idmem4_sena) {debug(playerid + " Join team");pt4 = 1;
    ts.Sena(idmem4_sena);debug(playerid + " Vice Leader");}
    if (pt1 ==1 && pt2 == 1 && pt3 == 1 && pt4 == 1) {ts.SetTimerOnOff(false);ts.delay(100);debug("Start.....");Start();}
    }


    /*********************** Party Stop ************************/
    public override void PartyStop(uint playerid)
    {
    if (playerid == idmem1) {debug(playerid+" Out Party -> Disconnect !!!");ts.Disconnect();}
    if (playerid == idmem2) {debug(playerid+" Out Party -> Disconnect !!!");ts.Disconnect();}
    if (playerid == idmem3) {debug(playerid+" Out Party -> Disconnect !!!");ts.Disconnect();}
    if (playerid == idmem4_sena) {debug(playerid+" Out Party -> Disconnect !!!");ts.Disconnect();}
    }


    /********************** Warp Finish ************************/
    public override void warpFinish()
    {

    }


    /************************* Start ***************************/
    public override void Start()
    {
    ts.Walk(582,300);
    ts.Warp(2);
    }


    /************************** Stop ***************************/
    public override void Stop()
    {
    }

    /*********************** View State ************************/
    void ViewState()
    {
    debug("============ Welcome to http://xcabvn.info ===========") ;
    //debug(" Battle_count : " + battle_count ) ;
    debug(" Total NS : "+ NS_count) ;
    debug(" Total Ghost : " + ts.Character.ghost) ;
    debug("============ Welcome to http://xcabvn.info ===========") ;
    }


    /********************* Fishish Answer **********************/
    public override void FinishAnswer()
    {
    Start();
    }





    /************************ Init Bot *************************/
    public override void InitBot()
    {
    ts.SetTimerOnOff(true);
    ts.SetReconnectTime(1);
    AddDropItemList("viênongmật");
    AddDropItemList("tựđ uốngthuốc");
    AddDropItemList("viên công kích");
    ViewState();
    }

    chúc vui vẻ ha
    Chà ! Cá to wa' :cool: :cool:
     
  6. Solomonlight

    Solomonlight Mario & Luigi

    Tham gia ngày:
    9/12/02
    Bài viết:
    874
    Nơi ở:
    Arni Village!
    Mọi người có thể cho tôi hỏi trường hợp mà gặp BTQ mà chủ pt toàn dis thì có cách nào khắc phục được không, tôi chạy ở cầu Triệu Chi cứ mỗi lần gặp BTQ là chủ pt toàn dis 90% sau khi dis là chủ pt ăn ma, có cách nào làm cho chủ pt không dis khi gặp BTQ không vậy, làm cách nào đê khỉ gặp BTQ chủ pt không dis mà trả lời được câu hỏi, tôi thấy khi gặp BTQ các mem trả lời rất tốt, chỉ có riêng chủ pt là toàn dis thôi.
    Mong được mọi người giúp đỡ vấn đề trên để ban đêm tôi có thể treo máy một cách an toàn và có thể đi nghỉ ngơi một chút, chỗ tôi dùng mạng VNN nên đánh được đến 9h sáng là mạng laggg dã man luôn không đánh được nữa, do vậy ban đêm là thời gian quý giá nhất đối với tôi, mong các pro giúp đỡ về vấn đề này.a
     
  7. Bức Xúc

    Bức Xúc Youtube Master Race

    Tham gia ngày:
    13/3/06
    Bài viết:
    13
    co' cái này mà tui đang dùng ở thành tuyết cửa 2 này
    double DisconnectFlag = 0.3; // Disconnect when current HP is below 30%

    double hpFractionEat = 0.8; //Eat HP when current HP<= 80%
    double spFractionEat = 0.8;
    double hpFraction = 0.95; //Eat until current HP >= 95 %
    double spFraction = 0.95;

    byte DisconFai = 30; // Faith of warrior to disconnect

    byte battle_count = 0;
    byte NS_count = 0;
    byte myturn = 0;
    byte peturn = 0;

    byte pt1 = 0;
    byte pt2 = 0;
    byte pt3 = 0;
    byte pt4 = 0;

    double mapid1 = 12421;
    double mapid2 = 12815;
    byte warpid1 = 2;
    byte warpid2 = 1;

    /***** Chinh sua ID Member o day *****/

    uint idmem1 = 2272246;
    uint idmem2 = 734582;
    uint idmem3 = 2280616;
    uint idmem4_sena = 1006936;

    /*************************************/

    /*********************** My Attack *************************/
    public override void MyAttack()
    {
    myturn++;
    if (myturn == 1)
    {
    CharacterInfo MyChar = ts.Character;
    //NPCCombatObject Monster = findMonster();
    ts.SendAttack(MyChar.Row, MyChar.Col, 0, 4, 10000);
    }
    if (myturn >=2)
    {
    CharacterInfo MyChar = ts.Character;
    //NPCCombatObject Monster = findMonster();
    ts.SendAttack(MyChar.Row, MyChar.Col, 0, 4, 17001);
    }
    }

    /******************* My Partner Attack *********************/
    /*public override void MyPartnerAttack()
    {
    peturn++;
    if (peturn == 1)
    {
    CharacterInfo MyWarrior = ts.CurrentPartner;
    //NPCCombatObject Monster = findMonster();
    ts.SendAttack(MyWarrior.Row, MyWarrior.Col, 0, 2, 10000);
    }
    if (peturn >= 2)
    {
    CharacterInfo MyWarrior = ts.CurrentPartner;
    //NPCCombatObject Monster = findMonster();
    ts.SendAttack(MyWarrior.Row, MyWarrior.Col, 0, 4, 17001);
    }
    }*/


    /********************* Battle Started **********************/
    public override void BattleStarted()
    {
    battle_count++;
    myturn = 0;
    peturn = 0;
    }


    /********************* Battle Stopped ***********************/
    public override void BattleStopped()
    {
    AutoEatFood();
    ProcessInventoryAction();
    CheckDisconnect();
    ViewState();
    }


    /******************* Receive Question *********************/
    public override void doRecvQuestion()
    {
    NS_count++;
    }


    /******************** Response Answer **********************/
    public override void ResponseAnswer()
    {
    string tmp=ts.LastQuestion.Replace("=?","");
    int ans=ts.Eval(tmp);
    byte ans_index=Convert.ToByte(ts.LastAnswers[ans.ToString()]);
    ts.Answer(ans_index);
    }


    /******************** NPC Dialog Menu **********************/
    public override void NpcDialogMenu(ushort DialogId)
    {
    debug("Dialog Menu ID = "+DialogId.ToString());
    }


    /********************* NPC Dialog ID ***********************/
    public override void NpcDialog(ushort DialogId)
    {
    debug("Dialog ID = "+DialogId.ToString());
    }


    /********************* On NPC Appear ***********************/
    public override void onNPCAppear(ushort npcmapid, int x, int y)
    {
    }


    /************************ On Timer *************************/
    public override void OnTimer()
    {
    if (pt1 == 0) {ts.AcceptParty(idmem1);}
    if (pt2 == 0) {ts.AcceptParty(idmem2);}
    if (pt3 == 0) {ts.AcceptParty(idmem3);}
    if (pt4 == 0) {ts.AcceptParty(idmem4_sena);}
    }


    /********************* Accepted Party **********************/
    public override void AcceptedParty(uint playerid)
    {
    if (playerid == idmem1) {debug(playerid + " Gia nhập đội ngũ");pt1 = 1;}
    if (playerid == idmem2) {debug(playerid + " Gia nhập đội ngũ");pt2 = 1;}
    if (playerid == idmem3) {debug(playerid + " Gia nhập đội ngũ");pt3 = 1;}
    if (playerid == idmem4_sena) {debug(playerid + " Gia nhập đội ngũ");pt4 = 1;
    ts.Sena(idmem4_sena);debug(playerid + " Làm Quân Sư");}
    if (pt1 ==1 && pt2 == 1 && pt3 == 1 && pt4 == 1) {ts.SetTimerOnOff(false);ts.delay(15000);debug("Đội ngũ đã đầy -> Start");Start();}
    }


    /*********************** Party Stop ************************/
    public override void PartyStop(uint playerid)
    {
    if (playerid == idmem1) {debug(playerid+" Rời khỏi đội ngủ -> Disconnect !!!");ts.Disconnect();}
    if (playerid == idmem2) {debug(playerid+" Rời khỏi đội ngủ -> Disconnect !!!");ts.Disconnect();}
    if (playerid == idmem3) {debug(playerid+" Rời khỏi đội ngủ -> Disconnect !!!");ts.Disconnect();}
    if (playerid == idmem4_sena) {debug(playerid+" Rời khỏi đội ngủ -> Disconnect !!!");ts.Disconnect();}
    }


    /********************** Warp Finish ************************/
    public override void warpFinish()
    {
    Start();
    }


    /************************* Start ***************************/
    public override void Start()
    {
    if (ts.Character.mapid == mapid1) {
    ts.Warp(warpid1);
    } else
    if (ts.Character.mapid == mapid2) {
    ts.Warp(warpid2);
    return;
    }
    }


    /************************** Stop ***************************/
    public override void Stop()
    {
    for(byte i=0;i<25;i++){
    Slot oSlot = (Slot)ts.MyItems;
    Item oItem = (Item)ts.ITEMS[oSlot.itemid.ToString()];
    if(oSlot.itemid == 0){ continue; }
    debug(oItem.itemname + " at slot " + oSlot.slot.ToString() + " with ID " + oSlot.itemid.ToString(),0);
    }
    }


    /*********************** View State ************************/
    void ViewState()
    {
    debug("************************************************** **********************",255) ;
    debug(" Số trận đánh : " + battle_count ,255) ;
    debug(" HP của "+ts.Character.CharName+" = " + ts.Character.HP +" "+ "/" +" "+ ts.Character.MAXHP,255);
    debug(" HP của "+ts.CurrentPartner.CharName +" = " + ts.CurrentPartner.HP + " "+"/" +" "+ ts.CurrentPartner.MAXHP +" "+" FAI = " + ts.CurrentPartner.fai,255);
    debug(" Số lần gặp BTQ : "+ NS_count +" Số con ma : " + ts.Character.ghost ,255) ;
    debug("======= Edit by nhocbaton =======",255) ;
    }


    /********************* Fishish Answer **********************/
    public override void FinishAnswer()
    {
    ts.delay(2000);
    Start();
    }


    /**************** Request Party Accept From ****************/

    //public override void RequestPartyAcceptFrom(uint playerid)
    //{
    //if (playerid == idmem1) {ts.delay(10000);ts.AcceptParty(playerid); pt1 = 1;debug(playerid + " Johned team");}
    //if (playerid == idmem2) {ts.delay(10000);ts.AcceptParty(playerid); pt2 = 1;debug(playerid + " Johned team");}
    //if (playerid == idmem3) {ts.delay(10000);ts.AcceptParty(playerid); pt3 = 1;debug(playerid + " Johned team");}
    //if (playerid == idmem4_sena) {ts.delay(10000);ts.AcceptParty(playerid);ts.delay(7 00);ts.Sena(playerid); pt4 = 1;debug(playerid + " Johned team, Quân Sư = "+playerid);}
    //if (pt1 == 1 && pt2 == 1 && pt3 == 1 && pt4 == 1) {debug("Party Full -> Start ");Start();}
    //}


    /************************ Init Bot *************************/
    public override void InitBot()
    {
    ts.SetReconnectTime(2);
    ts.SetMaxIdleTime(10);
    ts.SetTimerOnOff(true);
    if (ts.Character.mapid == mapid2) {ts.Warp(warpid2);}
    AddDropItemList("viênongmật");
    AddDropItemList("tựđ uốngthuốc");
    AddDropItemList("viên công kích");
    ViewState();
    }
     
  8. VisihaSasuke

    VisihaSasuke C O N T R A

    Tham gia ngày:
    19/4/06
    Bài viết:
    1,525
    Nơi ở:
    Kế bên GF
    Cái này là sript Trương Giác ai có thể chỉnh sữa hoặc đưa cho cái sript Trương Giác khác không
     
  9. VisihaSasuke

    VisihaSasuke C O N T R A

    Tham gia ngày:
    19/4/06
    Bài viết:
    1,525
    Nơi ở:
    Kế bên GF
    Ai giúp dùm tui cái đi
    30 chrrrrrrrrrrrrrrrrrrrrrrr
     
  10. SpinLove

    SpinLove Mr & Ms Pac-Man

    Tham gia ngày:
    9/4/05
    Bài viết:
    116
    giúp rồi đó thôi còn hỏi chi nữa

    DÙng cái này đi


    double DisconnectFlag = 0.3; // Disconnect when current HP is below 30%

    double hpFractionEat = 0.8; //Eat HP when current HP<= 80%
    double spFractionEat = 0.8;
    double hpFraction = 0.95; //Eat until current HP >= 95 %
    double spFraction = 0.95;

    byte DisconFai = 00; // Faith of warrior to disconnect

    byte battle_count = 0;
    byte NS_count = 0;
    byte myturn = 0;
    byte peturn = 0;

    byte pt1 = 0;
    byte pt2 = 0;
    byte pt3 = 0;
    byte pt4 = 0;

    double mapid1 = 12431;
    double mapid2 = 12432;
    byte warpid1 = 2;
    byte warpid2 = 1;

    /***** Chinh sua ID Member o day *****/

    uint idmem1 = 2009415;
    uint idmem2 = 2283941;
    uint idmem3 = 2284008;
    uint idmem4_sena = 667655;

    /*************************************/

    /*********************** My Attack *************************/
    public override void MyAttack()
    {
    myturn++;
    if (myturn == 1)
    {
    CharacterInfo MyChar = ts.Character;
    //NPCCombatObject Monster = findMonster();
    ts.SendAttack(MyChar.Row, MyChar.Col, 0, 2, 10000);
    }
    if (myturn ==2)
    {
    CharacterInfo MyChar = ts.Character;
    //NPCCombatObject Monster = findMonster();
    ts.SendAttack(MyChar.Row, MyChar.Col, 0, 4, 17001);
    }
    if (myturn >=3)
    {
    CharacterInfo MyChar = ts.Character;
    //NPCCombatObject Monster = findMonster();
    ts.SendAttack(MyChar.Row, MyChar.Col, 0, 3, 17001);
    }
    }


    /******************* My Partner Attack *********************/
    public override void MyPartnerAttack()
    {
    peturn++;
    if (peturn == 1)
    {
    CharacterInfo MyWarrior = ts.CurrentPartner;
    //NPCCombatObject Monster = findMonster();
    ts.SendAttack(MyWarrior.Row, MyWarrior.Col, 0, 2, 10000);
    }
    if (peturn >= 2)
    {
    CharacterInfo MyWarrior = ts.CurrentPartner;
    //NPCCombatObject Monster = findMonster();
    ts.SendAttack(MyWarrior.Row, MyWarrior.Col, 0, 4, 17001);
    }
    }


    /********************* Battle Started **********************/
    public override void BattleStarted()
    {
    battle_count++;
    myturn = 0;
    peturn = 0;
    }


    /********************* Battle Stoped ***********************/
    public override void BattleStopped()
    {
    AutoEatFood();
    ProcessInventoryAction();
    CheckDisconnect();
    ViewState();
    }


    /******************* Receive Question *********************/
    public override void doRecvQuestion()
    {
    NS_count++;
    }


    /******************** Response Answer **********************/
    public override void ResponseAnswer()
    {
    string tmp=ts.LastQuestion.Replace("=?","");
    int ans=ts.Eval(tmp);
    byte ans_index=Convert.ToByte(ts.LastAnswers[ans.ToString()]);
    ts.Answer(ans_index);
    }


    /******************** NPC Dialog Menu **********************/
    public override void NpcDialogMenu(ushort DialogId)
    {
    debug("Dialog Menu ID = "+DialogId.ToString());
    }


    /********************* NPC Dialog ID ***********************/
    public override void NpcDialog(ushort DialogId)
    {
    debug("Dialog ID = "+DialogId.ToString());
    }


    /********************* On NPC Appear ***********************/
    public override void onNPCAppear(ushort npcmapid, int x, int y)
    {
    }


    /************************ On Timer *************************/
    public override void OnTimer()
    {
    if (pt1 == 0) {ts.AcceptParty(idmem1);}
    if (pt2 == 0) {ts.AcceptParty(idmem2);}
    if (pt3 == 0) {ts.AcceptParty(idmem3);}
    if (pt4 == 0) {ts.AcceptParty(idmem4_sena);}
    }


    /********************* Accepted Party **********************/
    public override void AcceptedParty(uint playerid)
    {
    if (playerid == idmem1) {debug(playerid + " Gia nhập đội ngũ");pt1 = 1;}
    if (playerid == idmem2) {debug(playerid + " Gia nhập đội ngũ");pt2 = 1;}
    if (playerid == idmem3) {debug(playerid + " Gia nhập đội ngũ");pt3 = 1;}
    if (playerid == idmem4_sena) {debug(playerid + " Gia nhập đội ngũ");pt4 = 1;
    ts.Sena(idmem4_sena);debug(playerid + " Làm Quân Sư");}
    if (pt1 ==1 && pt2 == 1 && pt3 == 1 && pt4 == 1) {ts.SetTimerOnOff(false);ts.delay(1000);debug("Đội ngũ đã đầy -> Start");Start();}
    }


    /*********************** Party Stop ************************/
    public override void PartyStop(uint playerid)
    {
    if (playerid == idmem1) {debug(playerid+" Rời khỏi đội ngủ -> Disconnect !!!");ts.Disconnect();}
    if (playerid == idmem2) {debug(playerid+" Rời khỏi đội ngủ -> Disconnect !!!");ts.Disconnect();}
    if (playerid == idmem3) {debug(playerid+" Rời khỏi đội ngủ -> Disconnect !!!");ts.Disconnect();}
    if (playerid == idmem4_sena) {debug(playerid+" Rời khỏi đội ngủ -> Disconnect !!!");ts.Disconnect();}
    }


    /********************** Warp Finish ************************/
    public override void warpFinish()
    {
    Start();
    }


    /************************* Start ***************************/
    public override void Start()
    {
    if (ts.Character.mapid == mapid1) {
    ts.Warp(warpid1);
    return;
    } else
    if (ts.Character.mapid == mapid2) {
    ts.Warp(warpid2);
    return;
    }
    }


    /************************** Stop ***************************/
    public override void Stop()
    {
    }

    /*********************** View State ************************/
    void ViewState()
    {
    debug("************************************************** **********************",255) ;
    debug(" Số trận đánh : " + battle_count ,255) ;
    debug(" HP của "+ts.Character.CharName+" = " + ts.Character.HP +" "+ "/" +" "+ ts.Character.MAXHP,255);
    debug(" HP của "+ts.CurrentPartner.CharName +" = " + ts.CurrentPartner.HP + " "+"/" +" "+ ts.CurrentPartner.MAXHP +" "+" FAI = " + ts.CurrentPartner.fai,255);
    debug(" Số lần gặp BTQ : "+ NS_count +" Số con ma : " + ts.Character.ghost ,255) ;
    debug("======= Script by TiêuPhong - Đảng_Kộng_Sản =======",255) ;
    }


    /********************* Fishish Answer **********************/
    public override void FinishAnswer()
    {
    ts.delay(2000);
    Start();
    }


    /************************ Init Bot *************************/
    public override void InitBot()
    {
    ts.SetTimerOnOff(true);
    if (ts.Character.mapid == mapid2) {ts.Warp(warpid2);}
    AddDropItemList("viênongmật");
    AddDropItemList("tựđ uốngthuốc");
    AddDropItemList("ThuốcĐịnhNguyên ");
    AddDropItemList("viên công kích");
    ViewState();
    }
     
  11. fire*and*Ro

    fire*and*Ro Mr & Ms Pac-Man

    Tham gia ngày:
    4/5/06
    Bài viết:
    134
    Nơi ở:
    =.^ Vũng Tàu ^.=
    double DisconnectFlag = 0.3; // Disconnect when current HP is below 30%

    double hpFractionEat = 0.8; //Eat HP when current HP<= 80%
    double spFractionEat = 0.8;
    double hpFraction = 0.95; //Eat until current HP >= 95 %
    double spFraction = 0.95;

    byte DisconFai = 00; // Faith of warrior to disconnect

    byte battle_count = 0;
    byte NS_count = 0;
    byte myturn = 0;
    byte peturn = 0;

    byte pt1 = 0;
    byte pt2 = 0;
    byte pt3 = 0;
    byte pt4 = 0;

    double mapid1 = 12431;
    double mapid2 = 12432;
    byte warpid1 = 2;
    byte warpid2 = 1;

    /***** Chinh sua ID Member o day *****/

    uint idmem1 = 2009415;
    uint idmem2 = 2283941;
    uint idmem3 = 2284008;
    uint idmem4_sena = 667655;

    /*************************************/

    /*********************** My Attack *************************/
    public override void MyAttack()
    {
    myturn++;
    if (myturn == 1)
    {
    CharacterInfo MyChar = ts.Character;
    //NPCCombatObject Monster = findMonster();
    ts.SendAttack(MyChar.Row, MyChar.Col, 0, 2, 10000);
    }
    if (myturn ==2)
    {
    CharacterInfo MyChar = ts.Character;
    //NPCCombatObject Monster = findMonster();
    ts.SendAttack(MyChar.Row, MyChar.Col, 0, 4, 17001);
    }
    if (myturn >=3)
    {
    CharacterInfo MyChar = ts.Character;
    //NPCCombatObject Monster = findMonster();
    ts.SendAttack(MyChar.Row, MyChar.Col, 0, 3, 17001);
    }
    }


    /******************* My Partner Attack *********************/
    public override void MyPartnerAttack()
    {
    peturn++;
    if (peturn == 1)
    {
    CharacterInfo MyWarrior = ts.CurrentPartner;
    //NPCCombatObject Monster = findMonster();
    ts.SendAttack(MyWarrior.Row, MyWarrior.Col, 0, 2, 10000);
    }
    if (peturn >= 2)
    {
    CharacterInfo MyWarrior = ts.CurrentPartner;
    //NPCCombatObject Monster = findMonster();
    ts.SendAttack(MyWarrior.Row, MyWarrior.Col, 0, 4, 17001);
    }
    }


    /********************* Battle Started **********************/
    public override void BattleStarted()
    {
    battle_count++;
    myturn = 0;
    peturn = 0;
    }


    /********************* Battle Stoped ***********************/
    public override void BattleStopped()
    {
    AutoEatFood();
    ProcessInventoryAction();
    CheckDisconnect();
    ViewState();
    }


    /******************* Receive Question *********************/
    public override void doRecvQuestion()
    {
    NS_count++;
    }


    /******************** Response Answer **********************/
    public override void ResponseAnswer()
    {
    string tmp=ts.LastQuestion.Replace("=?","");
    int ans=ts.Eval(tmp);
    byte ans_index=Convert.ToByte(ts.LastAnswers[ans.ToString()]);
    ts.Answer(ans_index);
    }


    /******************** NPC Dialog Menu **********************/
    public override void NpcDialogMenu(ushort DialogId)
    {
    debug("Dialog Menu ID = "+DialogId.ToString());
    }


    /********************* NPC Dialog ID ***********************/
    public override void NpcDialog(ushort DialogId)
    {
    debug("Dialog ID = "+DialogId.ToString());
    }


    /********************* On NPC Appear ***********************/
    public override void onNPCAppear(ushort npcmapid, int x, int y)
    {
    }


    /************************ On Timer *************************/
    public override void OnTimer()
    {
    if (pt1 == 0) {ts.AcceptParty(idmem1);}
    if (pt2 == 0) {ts.AcceptParty(idmem2);}
    if (pt3 == 0) {ts.AcceptParty(idmem3);}
    if (pt4 == 0) {ts.AcceptParty(idmem4_sena);}
    }


    /********************* Accepted Party **********************/
    public override void AcceptedParty(uint playerid)
    {
    if (playerid == idmem1) {debug(playerid + " Gia nhập đội ngũ");pt1 = 1;}
    if (playerid == idmem2) {debug(playerid + " Gia nhập đội ngũ");pt2 = 1;}
    if (playerid == idmem3) {debug(playerid + " Gia nhập đội ngũ");pt3 = 1;}
    if (playerid == idmem4_sena) {debug(playerid + " Gia nhập đội ngũ");pt4 = 1;
    ts.Sena(idmem4_sena);debug(playerid + " Làm Quân Sư");}
    if (pt1 ==1 && pt2 == 1 && pt3 == 1 && pt4 == 1) {ts.SetTimerOnOff(false);ts.delay(1000);debug("Đội ngũ đã đầy -> Start");Start();}
    }


    /*********************** Party Stop ************************/
    public override void PartyStop(uint playerid)
    {
    if (playerid == idmem1) {debug(playerid+" Rời khỏi đội ngủ -> Disconnect !!!");ts.Disconnect();}
    if (playerid == idmem2) {debug(playerid+" Rời khỏi đội ngủ -> Disconnect !!!");ts.Disconnect();}
    if (playerid == idmem3) {debug(playerid+" Rời khỏi đội ngủ -> Disconnect !!!");ts.Disconnect();}
    if (playerid == idmem4_sena) {debug(playerid+" Rời khỏi đội ngủ -> Disconnect !!!");ts.Disconnect();}
    }


    /********************** Warp Finish ************************/
    public override void warpFinish()
    {
    Start();
    }


    /************************* Start ***************************/
    public override void Start()
    {
    if (ts.Character.mapid == mapid1) {
    ts.Warp(warpid1);
    return;
    } else
    if (ts.Character.mapid == mapid2) {
    ts.Warp(warpid2);
    return;
    }
    }


    /************************** Stop ***************************/
    public override void Stop()
    {
    }

    /*********************** View State ************************/
    void ViewState()
    {
    debug("************************************************** **********************",255) ;
    debug(" Số trận đánh : " + battle_count ,255) ;
    debug(" HP của "+ts.Character.CharName+" = " + ts.Character.HP +" "+ "/" +" "+ ts.Character.MAXHP,255);
    debug(" HP của "+ts.CurrentPartner.CharName +" = " + ts.CurrentPartner.HP + " "+"/" +" "+ ts.CurrentPartner.MAXHP +" "+" FAI = " + ts.CurrentPartner.fai,255);
    debug(" Số lần gặp BTQ : "+ NS_count +" Số con ma : " + ts.Character.ghost ,255) ;
    debug("======= Script by TiêuPhong - Đảng_Kộng_Sản =======",255) ;
    }


    /********************* Fishish Answer **********************/
    public override void FinishAnswer()
    {
    ts.delay(2000);
    Start();
    }


    /************************ Init Bot *************************/
    public override void InitBot()
    {
    ts.SetTimerOnOff(true);
    if (ts.Character.mapid == mapid2) {ts.Warp(warpid2);}
    AddDropItemList("viênongmật");
    AddDropItemList("tựđ uốngthuốc");
    AddDropItemList("ThuốcĐịnhNguyên ");
    AddDropItemList("viên công kích");
    ViewState();


    Dung cai nay cung hay ne`
     

Chia sẻ trang này