|
You last visited: Today at 03:25
Advertisement
Help! BugBotYang does not sell
Discussion on Help! BugBotYang does not sell within the Metin2 Private Server forum part of the Metin2 category.
09/06/2018, 18:10
|
#1
|
elite*gold: 0
Join Date: Jun 2012
Posts: 15
Received Thanks: 0
|
Help! BugBotYang does not sell
Hello, I need help with this phyton, what happens is that inside the game one time I turn on the bot yang, buy the object but do not sell it, just buy, someone can help me organize it so that, buy and sell the object or Does anyone know what happens?
THIS IS THE PYTHON CODE.
import ui
import dbg
import chat
import net
import time
BugYangV = 0
class Dialog1(ui.BoardWithTitleBar):
def __init__(self):
ui.BoardWithTitleBar.__init__(self)
self.BuildWindow()
def __del__(self):
ui.BoardWithTitleBar.__del__(self)
def BuildWindow(self):
self.SetSize(162, 100)
self.SetCenterPosition()
self.AddFlag('movable')
self.AddFlag('float')
self.SetTitleName('BOTI')
self.SetCloseEvent(self.Close)
self.comp = Component()
self.btnbugyang = self.comp.Button(self, 'Aktiflestir', '', 83, 37, self.btnbugyang_func, 'd:/ymir work/ui/public/middle_button_01.sub', 'd:/ymir work/ui/public/middle_button_02.sub', 'd:/ymir work/ui/public/middle_button_03.sub')
(self.slotbar_editlugar, self.editlugar) = self.comp.EditLine(self, '', 54, 39, 20, 15, 2)
self.txtlugar = self.comp.TextLine(self, 'Slot:', 18, 39, self.comp.RGB(255, 255, 255))
self.txtcredit = self.comp.TextLine(self, 'BOTI', 55, 73, self.comp.RGB(255, 255, 255))
def btnbugyang_func(self):
global BugYangV
if BugYangV == 0:
LugarBugYang = self.editlugar.GetText()
if LugarBugYang == '':
chat.AppendChat(chat.CHAT_TYPE_INFO, 'Bu alani bos birakmayin.')
else:
BugYangV = 1
self.btnbugyang.SetText('Kapat')
chat.AppendChat(chat.CHAT_TYPE_NOTICE, 'Envanterin tamamini ve ilk slotlarini bos birakiniz.')
chat.AppendChat(chat.CHAT_TYPE_NOTICE, 'Envanterin tamamini ve ilk slotlarini bos birakiniz.')
self.BugYangActivado()
else:
BugYangV = 0
self.btnbugyang.SetText('Aktiflestir')
self.BugYangDesactivado()
def BugYangActivado(self):
LugarBugYang = self.editlugar.GetText()
net.SendShopBuyPacket(int(LugarBugYang))
net.SendShopBuyPacket(int(LugarBugYang))
net.SendShopSellPacket(0)
net.SendShopSellPacket(1)
self.BugYangSegundos = WaitingDialog()
self.BugYangSegundos.Open(float(1e-070))
self.BugYangSegundos.SAFE_SetTimeOverEvent(self.Bu gYangActivado)
def BugYangDesactivado(self):
self.BugYangSegundos = WaitingDialog()
self.BugYangSegundos.Open(int(0x47BF19673DF52E37F2 410011D0FFFFFFFFFFFL))
self.BugYangSegundos.SAFE_SetTimeOverEvent(self.Bu gYangDesactivado)
def Close(self):
self.Hide()
class Component:
def Button(self, parent, buttonName, tooltipText, x, y, func, UpVisual, OverVisual, DownVisual):
button = ui.Button()
button.SetParent(parent)
button.SetPosition(x, y)
button.SetUpVisual(UpVisual)
button.SetOverVisual(OverVisual)
button.SetDownVisual(DownVisual)
button.SetText(buttonName)
button.SetToolTipText(tooltipText)
button.Show()
button.SetEvent(func)
return button
def ToggleButton(self, parent, buttonName, tooltipText, x, y, funcUp, funcDown, UpVisual, OverVisual, DownVisual):
button = ui.ToggleButton()
button.SetParent(parent)
button.SetPosition(x, y)
button.SetUpVisual(UpVisual)
button.SetOverVisual(OverVisual)
button.SetDownVisual(DownVisual)
button.SetText(buttonName)
button.SetToolTipText(tooltipText)
button.Show()
button.SetToggleUpEvent(funcUp)
button.SetToggleDownEvent(funcDown)
return button
def EditLine(self, parent, editlineText, x, y, width, heigh, max):
SlotBar = ui.SlotBar()
SlotBar.SetParent(parent)
SlotBar.SetSize(width, heigh)
SlotBar.SetPosition(x, y)
SlotBar.Show()
Value = ui.EditLine()
Value.SetParent(SlotBar)
Value.SetSize(width, heigh)
Value.SetPosition(5, 1)
Value.SetMax(max)
Value.SetText(editlineText)
Value.Show()
return (SlotBar, Value)
def TextLine(self, parent, textlineText, x, y, color):
textline = ui.TextLine()
textline.SetParent(parent)
textline.SetPosition(x, y)
if color != None:
textline.SetFontColor(color[0], color[1], color[2])
textline.SetText(textlineText)
textline.Show()
return textline
def RGB(self, r, g, b):
return (r * 255, g * 255, b * 255)
def SliderBar(self, parent, sliderPos, func, x, y):
Slider = ui.SliderBar()
Slider.SetParent(parent)
Slider.SetPosition(x, y)
Slider.SetSliderPos(sliderPos / 100)
Slider.Show()
Slider.SetEvent(func)
return Slider
def ExpandedImage(self, parent, x, y, img):
image = ui.ExpandedImageBox()
image.SetParent(parent)
image.SetPosition(x, y)
image.LoadImage(img)
image.Show()
return image
def ComboBox(self, parent, text, x, y, width):
combo = ui.ComboBox()
combo.SetParent(parent)
combo.SetPosition(x, y)
combo.SetSize(width, 15)
combo.SetCurrentItem(text)
combo.Show()
return combo
def ThinBoard(self, parent, moveable, x, y, width, heigh, center):
thin = ui.ThinBoard()
if parent != None:
thin.SetParent(parent)
if moveable == TRUE:
thin.AddFlag('movable')
thin.AddFlag('float')
thin.SetSize(width, heigh)
thin.SetPosition(x, y)
if center == TRUE:
thin.SetCenterPosition()
thin.Show()
return thin
class WaitingDialog(ui.ScriptWindow):
def __init__(self):
ui.ScriptWindow.__init__(self)
self.eventTimeOver = lambda *arg: None
self.eventExit = lambda *arg: None
def __del__(self):
ui.ScriptWindow.__del__(self)
def Open(self, waitTime):
curTime = time.clock()
self.endTime = curTime + waitTime
self.Show()
def Close(self):
self.Hide()
def Destroy(self):
self.Hide()
def SAFE_SetTimeOverEvent(self, event):
self.eventTimeOver = ui.__mem_func__(event)
def SAFE_SetExitEvent(self, event):
self.eventExit = ui.__mem_func__(event)
def OnUpdate(self):
lastTime = max(0, self.endTime - time.clock())
if 0 == lastTime:
self.Close()
self.eventTimeOver()
else:
return None
Dialog1().Show()
HELP ME THANKS!
|
|
|
09/10/2018, 08:33
|
#2
|
elite*gold: 0
Join Date: Dec 2015
Posts: 440
Received Thanks: 154
|
Just take this one. Works since years 
It´s of M2Bob-Forum
Code:
import ui,app,chat,chr,net,player,item,skill,time,game,shop,chrmgr,thread
class BuyAndSellBotDialog(ui.ScriptWindow):
ItemID = 0
State = 0
def __init__(self):
ui.ScriptWindow.__init__(self)
self.Board = ui.ThinBoard()
self.Board.SetSize(218, 250)
self.Board.SetCenterPosition()
self.Board.AddFlag("movable")
self.Board.Show()
self.comp = Component()
self.Header = self.comp.TextLine(self.Board, 'Buy & Sell Bot', 65, 8, self.comp.RGB(255, 255, 0))
self.BarItems, self.ListBoxItems, ScrollItems = self.comp.ListBoxEx(self.Board, 10, 50, 170, 140)
self.SkillIdNameLabel = self.comp.TextLine(self.Board, 'ID: Name:', 16, 37, self.comp.RGB(255, 255, 255))
self.Close = self.comp.Button(self.Board, '', 'Close', 183, 8, self.Board.Hide, 'd:/ymir work/ui/public/close_button_01.sub', 'd:/ymir work/ui/public/close_button_02.sub', 'd:/ymir work/ui/public/close_button_03.sub')
self.Refresh = self.comp.Button(self.Board, '', 'Refresh', 163, 6, self.UpdateItemList, 'd:/ymir work/ui/game/guild/refresh_button_01.sub', 'd:/ymir work/ui/game/guild/refresh_button_02.sub', 'd:/ymir work/ui/game/guild/refresh_button_03.sub')
self.StartButton = self.comp.Button(self.Board, 'Start', '', 70, 205, self.SetStatus, 'd:/ymir work/ui/public/large_button_01.sub', 'd:/ymir work/ui/public/large_button_02.sub', 'd:/ymir work/ui/public/large_button_03.sub')
self.UpdateItemList()
def UpdateItemList(self):
if not shop.IsOpen():
chat.AppendChat(7, "[M2-BOB] Please open a Shop first!")
return
self.ListBoxItems.RemoveAllItems()
for i in xrange(shop.SHOP_SLOT_COUNT):
ItemIndex = shop.GetItemID(i)
if ItemIndex != 0:
ItemName = item.GetItemName(item.SelectItem(int(ItemIndex)))
self.ListBoxItems.AppendItem(Item(str(ItemIndex) + ' ' + ItemName))
def SetStatus(self):
ItemIndex = self.ListBoxItems.GetSelectedItem()
if ItemIndex:
pass
else:
chat.AppendChat(7, "[M2-BOB] No Item selected!")
return
if not shop.IsOpen():
chat.AppendChat(7, "[M2-BOB] Please open a Shop first!")
return
if self.State:
self.State = 0
self.StartButton.SetText("Start")
self.SellRestItems()
else:
self.ItemID = int(ItemIndex.GetText().split(" ")[0])
self.State = 1
thread.start_new_thread(self.BuyAndSellItems,())
self.StartButton.SetText("Stop")
def BuyAndSellItems(self):
while self.State == 1 and shop.IsOpen():
for EachShopSlot in xrange(shop.SHOP_SLOT_COUNT):
getShopItemID = shop.GetItemID(EachShopSlot)
if getShopItemID == self.ItemID:
price = shop.GetItemPrice(EachShopSlot)
if price <= player.GetMoney():
net.SendShopBuyPacket(EachShopSlot)
break
else:
self.State = 1
self.StartButton.SetText("Stop")
time.sleep(0.01) # 0.1 = 100ms, 0.01 = 10ms
self.SellRestItems()
self.SellRestItems()
def SellRestItems(self):
for EachInventorySlot in xrange(90):
ItemIndex = player.GetItemIndex(EachInventorySlot)
if ItemIndex == self.ItemID:
net.SendShopSellPacket(EachInventorySlot)
class Item(ui.ListBoxEx.Item):
def __init__(self, fileName):
ui.ListBoxEx.Item.__init__(self)
self.canLoad=0
self.text=fileName
self.textLine=self.__CreateTextLine(fileName)
def __del__(self):
ui.ListBoxEx.Item.__del__(self)
def GetText(self):
return self.text
def SetSize(self, width, height):
ui.ListBoxEx.Item.SetSize(self, 6*len(self.textLine.GetText()) + 4, height)
def __CreateTextLine(self, fileName):
textLine=ui.TextLine()
textLine.SetParent(self)
textLine.SetPosition(0, 0)
textLine.SetText(fileName)
textLine.Show()
return textLine
class Component:
def Button(self, parent, buttonName, tooltipText, x, y, func, UpVisual, OverVisual, DownVisual):
button = ui.Button()
if parent != None:
button.SetParent(parent)
button.SetPosition(x, y)
button.SetUpVisual(UpVisual)
button.SetOverVisual(OverVisual)
button.SetDownVisual(DownVisual)
button.SetText(buttonName)
button.SetToolTipText(tooltipText)
button.Show()
button.SetEvent(func)
return button
def HideButton(self, parent, buttonName, tooltipText, x, y, func, UpVisual, OverVisual, DownVisual):
button = ui.Button()
if parent != None:
button.SetParent(parent)
button.SetPosition(x, y)
button.SetUpVisual(UpVisual)
button.SetOverVisual(OverVisual)
button.SetDownVisual(DownVisual)
button.SetText(buttonName)
button.SetToolTipText(tooltipText)
button.SetEvent(func)
return button
def ToggleButton(self, parent, buttonName, tooltipText, x, y, funcUp, funcDown, UpVisual, OverVisual, DownVisual):
button = ui.ToggleButton()
if parent != None:
button.SetParent(parent)
button.SetPosition(x, y)
button.SetUpVisual(UpVisual)
button.SetOverVisual(OverVisual)
button.SetDownVisual(DownVisual)
button.SetText(buttonName)
button.SetToolTipText(tooltipText)
button.Show()
button.SetToggleUpEvent(funcUp)
button.SetToggleDownEvent(funcDown)
return button
def EditLine(self, parent, editlineText, x, y, width, heigh, max):
SlotBar = ui.SlotBar()
if parent != None:
SlotBar.SetParent(parent)
SlotBar.SetSize(width, heigh)
SlotBar.SetPosition(x, y)
SlotBar.Show()
Value = ui.EditLine()
Value.SetParent(SlotBar)
Value.SetSize(width, heigh)
Value.SetPosition(8, 2)
Value.SetMax(max)
Value.SetLimitWidth(width)
Value.SetMultiLine()
Value.SetText(editlineText)
Value.SetIMEFlag(3)
Value.Show()
return SlotBar, Value
def OnlyEditLine(self, parent, width, heigh, x, y, editlineText, max):
Value = ui.EditLine()
if parent != None:
Value.SetParent(parent)
Value.SetSize(width, heigh)
Value.SetPosition(x, y)
Value.SetMax(max)
Value.SetText(editlineText)
Value.SetNumberMode()
Value.Show()
return Value
def TextLine(self, parent, textlineText, x, y, color):
textline = ui.TextLine()
if parent != None:
textline.SetParent(parent)
textline.SetPosition(x, y)
if color != None:
textline.SetFontColor(color[0], color[1], color[2])
textline.SetText(textlineText)
textline.SetOutline()
textline.Show()
return textline
def RGB(self, r, g, b):
return (r*255, g*255, b*255)
def SliderBar(self, parent, sliderPos, func, x, y):
Slider = ui.SliderBar()
if parent != None:
Slider.SetParent(parent)
Slider.SetPosition(x, y)
Slider.SetSliderPos(sliderPos)
Slider.Show()
Slider.SetEvent(func)
return Slider
def ExpandedImage(self, parent, x, y, img):
image = ui.ExpandedImageBox()
if parent != None:
image.SetParent(parent)
image.SetPosition(x, y)
image.LoadImage(img)
image.Show()
return image
def ComboBoxFunc(self, parent, text, x, y, width, func):
combo = ui.ComboBox()
if parent != None:
combo.SetParent(parent)
combo.SetPosition(x, y)
combo.SetSize(width, 15)
combo.SetCurrentItem(text)
combo.SetEvent(func)
combo.Show()
return combo
def ComboBox(self, parent, text, x, y, width):
combo = ui.ComboBox()
if parent != None:
combo.SetParent(parent)
combo.SetPosition(x, y)
combo.SetSize(width, 15)
combo.SetCurrentItem(text)
combo.Show()
return combo
def ThinBoard(self, parent, moveable, x, y, width, heigh, center):
thin = ui.ThinBoard()
if parent != None:
thin.SetParent(parent)
if moveable == TRUE:
thin.AddFlag('movable')
thin.AddFlag('float')
thin.SetSize(width, heigh)
thin.SetPosition(x, y)
if center == TRUE:
thin.SetCenterPosition()
thin.Show()
return thin
def Gauge(self, parent, width, color, x, y):
gauge = ui.Gauge()
if parent != None:
gauge.SetParent(parent)
gauge.SetPosition(x, y)
gauge.MakeGauge(width, color)
gauge.Show()
return gauge
def ListBoxEx(self, parent, x, y, width, heigh):
bar = ui.Bar()
if parent != None:
bar.SetParent(parent)
bar.SetPosition(x, y)
bar.SetSize(width + 20, heigh)
bar.SetColor(1996488704)
bar.Show()
ListBox = ui.ListBoxEx()
ListBox.SetParent(bar)
ListBox.SetPosition(0, 0)
ListBox.SetViewItemCount(7)
ListBox.SetSize(width, heigh)
ListBox.Show()
scroll = ui.ScrollBar()
scroll.SetParent(bar)
scroll.SetPosition(width + 5, 0)
scroll.SetScrollBarSize(heigh)
scroll.Show()
ListBox.SetScrollBar(scroll)
return (bar, ListBox, scroll)
def ListBoxEx2(self, parent, x, y, width, heigh):
bar = ui.Bar()
if parent != None:
bar.SetParent(parent)
bar.SetPosition(x, y)
bar.SetSize(width + 20, heigh)
bar.SetColor(1996488704)
bar.Show()
ListBox = ui.ListBoxEx()
ListBox.SetParent(bar)
ListBox.SetPosition(0, 0)
ListBox.SetViewItemCount(5)
ListBox.SetSize(width, heigh)
ListBox.Show()
scroll = ui.ScrollBar()
scroll.SetParent(bar)
scroll.SetPosition(width + 5, 0)
scroll.SetScrollBarSize(heigh)
scroll.Show()
ListBox.SetScrollBar(scroll)
return (bar, ListBox, scroll)
def FileListBox(self, parent, x, y, width, heigh, count):
ListBox = ui.ListBoxEx()
ListBox.SetParent(parent)
ListBox.SetPosition(x, y)
ListBox.SetViewItemCount(count)
ListBox.SetSize(width, heigh)
ListBox.Show()
scroll = ui.ScrollBar()
scroll.SetParent(ListBox)
scroll.SetPosition(width - 20, 0)
scroll.SetScrollBarSize(heigh)
scroll.Show()
ListBox.SetScrollBar(scroll)
return ListBox, scroll
def ReadingListBox(self, parent, x, y, width, heigh, count):
bar = ui.Bar()
if parent != None:
bar.SetParent(parent)
bar.SetPosition(x, y)
bar.SetSize(width + 20, heigh)
bar.Show()
ListBox = ui.ListBoxEx()
ListBox.SetParent(bar)
ListBox.SetPosition(10, 13)
ListBox.SetViewItemCount(count)
ListBox.SetSize(width, heigh)
ListBox.Show()
return bar, ListBox
x = BuyAndSellBotDialog()
x.Show()
|
|
|
09/10/2018, 21:05
|
#3
|
elite*gold: 0
Join Date: Jun 2012
Posts: 15
Received Thanks: 0
|
Quote:
Originally Posted by Volvox337
Just take this one. Works since years 
It´s of M2Bob-Forum
Code:
import ui,app,chat,chr,net,player,item,skill,time,game,shop,chrmgr,thread
class BuyAndSellBotDialog(ui.ScriptWindow):
ItemID = 0
State = 0
def __init__(self):
ui.ScriptWindow.__init__(self)
self.Board = ui.ThinBoard()
self.Board.SetSize(218, 250)
self.Board.SetCenterPosition()
self.Board.AddFlag("movable")
self.Board.Show()
self.comp = Component()
self.Header = self.comp.TextLine(self.Board, 'Buy & Sell Bot', 65, 8, self.comp.RGB(255, 255, 0))
self.BarItems, self.ListBoxItems, ScrollItems = self.comp.ListBoxEx(self.Board, 10, 50, 170, 140)
self.SkillIdNameLabel = self.comp.TextLine(self.Board, 'ID: Name:', 16, 37, self.comp.RGB(255, 255, 255))
self.Close = self.comp.Button(self.Board, '', 'Close', 183, 8, self.Board.Hide, 'd:/ymir work/ui/public/close_button_01.sub', 'd:/ymir work/ui/public/close_button_02.sub', 'd:/ymir work/ui/public/close_button_03.sub')
self.Refresh = self.comp.Button(self.Board, '', 'Refresh', 163, 6, self.UpdateItemList, 'd:/ymir work/ui/game/guild/refresh_button_01.sub', 'd:/ymir work/ui/game/guild/refresh_button_02.sub', 'd:/ymir work/ui/game/guild/refresh_button_03.sub')
self.StartButton = self.comp.Button(self.Board, 'Start', '', 70, 205, self.SetStatus, 'd:/ymir work/ui/public/large_button_01.sub', 'd:/ymir work/ui/public/large_button_02.sub', 'd:/ymir work/ui/public/large_button_03.sub')
self.UpdateItemList()
def UpdateItemList(self):
if not shop.IsOpen():
chat.AppendChat(7, "[M2-BOB] Please open a Shop first!")
return
self.ListBoxItems.RemoveAllItems()
for i in xrange(shop.SHOP_SLOT_COUNT):
ItemIndex = shop.GetItemID(i)
if ItemIndex != 0:
ItemName = item.GetItemName(item.SelectItem(int(ItemIndex)))
self.ListBoxItems.AppendItem(Item(str(ItemIndex) + ' ' + ItemName))
def SetStatus(self):
ItemIndex = self.ListBoxItems.GetSelectedItem()
if ItemIndex:
pass
else:
chat.AppendChat(7, "[M2-BOB] No Item selected!")
return
if not shop.IsOpen():
chat.AppendChat(7, "[M2-BOB] Please open a Shop first!")
return
if self.State:
self.State = 0
self.StartButton.SetText("Start")
self.SellRestItems()
else:
self.ItemID = int(ItemIndex.GetText().split(" ")[0])
self.State = 1
thread.start_new_thread(self.BuyAndSellItems,())
self.StartButton.SetText("Stop")
def BuyAndSellItems(self):
while self.State == 1 and shop.IsOpen():
for EachShopSlot in xrange(shop.SHOP_SLOT_COUNT):
getShopItemID = shop.GetItemID(EachShopSlot)
if getShopItemID == self.ItemID:
price = shop.GetItemPrice(EachShopSlot)
if price <= player.GetMoney():
net.SendShopBuyPacket(EachShopSlot)
break
else:
self.State = 1
self.StartButton.SetText("Stop")
time.sleep(0.01) # 0.1 = 100ms, 0.01 = 10ms
self.SellRestItems()
self.SellRestItems()
def SellRestItems(self):
for EachInventorySlot in xrange(90):
ItemIndex = player.GetItemIndex(EachInventorySlot)
if ItemIndex == self.ItemID:
net.SendShopSellPacket(EachInventorySlot)
class Item(ui.ListBoxEx.Item):
def __init__(self, fileName):
ui.ListBoxEx.Item.__init__(self)
self.canLoad=0
self.text=fileName
self.textLine=self.__CreateTextLine(fileName)
def __del__(self):
ui.ListBoxEx.Item.__del__(self)
def GetText(self):
return self.text
def SetSize(self, width, height):
ui.ListBoxEx.Item.SetSize(self, 6*len(self.textLine.GetText()) + 4, height)
def __CreateTextLine(self, fileName):
textLine=ui.TextLine()
textLine.SetParent(self)
textLine.SetPosition(0, 0)
textLine.SetText(fileName)
textLine.Show()
return textLine
class Component:
def Button(self, parent, buttonName, tooltipText, x, y, func, UpVisual, OverVisual, DownVisual):
button = ui.Button()
if parent != None:
button.SetParent(parent)
button.SetPosition(x, y)
button.SetUpVisual(UpVisual)
button.SetOverVisual(OverVisual)
button.SetDownVisual(DownVisual)
button.SetText(buttonName)
button.SetToolTipText(tooltipText)
button.Show()
button.SetEvent(func)
return button
def HideButton(self, parent, buttonName, tooltipText, x, y, func, UpVisual, OverVisual, DownVisual):
button = ui.Button()
if parent != None:
button.SetParent(parent)
button.SetPosition(x, y)
button.SetUpVisual(UpVisual)
button.SetOverVisual(OverVisual)
button.SetDownVisual(DownVisual)
button.SetText(buttonName)
button.SetToolTipText(tooltipText)
button.SetEvent(func)
return button
def ToggleButton(self, parent, buttonName, tooltipText, x, y, funcUp, funcDown, UpVisual, OverVisual, DownVisual):
button = ui.ToggleButton()
if parent != None:
button.SetParent(parent)
button.SetPosition(x, y)
button.SetUpVisual(UpVisual)
button.SetOverVisual(OverVisual)
button.SetDownVisual(DownVisual)
button.SetText(buttonName)
button.SetToolTipText(tooltipText)
button.Show()
button.SetToggleUpEvent(funcUp)
button.SetToggleDownEvent(funcDown)
return button
def EditLine(self, parent, editlineText, x, y, width, heigh, max):
SlotBar = ui.SlotBar()
if parent != None:
SlotBar.SetParent(parent)
SlotBar.SetSize(width, heigh)
SlotBar.SetPosition(x, y)
SlotBar.Show()
Value = ui.EditLine()
Value.SetParent(SlotBar)
Value.SetSize(width, heigh)
Value.SetPosition(8, 2)
Value.SetMax(max)
Value.SetLimitWidth(width)
Value.SetMultiLine()
Value.SetText(editlineText)
Value.SetIMEFlag(3)
Value.Show()
return SlotBar, Value
def OnlyEditLine(self, parent, width, heigh, x, y, editlineText, max):
Value = ui.EditLine()
if parent != None:
Value.SetParent(parent)
Value.SetSize(width, heigh)
Value.SetPosition(x, y)
Value.SetMax(max)
Value.SetText(editlineText)
Value.SetNumberMode()
Value.Show()
return Value
def TextLine(self, parent, textlineText, x, y, color):
textline = ui.TextLine()
if parent != None:
textline.SetParent(parent)
textline.SetPosition(x, y)
if color != None:
textline.SetFontColor(color[0], color[1], color[2])
textline.SetText(textlineText)
textline.SetOutline()
textline.Show()
return textline
def RGB(self, r, g, b):
return (r*255, g*255, b*255)
def SliderBar(self, parent, sliderPos, func, x, y):
Slider = ui.SliderBar()
if parent != None:
Slider.SetParent(parent)
Slider.SetPosition(x, y)
Slider.SetSliderPos(sliderPos)
Slider.Show()
Slider.SetEvent(func)
return Slider
def ExpandedImage(self, parent, x, y, img):
image = ui.ExpandedImageBox()
if parent != None:
image.SetParent(parent)
image.SetPosition(x, y)
image.LoadImage(img)
image.Show()
return image
def ComboBoxFunc(self, parent, text, x, y, width, func):
combo = ui.ComboBox()
if parent != None:
combo.SetParent(parent)
combo.SetPosition(x, y)
combo.SetSize(width, 15)
combo.SetCurrentItem(text)
combo.SetEvent(func)
combo.Show()
return combo
def ComboBox(self, parent, text, x, y, width):
combo = ui.ComboBox()
if parent != None:
combo.SetParent(parent)
combo.SetPosition(x, y)
combo.SetSize(width, 15)
combo.SetCurrentItem(text)
combo.Show()
return combo
def ThinBoard(self, parent, moveable, x, y, width, heigh, center):
thin = ui.ThinBoard()
if parent != None:
thin.SetParent(parent)
if moveable == TRUE:
thin.AddFlag('movable')
thin.AddFlag('float')
thin.SetSize(width, heigh)
thin.SetPosition(x, y)
if center == TRUE:
thin.SetCenterPosition()
thin.Show()
return thin
def Gauge(self, parent, width, color, x, y):
gauge = ui.Gauge()
if parent != None:
gauge.SetParent(parent)
gauge.SetPosition(x, y)
gauge.MakeGauge(width, color)
gauge.Show()
return gauge
def ListBoxEx(self, parent, x, y, width, heigh):
bar = ui.Bar()
if parent != None:
bar.SetParent(parent)
bar.SetPosition(x, y)
bar.SetSize(width + 20, heigh)
bar.SetColor(1996488704)
bar.Show()
ListBox = ui.ListBoxEx()
ListBox.SetParent(bar)
ListBox.SetPosition(0, 0)
ListBox.SetViewItemCount(7)
ListBox.SetSize(width, heigh)
ListBox.Show()
scroll = ui.ScrollBar()
scroll.SetParent(bar)
scroll.SetPosition(width + 5, 0)
scroll.SetScrollBarSize(heigh)
scroll.Show()
ListBox.SetScrollBar(scroll)
return (bar, ListBox, scroll)
def ListBoxEx2(self, parent, x, y, width, heigh):
bar = ui.Bar()
if parent != None:
bar.SetParent(parent)
bar.SetPosition(x, y)
bar.SetSize(width + 20, heigh)
bar.SetColor(1996488704)
bar.Show()
ListBox = ui.ListBoxEx()
ListBox.SetParent(bar)
ListBox.SetPosition(0, 0)
ListBox.SetViewItemCount(5)
ListBox.SetSize(width, heigh)
ListBox.Show()
scroll = ui.ScrollBar()
scroll.SetParent(bar)
scroll.SetPosition(width + 5, 0)
scroll.SetScrollBarSize(heigh)
scroll.Show()
ListBox.SetScrollBar(scroll)
return (bar, ListBox, scroll)
def FileListBox(self, parent, x, y, width, heigh, count):
ListBox = ui.ListBoxEx()
ListBox.SetParent(parent)
ListBox.SetPosition(x, y)
ListBox.SetViewItemCount(count)
ListBox.SetSize(width, heigh)
ListBox.Show()
scroll = ui.ScrollBar()
scroll.SetParent(ListBox)
scroll.SetPosition(width - 20, 0)
scroll.SetScrollBarSize(heigh)
scroll.Show()
ListBox.SetScrollBar(scroll)
return ListBox, scroll
def ReadingListBox(self, parent, x, y, width, heigh, count):
bar = ui.Bar()
if parent != None:
bar.SetParent(parent)
bar.SetPosition(x, y)
bar.SetSize(width + 20, heigh)
bar.Show()
ListBox = ui.ListBoxEx()
ListBox.SetParent(bar)
ListBox.SetPosition(10, 13)
ListBox.SetViewItemCount(count)
ListBox.SetSize(width, heigh)
ListBox.Show()
return bar, ListBox
x = BuyAndSellBotDialog()
x.Show()

|
It does not sell, it only buys too
|
|
|
09/12/2018, 20:09
|
#4
|
elite*gold: 0
Join Date: Jun 2012
Posts: 15
Received Thanks: 0
|
Up, Help.
|
|
|
09/17/2018, 00:09
|
#5
|
elite*gold: 20
Join Date: Aug 2008
Posts: 74
Received Thanks: 16
|
Code:
try:
net.SendShopSellPacket(slot)
except:
try:
net.SendShopSellPacket(1, slot)
except:
net.SendShopSellPacketNew(slot, 0, 1)
If it still doesn't work it's because your server has a custom sell packet. You need to decompile the client somehow and find out what it is.
|
|
|
 |
Similar Threads
|
[INFO] - Soft Ban - What does it mean, how does it affect you and how to avoid it
07/18/2016 - Pokemon Guides & Strategies - 5 Replies
http://cdn.elitepvpers.org/images/us.png
Disclaimer]
You can get a soft ban while spoofing your GPS as well as playing without spoofing!
What is a Soft Ban?]
A "Soft Ban" is exactly what it says, you got banned in a "soft" way. This means, you will most likely be unable
to interact with PokeStops, catch Pokemon or battle gymns for a certain amount of time.
|
[HELP] File is not a portable executable. DOS header does not contain 'MZ' signature
06/11/2015 - General Coding - 3 Replies
Hi
When i open Assembly-CSharp.dll File on .NET Reflector, i got the error that say "Assembly-CSharp, File is not a portable executable. DOS header does not contain 'MZ' signature.". can someone help me with this and how to dump the game? it is possible to decrypt DLL file and make it execute-able but peoples won't help me, always give me bad explaination and ignore me.
The game is named Call Of Duty Heroes Android. I had modded it before and i always modify units damage so units can...
|
pvp server register button no funciona help - register button does not work help
12/02/2014 - DarkOrbit - 1 Replies
He instalado el servidor
register button
no funciona
ˇayuda
**********************
I installed server
register button
does not work
help
**********************
|
[HELP]beta armor hp does not seem to help :(
07/11/2013 - Metin2 Private Server - 0 Replies
beta armor hp does not seem to help :(
Why not look beta armor hp
Where is the error?
locale de? Could it be?
|
[HELP] Account does not exist upon first click then does on second
12/28/2011 - Shaiya Private Server - 3 Replies
I have tried searching the forums for this issue but all I find is problems with starting the server, I have mine all set up and "semi" public but when I or anyone else logs in we get a message saying account does not exist but if you click ok and re-enter your password it logs in, does anyone know what the problem is?
|
All times are GMT +1. The time now is 03:25.
|
|