Register for your free account! | Forgot your password?

Go Back   elitepvpers > Popular Games > World of Warcraft > WoW Bots
You last visited: Today at 18:54

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



HB Plugin Abändern, wie?

Discussion on HB Plugin Abändern, wie? within the WoW Bots forum part of the World of Warcraft category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Sep 2010
Posts: 106
Received Thanks: 5
HB Plugin Abändern, wie?

Hallo, ich möchte ein HB Plugin abändern, es handelt sich um das MobileBanking Plugin, das zahlt das Gold vom Char in die Gbank, sodass der Char 100G übrig hat. Funktioniert prima, aber mir ist es zu wenig was er übrig lässt, es sollen 500 Gold sein statt 100 Gold die er behält.

Nachfolgend der Code kopiert mit Notepad++

Seh ich das richtig das ich diese Zeile nur ändern muss?

Code:
                MobileBank.Interact();

                var depositCopperAmount = Me.Copper - 1000000;
                var depositGoldAmount = Me.Gold - 100;
Code:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Windows.Media;
using Styx;
using Styx.Common;
using Styx.CommonBot;
using Styx.Pathing;
using Styx.Plugins;
using Styx.WoWInternals;
using Styx.WoWInternals.WoWObjects;


namespace MobileBanking {
    public class MobileBanking : HBPlugin {

        // ===========================================================
        // Constants
        // ===========================================================

        // ===========================================================
        // Fields
        // ===========================================================

        public static LocalPlayer Me = StyxWoW.Me;
        public static WoWObject MobileBank;

        // ===========================================================
        // Constructors
        // ===========================================================

        // ===========================================================
        // Getter & Setter
        // ===========================================================

        // ===========================================================
        // Methods for/from SuperClass/Interfaces
        // ===========================================================

        public override string Name {
            get { return "Mobile Banking"; }
        }

        public override string Author {
            get { return "Wigglez"; }
        }

        public override Version Version {
            get { return new Version(1, 0); }
        }

        public override void Initialize() {
            CustomNormalLog("Initialization complete.");

            base.Initialize();
        }

        public override void Dispose() {
            CustomNormalLog("Shutdown complete.");

            base.Dispose();
        }

        public override void Pulse() {
            if(Me.IsDead) {
                return;
            }

            if(Me.Combat) {
                return;
            }

            if(!IsViable(Me)) {
                return;
            }

            if(Me.Mounted) {
                return;
            }

            if(GetGuildReputation() < 5) {
                return;
            }

            if(Me.GuildLevel < 11) {
                return;
            }

            if(Me.Gold < 500) {
                return;
            }

            if(!HasMobileBanking()) {
                return;
            }



            if(!MobileBankExists()) {
                FindMobileBank();

                if(!CanCastMobileBanking()) {
                    return;
                }

                CastMobileBanking();
            } else {
                if(!MobileBank.WithinInteractRange) {

                    var mobileBankLocation = WoWMovement.CalculatePointFrom(MobileBank.Location, 5f);

                    Navigator.MoveTo(mobileBankLocation);
                }
            
                MobileBank.Interact();

                var depositCopperAmount = Me.Copper - 1000000;
                var depositGoldAmount = Me.Gold - 100;

                DepositGuildBankMoney(depositCopperAmount);

                CustomNormalLog("Deposited " + depositGoldAmount + " gold and closed the bank frame.");

            }
        }

        // ===========================================================
        // Methods
        // ===========================================================

        public void CustomNormalLog(string message, params object[] args) {
            Logging.Write(Colors.DeepSkyBlue, "[Mobile Banking]: " + message, args);
        }

        public static bool IsViable(WoWObject pWoWObject) {
            return (pWoWObject != null) && pWoWObject.IsValid;
        }

        public static bool HasMobileBanking() {
            return SpellManager.HasSpell(83958);
        }

        public static bool CanCastMobileBanking() {
            return SpellManager.CanCast(83958);
        }

        public static void CastMobileBanking() {
            SpellManager.Cast(83958);
        }

        public static void FindMobileBank() {
            MobileBank = ObjectManager.GetObjectsOfTypeFast<WoWObject>().FirstOrDefault(bank => bank.IsValid && bank.Entry == 206602);
        }

        public static bool MobileBankExists() {
            return MobileBank != null;
        }

        public static int GetGuildReputation() {
            var getGuildFactionStanding = GetFactionInfoByID(1168);
            var guildFactionStanding = Convert.ToInt32(getGuildFactionStanding[2]);

            return guildFactionStanding;
        }

        public static void DepositGuildBankMoney(ulong pCopper) {
            Lua.DoString(string.Format("DepositGuildBankMoney({0})", pCopper));
        }

        public static void CloseGuildBankFrame() {
            Lua.DoString("CloseGuildBankFrame()");
        }

        public static List<string> GetFactionInfoByID(int pFactionID) {
            return Lua.GetReturnValues(string.Format("return GetFactionInfoByID({0})", pFactionID));
        }


        // ===========================================================
        // Inner and Anonymous Classes
        // ===========================================================

    }
}
Keeper2o1o is offline  
Old 05/02/2014, 18:32   #2
 
wowtoon's Avatar
 
elite*gold: 0
Join Date: Apr 2011
Posts: 148
Received Thanks: 22
Code:
                var depositCopperAmount = Me.Copper - 1000000;
statt 1000000 einfach 5000000.

sollte alles sein. Falls du den report im log auch richtig haben willst einfach in die zeile darunter statt 100, 500 schreiben.
wowtoon is offline  
Reply


Similar Threads Similar Threads
Portale // Coords // Abändern ..
10/18/2010 - Metin2 Private Server - 5 Replies
Well, Angenommen ich möchte die Coords des Portales das vom Orktal ins ROTE reich führt ändern, sprich, die Coords, die auf Map1 zugewiesen sind. Wie kann ich das ganze machen ? Finde dazu keine Einträge. Grüße !
CONFIG´s Abändern?
08/20/2010 - Metin2 Private Server - 9 Replies
Moinsen ihr lieben mal ne Kleine Frage und zwar hatte ich vor mal meine CONFIG in jedem Game ordner und so ab zu ändern. Nun meine Frage HOSTNAME: first CHANNEL: 1 PORT: 13000 P2P_PORT: ***** DB_PORT: 15001
[How To] Ox-Fragen abändern
10/29/2009 - Metin2 PServer Guides & Strategies - 10 Replies
#Removed aufrgund von pers gründen o_o
Fonts abändern
01/13/2008 - Technical Support - 2 Replies
Clientdaten abändern ?
03/31/2005 - World of Warcraft - 11 Replies
Wollt mal wissen was man alles abändern kann an den Clientinformation . Kann man den Schaden abändern den man an den Mobs macht oder ist das Serverlastig ? Wird sicher vom Server berechnet, aber könnte man nicht die "Schlagfolge" abändern ? Sagen wir ich habe einen Spell A und der braucht 5 Sekunden zum aufladen, kann ich die Client-Informationen nicht so abändern, dass 5 mal der Spell A gecastet wird, ohne aufladen. Sagen wir auf einen Mob 5 mal den Spell A in einer Sekunde. Der Client...



All times are GMT +2. The time now is 18:54.


Powered by vBulletin®
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2024 elitepvpers All Rights Reserved.