Jump to content

kforce

Inactive Member
  • Posts

    8
  • Joined

  • Last visited

  • Feedback

    0%

Posts posted by kforce

  1. uidt.py: 

    import ui
    import snd
    import systemSetting
    import net
    import chat
    import app
    import locale
    import chrmgr
    import uiWhisper
    import interfacemodule
    import time
    import wndMgr
    
    class DemonTowerDialog(ui.ScriptWindow):
    
    	def __init__(self):
    		ui.ScriptWindow.__init__(self)
    		self.eventClose = None
    		self.__Load()
    		
    	def __del__(self):
    		ui.ScriptWindow.__del__(self)
    
    	def Destroy(self):
    		self.Hide()
    		return TRUE
    		
    	def __Load_LoadScript(self, fileName):
    		try:
    			pyScriptLoader = ui.PythonScriptLoader()
    			pyScriptLoader.LoadScriptFile(self, fileName)
    		except:
    			import exception
    			exception.Abort("DemonTowerDialog.__Load_LoadScript")
    
    	def __Load_BindObject(self):
    		try:
    			self.board = self.GetChild("titlebar")
    			self.timer = self.GetChild("timer")
    			self.img = self.GetChild("img")
    			self.counter = self.GetChild("counter")
    			self.counter2 = self.GetChild("counter2")
    			self.counter3 = self.GetChild("counter3")
    			self.counter4 = self.GetChild("counter4")
    			self.counter5 = self.GetChild("counter5")
    		except:
    			import exception
    			exception.Abort("DemonTowerDialog.__Load_BindObject")
    		
    		self.board.SetCloseEvent(ui.__mem_func__(self.Close))
    
    	def __Load(self):
    		self.__Load_LoadScript("uiscript/dtboard.py")
    		self.__Load_BindObject()
    		width = wndMgr.GetScreenWidth()
    		height = wndMgr.GetScreenHeight()
    	
    	def Show(self):
    		ui.ScriptWindow.Show(self)
    		
    	def SetData(self,data):
    		split = data.split('|')
    		self.timer.SetText(str(split[0]))
    		self.counter.SetText(str(split[1]))
    		self.counter2.SetText(str(split[2]))
    		self.counter3.SetText(str(split[3]))
    		self.counter4.SetText(str(split[4]))
    		self.counter5.SetText(str(split[5]))
    	
    	def SetCloseEvent(self, event):
    		self.eventClose = event
    		
    	def Close(self):
    		self.Hide()
    		if self.eventClose:
    			self.eventClose(self.vid)	
    		return TRUE
    		
    	def OnPressEscapeKey(self):
    		self.Hide()
    		return TRUE
  2. With the function item.set_value() we can set a attr bonus to an item, but my question is if we can get what bonus are on that item, i know that exists a function called item.get_value() but this doesn't seem to return the attr bonus. Alto, the argument that we need to set on that function is limited to 5.

    7N8r4.jpg

     

     

    quest test begin
    	state start begin
    		when 9003.take begin
    			for i = 0,5 do
    				say(i..": "..item.get_value(i))
    			end
    		end
    	end
    end

    I used this simple code to get all the values of a item, and thats what i got from a black steel armour+9 without any attr:

    7Na6s.jpg

     

     

    Am i using it right? Or this function simply doesn't return the attr bonus?

  3.  

    Didnt work for me. :

     

    7no56.png

    Full log: http://pastebin.com/cBVtuMLx

    16>.AffectFlagContainer.cpp(68) : error C2440: 'initializing' : cannot convert from 'CAffectFlagContainer::Element' to 'char &'

    Right click on the BYTE and click Go to Definition and change the char to unsigned char.

    6>.PythonGraphic.cpp(294) : error C2664: 'CPythonGraphic::SaveJPEG' : cannot convert parameter 2 from 'char *' to 'LPBYTE'

    Double click on the error and change the line to this:

    bool bSaved = SaveJPEG(c_pszFileName, (LPBYTE)pbyBuffer, uWidth, uHeight);

    Thanks!

    But now i have another problem, i get this error when i try to open the game with the compiled binary:

    7oM2e.jpg

     

    Im using the 40250 Test Client

  4. I do that long time ago.

    I just share if someone have problems with switch bot, that solve the problem.

     

    #Quest edited

    This doesnt solve the problem, its easy to bypass this "protection".

    • Love 3
×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.