Jump to content
Korean Random

Technowolf

User
  • Content Count

    3
  • Joined

  • Last visited

Community Reputation

0 Noob

Contacts

  • Nick
    Technowolf
  1. Hy again :) Is there a simple way to add a custom menu entry inside of the garage menu ? I would like to integrate the testwindow to this menu entry and open it with a click on that custom point instead of a key triggered action. Hope someone can help me with this. And btw happy patchday EU :D
  2. Thx a lot managed to get it the way it should be :) Is there an easy way to change the coloring and / or background of the System message ? I just had a look at the messenger.xml file wich should do the job. Are there any other types of system messages i could use for this kind of announcement ? Edit: Solved the problem by defining a new type of system message and editing the messenger.xml afterwards
  3. I´ve managed to get an Service record message tab wich notifies about live streaming Clan Members. I would like to annouce live streaming with a little message wich is working by now. Last thing is i would like this message not to show up if the selected streamer is offline wich should be handled witch the else function. import BigWorld import os from debug_utils import * import GUI import ResMgr import json import urllib2 import urllib, socket from xml.dom.minidom import parseString from subprocess import check_output import json ap_cr_channel = '<a href="event:http://www.twitch.tv/jeff_ich_heisse_jeff_"><font color="#E2D2A2">Watch now</font></a>' try: url = 'http://cloud1.odemmortis.com/scripts/jeffapi.php' file = urllib.urlopen('http://cloud1.odemmortis.com/scripts/jeffapi.php') data = file.read() file.close() except: LOG_ERROR('Unable to access Remote File') from gui import SystemMessages sys_msg = '' def modpack(): try: if len(sys_msg) != 0: if SystemMessages.g_instance is None: BigWorld.callback(4.0, modpack) elif data == 'online': SystemMessages.pushMessage(sys_msg, type=SystemMessages.SM_TYPE.Information) else: SystemMessages.pushMessage(sys_msg, type=SystemMessages.SM_TYPE.Warning) except: LOG_CURRENT_EXCEPTION() return if data == 'online': sys_msg = '<font color="#7FCF00">Jeff ist live ON AIR ' + ap_cr_channel else: sys_msg = '<font color="#FF0000">Jeff ist OFFLINE!' from Account import Account def _First(msg): SystemMessages.pushMessage(msg, SystemMessages.SM_TYPE.Warning) def new_onBecomePlayer(self): old_onBecomePlayer(self) _First(sys_msg) old_onBecomePlayer = Account.onBecomePlayer Account.onBecomePlayer = new_onBecomePlayer could anybody help me with this ? I tried to simply remove the red marked else function but the result wasnt that great else: sys_msg = '<font color="#FF0000">Jeff ist OFFLINE!' Long story shor: Would like to have an message when streamer is online and no message if he is not. Thanks a lot guys
×
×
  • Create New...