Postado Dezembro 23, 2011 13 anos Autor Não to conseguindo... Se eu postar o Codigo do meu projeto inteiro aqui se ajeita pra mim ? Imports Tibia Imports Tibia.Util Imports Tibia.Objects Imports Tibia.Constants Public Class Form2 Public c As Client Dim levelspy As Integer = p.Location.Z Public p As Player End Sub End Class Private Sub Form2_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load c = Form1.ComboBox1.SelectedItem If c.LoggedIn Then p = c.GetPlayer Form1.Hide() Else Me.Hide() MsgBox("Você precisa escolher o seu personagem.") End If End Sub Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click c.Map.FullLightOn() End Sub Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click c.Map.FullLightOff() End Sub Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click If ComboBox1.SelectedItem = "Beggar" Then p.OutfitType = Tibia.Constants.OutfitType.BeggarMale ElseIf ComboBox1.SelectedItem = "Assassin" Then p.OutfitType = Tibia.Constants.OutfitType.AssassinMale End If End Sub Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click If levelspy = 14 Then Else c.Map.LevelSpyOn(levelspy + 1) levelspy = levelspy + 1 End If End Sub Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click If levelspy = 0 Or levelspy = 7 Then Else c.Map.LevelSpyOn(levelspy - 1) levelspy = levelspy - 1 End If End Sub Private Sub Button6_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) c.Map.LevelSpyOff() levelspy = levelspy End Sub Private Sub Button6_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button6.Click c.Map.LevelSpyOff() levelspy = levelspy End Sub Private Sub TimerDance_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TimerDance.Tick Dim min As Integer = NumericUpDown1.Value TimerDance.Interval = min * 60000 p.Turn(Direction.Up) p.Turn(Direction.Up) p.Turn(Direction.Down) p.Turn(Direction.Down) p.Turn(Direction.Left) p.Turn(Direction.Left) p.Turn(Direction.Right) p.Turn(Direction.Right) End Sub Private Sub CheckBox1_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CheckBox1.CheckedChanged If CheckBox1.Checked Then TimerDance.Start() NumericUpDown1.Enabled = False Else TimerDance.Stop() NumericUpDown1.Enabled = True End If End Sub Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick If c.LoggedIn Then If p.Mana > TextBox2.Text Then c.Console.Say(TextBox1.Text) End If End If End Sub Private Sub CheckBox2_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CheckBox2.CheckedChanged If CheckBox1.Checked Then Timer1.Start() Else Timer1.Stop() End If End Sub Private Sub CheckBox3_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CheckBox3.CheckedChanged If CheckBox3.Checked Then Timer2.Interval = 30000 Timer2.Start() Else Timer2.Stop() End If End Sub Private Sub Timer2_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer2.Tick If c.LoggedIn Then For Each id As Item In c.Inventory.GetItems If id.Id = Constants.Items.Food.Apple.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Banana.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Blueberry.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Carrot.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Cheese.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Cherry.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.BrownMushroom.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Coconut.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Corncob.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.DragonHam.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Egg.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Fish.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Grapes.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.GreenMushroom.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Ham.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Meat.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Mellon.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Orange.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Roll.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Salmon.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.WhiteMushroom.Id Then id.UseOnSelf() End If Next End If End Sub Private Sub Button7_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button7.Click p.Addon = Tibia.Constants.OutfitAddon.Both End Sub Editado Dezembro 23, 2011 13 anos por weslen (veja o histórico de edições)
Postado Dezembro 23, 2011 13 anos Imports Tibia Imports Tibia.Util Imports Tibia.Objects Imports Tibia.Constants Public Class Form2 Public c As Client Dim levelspy As Integer = p.Location.Z Public p As Player Private Sub Form2_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load c = Form1.ComboBox1.SelectedItem If c.LoggedIn Then p = c.GetPlayer Form1.Hide() Else Me.Hide() MsgBox("Você precisa escolher o seu personagem.") End If End Sub Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click c.Map.FullLightOn() End Sub Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click c.Map.FullLightOff() End Sub Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click If ComboBox1.SelectedItem = "Beggar" Then p.OutfitType = Tibia.Constants.OutfitType.BeggarMale ElseIf ComboBox1.SelectedItem = "Assassin" Then p.OutfitType = Tibia.Constants.OutfitType.AssassinMale End If End Sub Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click If levelspy = 14 Then Else c.Map.LevelSpyOn(levelspy + 1) levelspy = levelspy + 1 End If End Sub Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click If levelspy = 0 Or levelspy = 7 Then Else c.Map.LevelSpyOn(levelspy - 1) levelspy = levelspy - 1 End If End Sub Private Sub Button6_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) c.Map.LevelSpyOff() levelspy = levelspy End Sub Private Sub Button6_Click_1(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button6.Click c.Map.LevelSpyOff() levelspy = levelspy End Sub Private Sub TimerDance_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles TimerDance.Tick Dim min As Integer = NumericUpDown1.Value TimerDance.Interval = min * 60000 p.Turn(Direction.Up) p.Turn(Direction.Up) p.Turn(Direction.Down) p.Turn(Direction.Down) p.Turn(Direction.Left) p.Turn(Direction.Left) p.Turn(Direction.Right) p.Turn(Direction.Right) End Sub Private Sub CheckBox1_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CheckBox1.CheckedChanged If CheckBox1.Checked Then TimerDance.Start() NumericUpDown1.Enabled = False Else TimerDance.Stop() NumericUpDown1.Enabled = True End If End Sub Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick If c.LoggedIn Then If p.Mana > TextBox2.Text Then c.Console.Say(TextBox1.Text) End If End If End Sub Private Sub CheckBox2_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CheckBox2.CheckedChanged If CheckBox1.Checked Then Timer1.Start() Else Timer1.Stop() End If End Sub Private Sub CheckBox3_CheckedChanged(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles CheckBox3.CheckedChanged If CheckBox3.Checked Then Timer2.Interval = 30000 Timer2.Start() Else Timer2.Stop() End If End Sub Private Sub Timer2_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer2.Tick If c.LoggedIn Then For Each id As Item In c.Inventory.GetItems If id.Id = Constants.Items.Food.Apple.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Banana.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Blueberry.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Carrot.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Cheese.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Cherry.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.BrownMushroom.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Coconut.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Corncob.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.DragonHam.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Egg.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Fish.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Grapes.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.GreenMushroom.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Ham.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Meat.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Mellon.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Orange.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Roll.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.Salmon.Id Then id.UseOnSelf() End If If id.Id = Constants.Items.Food.WhiteMushroom.Id Then id.UseOnSelf() End If Next End If End Sub Private Sub Button7_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button7.Click p.Addon = Tibia.Constants.OutfitAddon.Both End Sub End Class
Postado Dezembro 23, 2011 13 anos Acredito que se você só remover o End Sub O código já irá funcionar! # Regras Gerais - TibiaKing.com # Contato: [email protected]Não respondo dúvidas via MP.
Postado Dezembro 23, 2011 13 anos Autor Obrigado Valeus Kimoszin Conseguir Editado Dezembro 23, 2011 13 anos por weslen (veja o histórico de edições)
Participe da conversa
Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.