|
You last visited: Today at 01:10
Advertisement
[RELEASE] Exchange System v1.0 ~ by Fatihbab34™
Discussion on [RELEASE] Exchange System v1.0 ~ by Fatihbab34™ within the Metin2 PServer Guides & Strategies forum part of the Metin2 Private Server category.
03/26/2015, 14:52
|
#16
|
elite*gold: 0
Join Date: Oct 2011
Posts: 164
Received Thanks: 34
|
kann nur ein item einfügen
|
|
|
03/26/2015, 16:07
|
#17
|
elite*gold: 150
Join Date: Sep 2010
Posts: 1,049
Received Thanks: 275
|
um das level etc des anderen anzeigen zu lassen braucht man ne quest wüsste nicht wie das nur mit python funtzen sollte und das und der bugs mit dem items liegt wohl dadran das die fenster größen nicht stimmen
|
|
|
03/26/2015, 16:50
|
#18
|
elite*gold: 0
Join Date: Jan 2010
Posts: 229
Received Thanks: 32
|
Quote:
Originally Posted by gerald500
looks pretty cool but i like mine more
|
cmon release yours would be awesome!
|
|
|
03/26/2015, 20:56
|
#19
|
elite*gold: 399
Join Date: Sep 2011
Posts: 5,323
Received Thanks: 3,938
|
Quote:
Originally Posted by gerald500
um das level etc des anderen anzeigen zu lassen braucht man ne quest wüsste nicht wie das nur mit python funtzen sollte und das und der bugs mit dem items liegt wohl dadran das die fenster größen nicht stimmen
|
Liegt wohl eher daran, dass du nicht wirklich Python kannst
Das Level abzufragen ist über haupt kein Problem. Solange es sich nicht um eine für ein System essentielle Levelabfrage handelt kann mans über Python machen. Die Abfrage ist halt extrem einfach zu umgehen bzw. zu modifizieren wenn man den Client entpackt hat..
Rechtschreibfehler kommen mit lieben Grüßen von meiner Android Tastatur.
|
|
|
03/27/2015, 00:15
|
#20
|
elite*gold: 17
Join Date: May 2014
Posts: 2,094
Received Thanks: 1,279
|
there is a bug that the "Face" is not correct. I trade as warrior with a shaman but both faces are warriors.
I got no sysrr warning.
I (the warrior) open the trade window and i got this:
but when i switch to the shaman window i got this:
can you fix it that is on both sides correct?
|
|
|
04/07/2015, 14:34
|
#21
|
elite*gold: 0
Join Date: Sep 2013
Posts: 56
Received Thanks: 15
|
can not be inserted into items from window
|
|
|
04/08/2015, 20:14
|
#22
|
elite*gold: 0
Join Date: Nov 2011
Posts: 1,448
Received Thanks: 1,258
|
Quote:
Originally Posted by AmerigoMendosa
can not be inserted into items from window
|
Do you have backup files of uiexchange.py?
If so, then search in your backup uiexchange.py the function
Code:
def SelectOwnerEmptySlot(self, SlotIndex):
In this function must be a command that looks a bit like this but isnt:
Code:
net.SendExchangeItemAddPacket(SrcSlotNumber, DstSlotNumber)
Took this different command of your backup uiexchange.py and replace it with the command in uiexchange.py from release.
Otherwise post syserr.
|
|
|
04/09/2015, 12:07
|
#23
|
elite*gold: 0
Join Date: Sep 2013
Posts: 56
Received Thanks: 15
|
40k client
image
root
constinfo.py
Code:
ticsinif = 0
ticlonca = ""
ticlevel = ""
game.py
Code:
def OnRecvWhisper(self, mode, name, line):
if line.find("xxbanasinifiniverxx") != -1:
race = net.GetMainActorRace()
if not guild.IsGuildEnable():
net.SendWhisperPacket(name, "xxbuyursinifimkardesimxx"+str(race)+"xx"+"Nincs céhben.xx"+str(player.GetStatus(player.LEVEL))+"xx")
else:
net.SendWhisperPacket(name, "xxbuyursinifimkardesimxx"+str(race)+"xx"+str(player.GetGuildName())+"xx"+str(player.GetStatus(player.LEVEL))+"xx")
return
if line.find("xxbuyursinifimkardesimxx") != -1:
constInfo.ticsinif = int(line.split("xx")[2])
constInfo.ticlonca = line.split("xx")[3]
constInfo.ticlevel = line.split("xx")[4]
return
if mode == chat.WHISPER_TYPE_GM:
self.interface.RegisterGameMasterName(name)
chat.AppendWhisper(mode, name, line)
self.interface.RecvWhisper(name)
uiexchange.py
Code:
import player
import exchange
import net
import localeInfo
import event
import chat
import item
import constInfo
import playerSettingModule
import ui
import mouseModule
import uiPickMoney
import wndMgr
###################################################################################################
## Exchange
FACE_IMAGE_DICT = {
playerSettingModule.RACE_WARRIOR_M : "icon/face/warrior_m.tga",
playerSettingModule.RACE_WARRIOR_W : "icon/face/warrior_w.tga",
playerSettingModule.RACE_ASSASSIN_M : "icon/face/assassin_m.tga",
playerSettingModule.RACE_ASSASSIN_W : "icon/face/assassin_w.tga",
playerSettingModule.RACE_SURA_M : "icon/face/sura_m.tga",
playerSettingModule.RACE_SURA_W : "icon/face/sura_w.tga",
playerSettingModule.RACE_SHAMAN_M : "icon/face/shaman_m.tga",
playerSettingModule.RACE_SHAMAN_W : "icon/face/shaman_w.tga",
}
class ExchangeDialog(ui.ScriptWindow):
def __init__(self):
ui.ScriptWindow.__init__(self)
self.TitleName = 0
self.tooltipItem = 0
self.xStart = 0
self.yStart = 0
def __del__(self):
ui.ScriptWindow.__del__(self)
def LoadDialog(self):
PythonScriptLoader = ui.PythonScriptLoader()
PythonScriptLoader.LoadScriptFile(self, "UIScript/exchangedialog.py")
## Owner
self.OwnerSlot = self.GetChild("Owner_Slot")
self.OwnerSlot.SetSelectEmptySlotEvent(ui.__mem_func__(self.SelectOwnerEmptySlot))
self.OwnerSlot.SetSelectItemSlotEvent(ui.__mem_func__(self.SelectOwnerItemSlot))
self.OwnerSlot.SetOverInItemEvent(ui.__mem_func__(self.OverInOwnerItem))
self.OwnerSlot.SetOverOutItemEvent(ui.__mem_func__(self.OverOutItem))
self.OwnerMoney = self.GetChild("Owner_Money_Value")
self.OwnerAcceptLight = self.GetChild("Owner_Accept_Light")
self.OwnerAcceptLight.Disable()
self.OwnerMoneyButton = self.GetChild("Owner_Money")
self.OwnerMoneyButton.SetEvent(ui.__mem_func__(self.OpenPickMoneyDialog))
## Target
self.TargetSlot = self.GetChild("Target_Slot")
self.TargetSlot.SetOverInItemEvent(ui.__mem_func__(self.OverInTargetItem))
self.TargetSlot.SetOverOutItemEvent(ui.__mem_func__(self.OverOutItem))
self.TargetMoney = self.GetChild("Target_Money_Value")
self.TargetAcceptLight = self.GetChild("Target_Accept_Light")
self.TargetAcceptLight.Disable()
## PickMoneyDialog
dlgPickMoney = uiPickMoney.PickMoneyDialog()
dlgPickMoney.LoadDialog()
dlgPickMoney.SetAcceptEvent(ui.__mem_func__(self.OnPickMoney))
dlgPickMoney.SetTitleName(localeInfo.EXCHANGE_MONEY)
dlgPickMoney.SetMax(9) ## 999.999.999 millió yang
#dlgPickMoney.SetMax(7) ## 9.999.999 millió yang
dlgPickMoney.Hide()
self.dlgPickMoney = dlgPickMoney
## Button
self.AcceptButton = self.GetChild("Owner_Accept_Button")
self.AcceptButton.SetToggleDownEvent(ui.__mem_func__(self.AcceptExchange))
self.TitleName = self.GetChild("TitleName")
self.GetChild("TitleBar").SetCloseEvent(net.SendExchangeExitPacket)
def Destroy(self):
print "---------------------------------------------------------------------------- DESTROY EXCHANGE"
self.ClearDictionary()
self.dlgPickMoney.Destroy()
self.dlgPickMoney = 0
self.OwnerSlot = 0
self.OwnerMoney = 0
self.OwnerAcceptLight = 0
self.OwnerMoneyButton = 0
self.TargetSlot = 0
self.TargetMoney = 0
self.TargetAcceptLight = 0
self.TitleName = 0
self.AcceptButton = 0
self.tooltipItem = 0
def OpenDialog(self):
self.TitleName.SetText(localeInfo.EXCHANGE_TITLE % (exchange.GetNameFromTarget()))
self.AcceptButton.Enable()
self.AcceptButton.SetUp()
self.Show()
net.SendWhisperPacket(exchange.GetNameFromTarget(), "xxbanasinifiniverxx")
self.GetChild("level").SetFontColor(255, 43, 255)
self.GetChild("level").SetFontName(localeInfo.UI_DEF_FONT)
self.GetChild("name").SetFontName(localeInfo.UI_DEF_FONT)
self.GetChild("name").SetText(str(exchange.GetNameFromTarget()))
self.GetChild("lonca").SetFontName(localeInfo.UI_DEF_FONT)
self.GetChild("benim_name").SetFontColor(255*255, 0*255, 8*255)
(self.xStart, self.yStart, z) = player.GetMainCharacterPosition()
def CloseDialog(self):
wndMgr.OnceIgnoreMouseLeftButtonUpEvent()
if 0 != self.tooltipItem:
self.tooltipItem.HideToolTip()
self.dlgPickMoney.Close()
self.Hide()
def SetItemToolTip(self, tooltipItem):
self.tooltipItem = tooltipItem
def Owner_Kapat(self):
self.GetChild("Owner_Accept_Light").Hide()
def Owner_Ac(self):
self.GetChild("Owner_Accept_Light").Show()
def Owner_Kapat2(self):
self.GetChild("Target_Accept_Light").Hide()
def Owner_Ac2(self):
self.GetChild("Target_Accept_Light").Show()
def OpenPickMoneyDialog(self):
if exchange.GetElkFromSelf() > 0:
chat.AppendChat(chat.CHAT_TYPE_INFO, localeInfo.EXCHANGE_CANT_EDIT_MONEY)
return
self.dlgPickMoney.Open(player.GetElk())
def OnPickMoney(self, money):
net.SendExchangeElkAddPacket(money)
def AcceptExchange(self):
net.SendExchangeAcceptPacket()
self.AcceptButton.Disable()
def SelectOwnerEmptySlot(self, SlotIndex):
if False == mouseModule.mouseController.isAttached():
return
if mouseModule.mouseController.IsAttachedMoney():
net.SendExchangeElkAddPacket(mouseModule.mouseController.GetAttachedMoneyAmount())
else:
attachedSlotType = mouseModule.mouseController.GetAttachedType()
if (player.SLOT_TYPE_INVENTORY == attachedSlotType
or player.SLOT_TYPE_DRAGON_SOUL_INVENTORY == attachedSlotType):
attachedInvenType = player.SlotTypeToInvenType(attachedSlotType)
SrcSlotNumber = mouseModule.mouseController.GetAttachedSlotNumber()
DstSlotNumber = SlotIndex
itemID = player.GetItemIndex(attachedInvenType, SrcSlotNumber)
item.SelectItem(itemID)
if item.IsAntiFlag(item.ANTIFLAG_GIVE):
chat.AppendChat(chat.CHAT_TYPE_INFO, localeInfo.EXCHANGE_CANNOT_GIVE)
mouseModule.mouseController.DeattachObject()
return
net.SendExchangeItemAddPacket(attachedInvenType, SrcSlotNumber, DstSlotNumber)
mouseModule.mouseController.DeattachObject()
def SelectOwnerItemSlot(self, SlotIndex):
if player.ITEM_MONEY == mouseModule.mouseController.GetAttachedItemIndex():
money = mouseModule.mouseController.GetAttachedItemCount()
net.SendExchangeElkAddPacket(money)
def RefreshOwnerSlot(self):
for i in xrange(exchange.EXCHANGE_ITEM_MAX_NUM):
itemIndex = exchange.GetItemVnumFromSelf(i)
itemCount = exchange.GetItemCountFromSelf(i)
if 1 == itemCount:
itemCount = 0
self.OwnerSlot.SetItemSlot(i, itemIndex, itemCount)
self.OwnerSlot.RefreshSlot()
def RefreshTargetSlot(self):
for i in xrange(exchange.EXCHANGE_ITEM_MAX_NUM):
itemIndex = exchange.GetItemVnumFromTarget(i)
itemCount = exchange.GetItemCountFromTarget(i)
if 1 == itemCount:
itemCount = 0
self.TargetSlot.SetItemSlot(i, itemIndex, itemCount)
self.TargetSlot.RefreshSlot()
def Refresh(self):
self.RefreshOwnerSlot()
self.RefreshTargetSlot()
self.OwnerMoney.SetText(str(exchange.GetElkFromSelf()))
self.TargetMoney.SetText(str(exchange.GetElkFromTarget()))
if True == exchange.GetAcceptFromSelf():
self.OwnerAcceptLight.Down()
else:
self.AcceptButton.Enable()
self.AcceptButton.SetUp()
self.OwnerAcceptLight.SetUp()
if True == exchange.GetAcceptFromTarget():
self.TargetAcceptLight.Down()
else:
self.TargetAcceptLight.SetUp()
def OverInOwnerItem(self, slotIndex):
if 0 != self.tooltipItem:
self.tooltipItem.SetExchangeOwnerItem(slotIndex)
def OverInTargetItem(self, slotIndex):
if 0 != self.tooltipItem:
self.tooltipItem.SetExchangeTargetItem(slotIndex)
def OverOutItem(self):
if 0 != self.tooltipItem:
self.tooltipItem.HideToolTip()
def OnTop(self):
self.tooltipItem.SetTop()
def OnUpdate(self):
USE_EXCHANGE_LIMIT_RANGE = 1000
self.OwnerMoney.SetText(localeInfo.NumberToMoneyString(str(exchange.GetElkFromSelf())))
self.TargetMoney.SetText(localeInfo.NumberToMoneyString(str(exchange.GetElkFromTarget())))
(x, y, z) = player.GetMainCharacterPosition()
if abs(x - self.xStart) > USE_EXCHANGE_LIMIT_RANGE or abs(y - self.yStart) > USE_EXCHANGE_LIMIT_RANGE:
(self.xStart, self.yStart, z) = player.GetMainCharacterPosition()
net.SendExchangeExitPacket()
self.GetChild("karakter").LoadImage(FACE_IMAGE_DICT[constInfo.ticsinif])
self.GetChild("benim_karakter").LoadImage(FACE_IMAGE_DICT[net.GetMainActorRace()])
self.GetChild("benim_name").SetText(str(player.GetName()))
self.GetChild("lonca").SetText(str(constInfo.ticlonca))
self.GetChild("level").SetText("Lv." + str(constInfo.ticlevel))
uiscript
exchangedialog.py
Code:
import uiScriptLocale
ROOT = "d:/ymir work/ui/game/"
FACE_SLOT_FILE = "d:/ymir work/ui/game/windows/box_face.sub"
window = {
"name" : "ExchangeDialog",
"x" : 0,
"y" : 0,
"style" : ("movable", "float",),
"width" : 446-25-15,
"height" : 250-10-35,
"children" :
(
{
"name" : "board",
"type" : "board",
"style" : ("attach",),
"x" : 0,
"y" : 0,
"width" : 446-25-15,
"height" : 250-10-35,
"children" :
(
## Title
{
"name" : "TitleBar",
"type" : "titlebar",
"style" : ("attach",),
"x" : 8,
"y" : 8,
"width" : 446-12 - 51 + 10,
"color" : "gray",
"children" :
(
{ "name":"TitleName", "type":"text", "x":133+215-173+50+8 - 20 - 30 - 25 - 15 + 51, "y":3, "text":uiScriptLocale.EXCHANGE_TITLE, "text_horizontal_align":"center" },
),
},
#karakter bilgileri:
#Rakibin
{ "name" : "Face_Slot", "type" : "image", "x" : 15, "y" : 36, "image" : FACE_SLOT_FILE, },
{
"name" : "karakter",
"type" : "image",
"x" : 18,
"y" : 36+5,
"image" : "icon/face/warrior_m.tga",
},
{
"name" : "level",
"type" : "text",
"x" : 61+7,
"y" : 36,
"text" : "Lv. 0",
},
{
"name" : "name",
"type" : "text",
"x" : 104-16+7 + 4,
"y" : 36,
"text" : "Fatihbab34",
},
{
"name" : "lonca",
"type" : "text",
"x" : 61+7,
"y" : 50-7+11 - 5,
"text" : "TURKIYE",
},
#benim#
{ "name" : "Face_Slot2", "type" : "image", "x" : 240-3-15, "y" : 36, "image" : FACE_SLOT_FILE, },
{
"name" : "benim_karakter",
"type" : "image",
"x" : 240-15,
"y" : 36+5,
"image" : "icon/face/warrior_m.tga",
},
{
"name" : "benim_name",
"type" : "text",
"x" : 296 - 4-15,
"y" : 31 + 6,
"text" : "Sen",
},
## MiddleBar
{
"name" : "Middle_Bar",
"type" : "image",
"x" : 139 + 9000,
"y" : 31,
"image" : ROOT + "windows/middlebar.sub",
},
{
"name" : "Middle_Bar2",
"type" : "image",
"x" : 139+9000,
"y" : 95,
"image" : ROOT + "windows/middlebar.sub",
},
#yang dialog yeri
{
"name" : "Owner_Money",
"type" : "button",
"x" : 292-1-15,
"y" : 59+11-3,
"default_image" : "d:/ymir work/ui/public/parameter_slot_03.sub",
"over_image" : "d:/ymir work/ui/public/parameter_slot_03.sub",
"down_image" : "d:/ymir work/ui/public/parameter_slot_03.sub",
"children" :
(
{
"name" : "Owner_Money_Value",
"type" : "text",
"x" : 59 + 35 - 6,
"y" : 2,
"text" : "1234567",
"text_horizontal_align" : "right",
},
{
"name" : "Owner_Money_Value2",
"type" : "text",
"x" : 59+29 + 28 + 9000,#-
"y" : 2,
"text" : "Arany",
"text_horizontal_align" : "right",
},
),
},
## Owner
{
"name" : "Owner",
"type" : "window",
"x" : 234 + 6 + 15 - 15,
"y" : 87 + 15 - 10,
"width" : 130,
"height" : 130 + 96,
"children" :
(
{
"name" : "Owner_Slot",
"type" : "grid_table",
"x" : 0,
"y" : 0,
"start_index" : 0,
"x_count" : 4,
"y_count" : 3,
"x_step" : 32,
"y_step" : 32,
"x_blank" : 0,
"y_blank" : 0,
"image" : "d:/ymir work/ui/public/slot_base.sub",
},
),
},
{
"name" : "Owner_Accept_Light",#aktif hali eklenicek.
"type" : "button",
"x" : 292-1 + 92 - 15,
"y" : 59+11-3,
"default_image" : "d:/ymir work/ui/game/windows/accept_button_off.sub",
"over_image" : "d:/ymir work/ui/game/windows/accept_button_off.sub",
"down_image" : "d:/ymir work/ui/game/windows/accept_button_on.sub",
},
#{
# "name" : "Owner_Accept_Light",#aktif hali eklenicek.
# "type" : "toggle_button",
# "x" : 234 + 6 + 9000,
# "y" : 87 + 15 - 10,
# "default_image" : "locale/tr/ui/xd.tga",
# "over_image" : "locale/tr/ui/kabuletti.tga",
# "down_image" : "locale/tr/ui/kabuletti.tga",
#},
#kabulet
{
"name" : "Owner_Accept_Button",
"type" : "toggle_button",
"x" : 209 - 7 + 3 - 14 - 9 - 15,
"y" : 58+72,
"text" : "Elfogad",
#"default_image" : "locale/tr/ui/ticaret.tga",
#"over_image" : "locale/tr/ui/ticaret.tga",
#"down_image" : "locale/tr/ui/ticaret.tga",
"default_image" : "d:/ymir work/ui/public/middle_button_01.sub",
"over_image" : "d:/ymir work/ui/public/middle_button_02.sub",
"down_image" : "d:/ymir work/ui/public/middle_button_03.sub",
},
{
"name" : "Target_Money",
"type" : "image",
"x" : 62 + 6,
"y" : 56 + 9 + 2,
"image" : "d:/ymir work/ui/public/parameter_slot_03.sub",
"children" :
(
{
"name" : "Target_Money_Value",
"type" : "text",
"x" : 59+35-6,
"y" : 2,
"text" : "1234567",
"text_horizontal_align" : "right",
},
{
"name" : "Target_Money_Value2",
"type" : "text",
"x" : 59+29 + 28 + 9000,#-
"y" : 2,
"text" : "Arany",
"text_horizontal_align" : "right",
},
),
},
## Target
{
"name" : "Target",
"type" : "window",
"x" : 10 + 15,
"y" : 87 + 18 - 10,
"width" : 130,
"height" : 130 + 96,
"children" :
(
{
"name" : "Target_Slot",
"type" : "grid_table",
"x" : 0,
"y" : 0,
"start_index" : 0,
"x_count" : 4,
"y_count" : 3,
"x_step" : 32,
"y_step" : 32,
"x_blank" : 0,
"y_blank" : 0,
"image" : "d:/ymir work/ui/public/slot_base.sub",
},
),
},
{
"name" : "Target_Accept_Light", #aktif koyulcak
"type" : "button",
"x" : 62 + 6 + 92,
"y" : 56 + 9 + 2,
"default_image" : "d:/ymir work/ui/game/windows/accept_button_off.sub",
"over_image" : "d:/ymir work/ui/game/windows/accept_button_off.sub",
"down_image" : "d:/ymir work/ui/game/windows/accept_button_on.sub",
},
),
},
),
}
|
|
|
04/14/2015, 22:07
|
#24
|
elite*gold: 0
Join Date: Jul 2009
Posts: 19
Received Thanks: 0
|
Quote:
Originally Posted by AmerigoMendosa
40k client
image
root
constinfo.py
Code:
ticsinif = 0
ticlonca = ""
ticlevel = ""
game.py
Code:
def OnRecvWhisper(self, mode, name, line):
if line.find("xxbanasinifiniverxx") != -1:
race = net.GetMainActorRace()
if not guild.IsGuildEnable():
net.SendWhisperPacket(name, "xxbuyursinifimkardesimxx"+str(race)+"xx"+"Nincs céhben.xx"+str(player.GetStatus(player.LEVEL))+"xx")
else:
net.SendWhisperPacket(name, "xxbuyursinifimkardesimxx"+str(race)+"xx"+str(player.GetGuildName())+"xx"+str(player.GetStatus(player.LEVEL))+"xx")
return
if line.find("xxbuyursinifimkardesimxx") != -1:
constInfo.ticsinif = int(line.split("xx")[2])
constInfo.ticlonca = line.split("xx")[3]
constInfo.ticlevel = line.split("xx")[4]
return
if mode == chat.WHISPER_TYPE_GM:
self.interface.RegisterGameMasterName(name)
chat.AppendWhisper(mode, name, line)
self.interface.RecvWhisper(name)
uiexchange.py
Code:
import player
import exchange
import net
import localeInfo
import event
import chat
import item
import constInfo
import playerSettingModule
import ui
import mouseModule
import uiPickMoney
import wndMgr
###################################################################################################
## Exchange
FACE_IMAGE_DICT = {
playerSettingModule.RACE_WARRIOR_M : "icon/face/warrior_m.tga",
playerSettingModule.RACE_WARRIOR_W : "icon/face/warrior_w.tga",
playerSettingModule.RACE_ASSASSIN_M : "icon/face/assassin_m.tga",
playerSettingModule.RACE_ASSASSIN_W : "icon/face/assassin_w.tga",
playerSettingModule.RACE_SURA_M : "icon/face/sura_m.tga",
playerSettingModule.RACE_SURA_W : "icon/face/sura_w.tga",
playerSettingModule.RACE_SHAMAN_M : "icon/face/shaman_m.tga",
playerSettingModule.RACE_SHAMAN_W : "icon/face/shaman_w.tga",
}
class ExchangeDialog(ui.ScriptWindow):
def __init__(self):
ui.ScriptWindow.__init__(self)
self.TitleName = 0
self.tooltipItem = 0
self.xStart = 0
self.yStart = 0
def __del__(self):
ui.ScriptWindow.__del__(self)
def LoadDialog(self):
PythonScriptLoader = ui.PythonScriptLoader()
PythonScriptLoader.LoadScriptFile(self, "UIScript/exchangedialog.py")
## Owner
self.OwnerSlot = self.GetChild("Owner_Slot")
self.OwnerSlot.SetSelectEmptySlotEvent(ui.__mem_func__(self.SelectOwnerEmptySlot))
self.OwnerSlot.SetSelectItemSlotEvent(ui.__mem_func__(self.SelectOwnerItemSlot))
self.OwnerSlot.SetOverInItemEvent(ui.__mem_func__(self.OverInOwnerItem))
self.OwnerSlot.SetOverOutItemEvent(ui.__mem_func__(self.OverOutItem))
self.OwnerMoney = self.GetChild("Owner_Money_Value")
self.OwnerAcceptLight = self.GetChild("Owner_Accept_Light")
self.OwnerAcceptLight.Disable()
self.OwnerMoneyButton = self.GetChild("Owner_Money")
self.OwnerMoneyButton.SetEvent(ui.__mem_func__(self.OpenPickMoneyDialog))
## Target
self.TargetSlot = self.GetChild("Target_Slot")
self.TargetSlot.SetOverInItemEvent(ui.__mem_func__(self.OverInTargetItem))
self.TargetSlot.SetOverOutItemEvent(ui.__mem_func__(self.OverOutItem))
self.TargetMoney = self.GetChild("Target_Money_Value")
self.TargetAcceptLight = self.GetChild("Target_Accept_Light")
self.TargetAcceptLight.Disable()
## PickMoneyDialog
dlgPickMoney = uiPickMoney.PickMoneyDialog()
dlgPickMoney.LoadDialog()
dlgPickMoney.SetAcceptEvent(ui.__mem_func__(self.OnPickMoney))
dlgPickMoney.SetTitleName(localeInfo.EXCHANGE_MONEY)
dlgPickMoney.SetMax(9) ## 999.999.999 millió yang
#dlgPickMoney.SetMax(7) ## 9.999.999 millió yang
dlgPickMoney.Hide()
self.dlgPickMoney = dlgPickMoney
## Button
self.AcceptButton = self.GetChild("Owner_Accept_Button")
self.AcceptButton.SetToggleDownEvent(ui.__mem_func__(self.AcceptExchange))
self.TitleName = self.GetChild("TitleName")
self.GetChild("TitleBar").SetCloseEvent(net.SendExchangeExitPacket)
def Destroy(self):
print "---------------------------------------------------------------------------- DESTROY EXCHANGE"
self.ClearDictionary()
self.dlgPickMoney.Destroy()
self.dlgPickMoney = 0
self.OwnerSlot = 0
self.OwnerMoney = 0
self.OwnerAcceptLight = 0
self.OwnerMoneyButton = 0
self.TargetSlot = 0
self.TargetMoney = 0
self.TargetAcceptLight = 0
self.TitleName = 0
self.AcceptButton = 0
self.tooltipItem = 0
def OpenDialog(self):
self.TitleName.SetText(localeInfo.EXCHANGE_TITLE % (exchange.GetNameFromTarget()))
self.AcceptButton.Enable()
self.AcceptButton.SetUp()
self.Show()
net.SendWhisperPacket(exchange.GetNameFromTarget(), "xxbanasinifiniverxx")
self.GetChild("level").SetFontColor(255, 43, 255)
self.GetChild("level").SetFontName(localeInfo.UI_DEF_FONT)
self.GetChild("name").SetFontName(localeInfo.UI_DEF_FONT)
self.GetChild("name").SetText(str(exchange.GetNameFromTarget()))
self.GetChild("lonca").SetFontName(localeInfo.UI_DEF_FONT)
self.GetChild("benim_name").SetFontColor(255*255, 0*255, 8*255)
(self.xStart, self.yStart, z) = player.GetMainCharacterPosition()
def CloseDialog(self):
wndMgr.OnceIgnoreMouseLeftButtonUpEvent()
if 0 != self.tooltipItem:
self.tooltipItem.HideToolTip()
self.dlgPickMoney.Close()
self.Hide()
def SetItemToolTip(self, tooltipItem):
self.tooltipItem = tooltipItem
def Owner_Kapat(self):
self.GetChild("Owner_Accept_Light").Hide()
def Owner_Ac(self):
self.GetChild("Owner_Accept_Light").Show()
def Owner_Kapat2(self):
self.GetChild("Target_Accept_Light").Hide()
def Owner_Ac2(self):
self.GetChild("Target_Accept_Light").Show()
def OpenPickMoneyDialog(self):
if exchange.GetElkFromSelf() > 0:
chat.AppendChat(chat.CHAT_TYPE_INFO, localeInfo.EXCHANGE_CANT_EDIT_MONEY)
return
self.dlgPickMoney.Open(player.GetElk())
def OnPickMoney(self, money):
net.SendExchangeElkAddPacket(money)
def AcceptExchange(self):
net.SendExchangeAcceptPacket()
self.AcceptButton.Disable()
def SelectOwnerEmptySlot(self, SlotIndex):
if False == mouseModule.mouseController.isAttached():
return
if mouseModule.mouseController.IsAttachedMoney():
net.SendExchangeElkAddPacket(mouseModule.mouseController.GetAttachedMoneyAmount())
else:
attachedSlotType = mouseModule.mouseController.GetAttachedType()
if (player.SLOT_TYPE_INVENTORY == attachedSlotType
or player.SLOT_TYPE_DRAGON_SOUL_INVENTORY == attachedSlotType):
attachedInvenType = player.SlotTypeToInvenType(attachedSlotType)
SrcSlotNumber = mouseModule.mouseController.GetAttachedSlotNumber()
DstSlotNumber = SlotIndex
itemID = player.GetItemIndex(attachedInvenType, SrcSlotNumber)
item.SelectItem(itemID)
if item.IsAntiFlag(item.ANTIFLAG_GIVE):
chat.AppendChat(chat.CHAT_TYPE_INFO, localeInfo.EXCHANGE_CANNOT_GIVE)
mouseModule.mouseController.DeattachObject()
return
net.SendExchangeItemAddPacket(attachedInvenType, SrcSlotNumber, DstSlotNumber)
mouseModule.mouseController.DeattachObject()
def SelectOwnerItemSlot(self, SlotIndex):
if player.ITEM_MONEY == mouseModule.mouseController.GetAttachedItemIndex():
money = mouseModule.mouseController.GetAttachedItemCount()
net.SendExchangeElkAddPacket(money)
def RefreshOwnerSlot(self):
for i in xrange(exchange.EXCHANGE_ITEM_MAX_NUM):
itemIndex = exchange.GetItemVnumFromSelf(i)
itemCount = exchange.GetItemCountFromSelf(i)
if 1 == itemCount:
itemCount = 0
self.OwnerSlot.SetItemSlot(i, itemIndex, itemCount)
self.OwnerSlot.RefreshSlot()
def RefreshTargetSlot(self):
for i in xrange(exchange.EXCHANGE_ITEM_MAX_NUM):
itemIndex = exchange.GetItemVnumFromTarget(i)
itemCount = exchange.GetItemCountFromTarget(i)
if 1 == itemCount:
itemCount = 0
self.TargetSlot.SetItemSlot(i, itemIndex, itemCount)
self.TargetSlot.RefreshSlot()
def Refresh(self):
self.RefreshOwnerSlot()
self.RefreshTargetSlot()
self.OwnerMoney.SetText(str(exchange.GetElkFromSelf()))
self.TargetMoney.SetText(str(exchange.GetElkFromTarget()))
if True == exchange.GetAcceptFromSelf():
self.OwnerAcceptLight.Down()
else:
self.AcceptButton.Enable()
self.AcceptButton.SetUp()
self.OwnerAcceptLight.SetUp()
if True == exchange.GetAcceptFromTarget():
self.TargetAcceptLight.Down()
else:
self.TargetAcceptLight.SetUp()
def OverInOwnerItem(self, slotIndex):
if 0 != self.tooltipItem:
self.tooltipItem.SetExchangeOwnerItem(slotIndex)
def OverInTargetItem(self, slotIndex):
if 0 != self.tooltipItem:
self.tooltipItem.SetExchangeTargetItem(slotIndex)
def OverOutItem(self):
if 0 != self.tooltipItem:
self.tooltipItem.HideToolTip()
def OnTop(self):
self.tooltipItem.SetTop()
def OnUpdate(self):
USE_EXCHANGE_LIMIT_RANGE = 1000
self.OwnerMoney.SetText(localeInfo.NumberToMoneyString(str(exchange.GetElkFromSelf())))
self.TargetMoney.SetText(localeInfo.NumberToMoneyString(str(exchange.GetElkFromTarget())))
(x, y, z) = player.GetMainCharacterPosition()
if abs(x - self.xStart) > USE_EXCHANGE_LIMIT_RANGE or abs(y - self.yStart) > USE_EXCHANGE_LIMIT_RANGE:
(self.xStart, self.yStart, z) = player.GetMainCharacterPosition()
net.SendExchangeExitPacket()
self.GetChild("karakter").LoadImage(FACE_IMAGE_DICT[constInfo.ticsinif])
self.GetChild("benim_karakter").LoadImage(FACE_IMAGE_DICT[net.GetMainActorRace()])
self.GetChild("benim_name").SetText(str(player.GetName()))
self.GetChild("lonca").SetText(str(constInfo.ticlonca))
self.GetChild("level").SetText("Lv." + str(constInfo.ticlevel))
uiscript
exchangedialog.py
Code:
import uiScriptLocale
ROOT = "d:/ymir work/ui/game/"
FACE_SLOT_FILE = "d:/ymir work/ui/game/windows/box_face.sub"
window = {
"name" : "ExchangeDialog",
"x" : 0,
"y" : 0,
"style" : ("movable", "float",),
"width" : 446-25-15,
"height" : 250-10-35,
"children" :
(
{
"name" : "board",
"type" : "board",
"style" : ("attach",),
"x" : 0,
"y" : 0,
"width" : 446-25-15,
"height" : 250-10-35,
"children" :
(
## Title
{
"name" : "TitleBar",
"type" : "titlebar",
"style" : ("attach",),
"x" : 8,
"y" : 8,
"width" : 446-12 - 51 + 10,
"color" : "gray",
"children" :
(
{ "name":"TitleName", "type":"text", "x":133+215-173+50+8 - 20 - 30 - 25 - 15 + 51, "y":3, "text":uiScriptLocale.EXCHANGE_TITLE, "text_horizontal_align":"center" },
),
},
#karakter bilgileri:
#Rakibin
{ "name" : "Face_Slot", "type" : "image", "x" : 15, "y" : 36, "image" : FACE_SLOT_FILE, },
{
"name" : "karakter",
"type" : "image",
"x" : 18,
"y" : 36+5,
"image" : "icon/face/warrior_m.tga",
},
{
"name" : "level",
"type" : "text",
"x" : 61+7,
"y" : 36,
"text" : "Lv. 0",
},
{
"name" : "name",
"type" : "text",
"x" : 104-16+7 + 4,
"y" : 36,
"text" : "Fatihbab34",
},
{
"name" : "lonca",
"type" : "text",
"x" : 61+7,
"y" : 50-7+11 - 5,
"text" : "TURKIYE",
},
#benim#
{ "name" : "Face_Slot2", "type" : "image", "x" : 240-3-15, "y" : 36, "image" : FACE_SLOT_FILE, },
{
"name" : "benim_karakter",
"type" : "image",
"x" : 240-15,
"y" : 36+5,
"image" : "icon/face/warrior_m.tga",
},
{
"name" : "benim_name",
"type" : "text",
"x" : 296 - 4-15,
"y" : 31 + 6,
"text" : "Sen",
},
## MiddleBar
{
"name" : "Middle_Bar",
"type" : "image",
"x" : 139 + 9000,
"y" : 31,
"image" : ROOT + "windows/middlebar.sub",
},
{
"name" : "Middle_Bar2",
"type" : "image",
"x" : 139+9000,
"y" : 95,
"image" : ROOT + "windows/middlebar.sub",
},
#yang dialog yeri
{
"name" : "Owner_Money",
"type" : "button",
"x" : 292-1-15,
"y" : 59+11-3,
"default_image" : "d:/ymir work/ui/public/parameter_slot_03.sub",
"over_image" : "d:/ymir work/ui/public/parameter_slot_03.sub",
"down_image" : "d:/ymir work/ui/public/parameter_slot_03.sub",
"children" :
(
{
"name" : "Owner_Money_Value",
"type" : "text",
"x" : 59 + 35 - 6,
"y" : 2,
"text" : "1234567",
"text_horizontal_align" : "right",
},
{
"name" : "Owner_Money_Value2",
"type" : "text",
"x" : 59+29 + 28 + 9000,#-
"y" : 2,
"text" : "Arany",
"text_horizontal_align" : "right",
},
),
},
## Owner
{
"name" : "Owner",
"type" : "window",
"x" : 234 + 6 + 15 - 15,
"y" : 87 + 15 - 10,
"width" : 130,
"height" : 130 + 96,
"children" :
(
{
"name" : "Owner_Slot",
"type" : "grid_table",
"x" : 0,
"y" : 0,
"start_index" : 0,
"x_count" : 4,
"y_count" : 3,
"x_step" : 32,
"y_step" : 32,
"x_blank" : 0,
"y_blank" : 0,
"image" : "d:/ymir work/ui/public/slot_base.sub",
},
),
},
{
"name" : "Owner_Accept_Light",#aktif hali eklenicek.
"type" : "button",
"x" : 292-1 + 92 - 15,
"y" : 59+11-3,
"default_image" : "d:/ymir work/ui/game/windows/accept_button_off.sub",
"over_image" : "d:/ymir work/ui/game/windows/accept_button_off.sub",
"down_image" : "d:/ymir work/ui/game/windows/accept_button_on.sub",
},
#{
# "name" : "Owner_Accept_Light",#aktif hali eklenicek.
# "type" : "toggle_button",
# "x" : 234 + 6 + 9000,
# "y" : 87 + 15 - 10,
# "default_image" : "locale/tr/ui/xd.tga",
# "over_image" : "locale/tr/ui/kabuletti.tga",
# "down_image" : "locale/tr/ui/kabuletti.tga",
#},
#kabulet
{
"name" : "Owner_Accept_Button",
"type" : "toggle_button",
"x" : 209 - 7 + 3 - 14 - 9 - 15,
"y" : 58+72,
"text" : "Elfogad",
#"default_image" : "locale/tr/ui/ticaret.tga",
#"over_image" : "locale/tr/ui/ticaret.tga",
#"down_image" : "locale/tr/ui/ticaret.tga",
"default_image" : "d:/ymir work/ui/public/middle_button_01.sub",
"over_image" : "d:/ymir work/ui/public/middle_button_02.sub",
"down_image" : "d:/ymir work/ui/public/middle_button_03.sub",
},
{
"name" : "Target_Money",
"type" : "image",
"x" : 62 + 6,
"y" : 56 + 9 + 2,
"image" : "d:/ymir work/ui/public/parameter_slot_03.sub",
"children" :
(
{
"name" : "Target_Money_Value",
"type" : "text",
"x" : 59+35-6,
"y" : 2,
"text" : "1234567",
"text_horizontal_align" : "right",
},
{
"name" : "Target_Money_Value2",
"type" : "text",
"x" : 59+29 + 28 + 9000,#-
"y" : 2,
"text" : "Arany",
"text_horizontal_align" : "right",
},
),
},
## Target
{
"name" : "Target",
"type" : "window",
"x" : 10 + 15,
"y" : 87 + 18 - 10,
"width" : 130,
"height" : 130 + 96,
"children" :
(
{
"name" : "Target_Slot",
"type" : "grid_table",
"x" : 0,
"y" : 0,
"start_index" : 0,
"x_count" : 4,
"y_count" : 3,
"x_step" : 32,
"y_step" : 32,
"x_blank" : 0,
"y_blank" : 0,
"image" : "d:/ymir work/ui/public/slot_base.sub",
},
),
},
{
"name" : "Target_Accept_Light", #aktif koyulcak
"type" : "button",
"x" : 62 + 6 + 92,
"y" : 56 + 9 + 2,
"default_image" : "d:/ymir work/ui/game/windows/accept_button_off.sub",
"over_image" : "d:/ymir work/ui/game/windows/accept_button_off.sub",
"down_image" : "d:/ymir work/ui/game/windows/accept_button_on.sub",
},
),
},
),
}
|
0414 23:06:11702 ::
networkModule.py(line:208) SetSelectCharacterPhase
system.py(line:130) __pack_import
system.py(line:110) _process_result
introSelect.py(line:30) ?
system.py(line:130) __pack_import
system.py(line:110) _process_result
interfaceModule.py(line:23) ?
system.py(line:130) __pack_import
networkModule.SetSelectCharacterPhase - exceptions.SyntaxError:invalid syntax (line 259)
0414 23:06:11703 :: ================================================== ================================================== ========
0414 23:06:11703 :: Abort!!!!
|
|
|
05/01/2015, 12:33
|
#25
|
elite*gold: 0
Join Date: Mar 2010
Posts: 10
Received Thanks: 1
|
40K +
uiexchange.py
Code:
import player
import exchange
import net
import localeInfo
import event
import chat
import item
import constInfo
import playerSettingModule
import ui
import mouseModule
import uiPickMoney
import wndMgr
FACE_IMAGE_DICT = {
playerSettingModule.RACE_WARRIOR_M : "icon/face/warrior_m.tga",
playerSettingModule.RACE_WARRIOR_W : "icon/face/warrior_w.tga",
playerSettingModule.RACE_ASSASSIN_M : "icon/face/assassin_m.tga",
playerSettingModule.RACE_ASSASSIN_W : "icon/face/assassin_w.tga",
playerSettingModule.RACE_SURA_M : "icon/face/sura_m.tga",
playerSettingModule.RACE_SURA_W : "icon/face/sura_w.tga",
playerSettingModule.RACE_SHAMAN_M : "icon/face/shaman_m.tga",
playerSettingModule.RACE_SHAMAN_W : "icon/face/shaman_w.tga",
}
class ExchangeDialog(ui.ScriptWindow):
def __init__(self):
ui.ScriptWindow.__init__(self)
self.TitleName = 0
self.tooltipItem = 0
self.xStart = 0
self.yStart = 0
def __del__(self):
ui.ScriptWindow.__del__(self)
def LoadDialog(self):
PythonScriptLoader = ui.PythonScriptLoader()
PythonScriptLoader.LoadScriptFile(self, "UIScript/exchangedialog.py")
self.OwnerSlot = self.GetChild("Owner_Slot")
self.OwnerSlot.SetSelectEmptySlotEvent(ui.__mem_func__(self.SelectOwnerEmptySlot))
self.OwnerSlot.SetSelectItemSlotEvent(ui.__mem_func__(self.SelectOwnerItemSlot))
self.OwnerSlot.SetOverInItemEvent(ui.__mem_func__(self.OverInOwnerItem))
self.OwnerSlot.SetOverOutItemEvent(ui.__mem_func__(self.OverOutItem))
self.OwnerMoney = self.GetChild("Owner_Money_Value")
self.OwnerAcceptLight = self.GetChild("Owner_Accept_Light")
self.OwnerAcceptLight.Disable()
self.OwnerMoneyButton = self.GetChild("Owner_Money")
self.OwnerMoneyButton.SetEvent(ui.__mem_func__(self.OpenPickMoneyDialog))
self.TargetSlot = self.GetChild("Target_Slot")
self.TargetSlot.SetOverInItemEvent(ui.__mem_func__(self.OverInTargetItem))
self.TargetSlot.SetOverOutItemEvent(ui.__mem_func__(self.OverOutItem))
self.TargetMoney = self.GetChild("Target_Money_Value")
self.TargetAcceptLight = self.GetChild("Target_Accept_Light")
self.TargetAcceptLight.Disable()
dlgPickMoney = uiPickMoney.PickMoneyDialog()
dlgPickMoney.LoadDialog()
dlgPickMoney.SetAcceptEvent(ui.__mem_func__(self.OnPickMoney))
dlgPickMoney.SetTitleName(localeInfo.EXCHANGE_MONEY)
dlgPickMoney.SetMax(8) ## 99.999.999 millió yang
#dlgPickMoney.SetMax(9) ## 999.999.999 millió yang
dlgPickMoney.Hide()
self.dlgPickMoney = dlgPickMoney
self.AcceptButton = self.GetChild("Owner_Accept_Button")
self.AcceptButton.SetToggleDownEvent(ui.__mem_func__(self.AcceptExchange))
self.TitleName = self.GetChild("TitleName")
self.GetChild("TitleBar").SetCloseEvent(net.SendExchangeExitPacket)
def Destroy(self):
print "---------------------------------------------------------------------------- DESTROY EXCHANGE"
self.ClearDictionary()
self.dlgPickMoney.Destroy()
self.dlgPickMoney = 0
self.OwnerSlot = 0
self.OwnerMoney = 0
self.OwnerAcceptLight = 0
self.OwnerMoneyButton = 0
self.TargetSlot = 0
self.TargetMoney = 0
self.TargetAcceptLight = 0
self.TitleName = 0
self.AcceptButton = 0
self.tooltipItem = 0
def OpenDialog(self):
self.TitleName.SetText(localeInfo.EXCHANGE_TITLE_FATIHBAB34)
self.AcceptButton.Enable()
self.AcceptButton.SetUp()
self.Show()
net.SendWhisperPacket(exchange.GetNameFromTarget(), "xxbanasinifiniverxx")
self.GetChild("level").SetFontColor(255, 43, 255)
self.GetChild("level").SetFontName(localeInfo.UI_DEF_FONT)
self.GetChild("name").SetFontName(localeInfo.UI_DEF_FONT)
self.GetChild("name").SetText(str(exchange.GetNameFromTarget()))
self.GetChild("lonca").SetFontName(localeInfo.UI_DEF_FONT)
self.GetChild("benim_name").SetFontColor(255*255, 0*255, 8*255)
(self.xStart, self.yStart, z) = player.GetMainCharacterPosition()
def CloseDialog(self):
wndMgr.OnceIgnoreMouseLeftButtonUpEvent()
if 0 != self.tooltipItem:
self.tooltipItem.HideToolTip()
self.dlgPickMoney.Close()
self.Hide()
def SetItemToolTip(self, tooltipItem):
self.tooltipItem = tooltipItem
def Owner_Kapat(self):
self.GetChild("Owner_Accept_Light").Hide()
def Owner_Ac(self):
self.GetChild("Owner_Accept_Light").Show()
def Owner_Kapat2(self):
self.GetChild("Target_Accept_Light").Hide()
def Owner_Ac2(self):
self.GetChild("Target_Accept_Light").Show()
def OpenPickMoneyDialog(self):
if exchange.GetElkFromSelf() > 0:
chat.AppendChat(chat.CHAT_TYPE_INFO, localeInfo.EXCHANGE_CANT_EDIT_MONEY)
return
self.dlgPickMoney.Open(player.GetElk())
def OnPickMoney(self, money):
net.SendExchangeElkAddPacket(money)
def AcceptExchange(self):
net.SendExchangeAcceptPacket()
self.AcceptButton.Disable()
def SelectOwnerEmptySlot(self, SlotIndex):
if False == mouseModule.mouseController.isAttached():
return
if mouseModule.mouseController.IsAttachedMoney():
net.SendExchangeElkAddPacket(mouseModule.mouseController.GetAttachedMoneyAmount())
else:
attachedSlotType = mouseModule.mouseController.GetAttachedType()
if (player.SLOT_TYPE_INVENTORY == attachedSlotType
or player.SLOT_TYPE_DRAGON_SOUL_INVENTORY == attachedSlotType):
attachedInvenType = player.SlotTypeToInvenType(attachedSlotType)
SrcSlotNumber = mouseModule.mouseController.GetAttachedSlotNumber()
DstSlotNumber = SlotIndex
itemID = player.GetItemIndex(attachedInvenType, SrcSlotNumber)
item.SelectItem(itemID)
if item.IsAntiFlag(item.ANTIFLAG_GIVE):
chat.AppendChat(chat.CHAT_TYPE_INFO, localeInfo.EXCHANGE_CANNOT_GIVE)
mouseModule.mouseController.DeattachObject()
return
net.SendExchangeItemAddPacket(attachedInvenType, SrcSlotNumber, DstSlotNumber)
mouseModule.mouseController.DeattachObject()
def SelectOwnerItemSlot(self, SlotIndex):
if player.ITEM_MONEY == mouseModule.mouseController.GetAttachedItemIndex():
money = mouseModule.mouseController.GetAttachedItemCount()
net.SendExchangeElkAddPacket(money)
def RefreshOwnerSlot(self):
for i in xrange(exchange.EXCHANGE_ITEM_MAX_NUM):
itemIndex = exchange.GetItemVnumFromSelf(i)
itemCount = exchange.GetItemCountFromSelf(i)
if 1 == itemCount:
itemCount = 0
self.OwnerSlot.SetItemSlot(i, itemIndex, itemCount)
self.OwnerSlot.RefreshSlot()
def RefreshTargetSlot(self):
for i in xrange(exchange.EXCHANGE_ITEM_MAX_NUM):
itemIndex = exchange.GetItemVnumFromTarget(i)
itemCount = exchange.GetItemCountFromTarget(i)
if 1 == itemCount:
itemCount = 0
self.TargetSlot.SetItemSlot(i, itemIndex, itemCount)
self.TargetSlot.RefreshSlot()
def Refresh(self):
self.RefreshOwnerSlot()
self.RefreshTargetSlot()
self.OwnerMoney.SetText(localeInfo.NumberToMoneyString(str(exchange.GetElkFromSelf())))
self.TargetMoney.SetText(localeInfo.NumberToMoneyString(str(exchange.GetElkFromTarget())))
if TRUE == exchange.GetAcceptFromSelf():
self.OwnerAcceptLight.Down()
else:
self.AcceptButton.Enable()
self.AcceptButton.SetUp()
self.OwnerAcceptLight.SetUp()
if TRUE == exchange.GetAcceptFromTarget():
self.TargetAcceptLight.Down()
else:
self.TargetAcceptLight.SetUp()
def OverInOwnerItem(self, slotIndex):
if 0 != self.tooltipItem:
self.tooltipItem.SetExchangeOwnerItem(slotIndex)
def OverInTargetItem(self, slotIndex):
if 0 != self.tooltipItem:
self.tooltipItem.SetExchangeTargetItem(slotIndex)
def OverOutItem(self):
if 0 != self.tooltipItem:
self.tooltipItem.HideToolTip()
def OnTop(self):
self.tooltipItem.SetTop()
def OnUpdate(self):
USE_EXCHANGE_LIMIT_RANGE = 1000
self.OwnerMoney.SetText(localeInfo.NumberToMoneyString(str(exchange.GetElkFromSelf())))
self.TargetMoney.SetText(localeInfo.NumberToMoneyString(str(exchange.GetElkFromTarget())))
(x, y, z) = player.GetMainCharacterPosition()
if abs(x - self.xStart) > USE_EXCHANGE_LIMIT_RANGE or abs(y - self.yStart) > USE_EXCHANGE_LIMIT_RANGE:
(self.xStart, self.yStart, z) = player.GetMainCharacterPosition()
net.SendExchangeExitPacket()
self.GetChild("karakter").LoadImage(FACE_IMAGE_DICT[constInfo.ticsinif])
self.GetChild("benim_karakter").LoadImage(FACE_IMAGE_DICT[net.GetMainActorRace()])
self.GetChild("benim_name").SetText(str(player.GetName()))
self.GetChild("lonca").SetText(str(constInfo.ticlonca))
self.GetChild("level").SetText("Lv." + str(constInfo.ticlevel))
|
|
|
11/06/2015, 16:49
|
#26
|
elite*gold: 0
Join Date: Jul 2013
Posts: 8
Received Thanks: 0
|
24 slot's please men
|
|
|
11/07/2015, 16:06
|
#27
|
elite*gold: 0
Join Date: Jun 2013
Posts: 1
Received Thanks: 0
|
I can not give add items to trade :S
|
|
|
11/08/2015, 12:51
|
#28
|
elite*gold: 0
Join Date: Jul 2013
Posts: 8
Received Thanks: 0
|
Quote:
Originally Posted by endox93
I can not give add items to trade :S
|
Yes
Yes ;(
|
|
|
11/08/2015, 15:45
|
#29
|
elite*gold: 0
Join Date: Jul 2011
Posts: 9
Received Thanks: 0
|
ONE BUG:
Drag item to slot... Accept... Close Window... Open Handel
|
|
|
11/08/2015, 16:16
|
#30
|
elite*gold: 0
Join Date: Feb 2014
Posts: 478
Received Thanks: 564
|
Danke für das Release sieht echt toll aus.
Lg.
|
|
|
Similar Threads
|
[RELEASE]Group PM System - Fatihbab34™
02/03/2018 - Metin2 PServer Guides & Strategies - 73 Replies
KF-Works.Tk
Hi. We will release "Group PM Release"
For much more : KF-Works.Tk
Note : if you want have a ready "uiwhisper.py and whisperdialog.py
------------------------------------------------- --------------------
|
[RELEASE] OXO-System(Tic tac toe) > by Fatihbab34™
06/08/2015 - Metin2 PServer Guides & Strategies - 11 Replies
Hello! epvp. i want to share you Oxo-System.
!* i did only for my beta server.so you can only 1 times.
!* System is for 2 player.
http://i.hizliresim.com/8l6PzA.png
*video
https://www.youtube.com/watch?v=dwJUf7_P3GM
|
All times are GMT +2. The time now is 01:10.
|
|