original mods thread on forum of RU-Tera - http://forum.tera-online.ru/topic/22838/ new english thread - https://www.undertow.club/threads/owyns-tera-ui-mods-elin-gunner-update.11709/ software used: FFDEC, WinHex, TeraHelper ( https://github.com/GoneUp/GPK_RePack/releases ), UTHelper, Paint.net example tutorial on using FFDEC+terahelper to do code edits: https://github.com/neowutran/S1UI_chat2/wiki // some swf specs: // http://www-lehre.inf.uos.de/~fbstark/diplom/docs/swf/BasicTypes.htm The ScaleX, ScaleY, RotateSkew0 and RotateSkew1 fields are stored as 16.16 fixed-point values. The TranslateX and TranslateY values are stored as signed values in twips. ///////////// S1UI_Message disable lock-on message when you use a lock skill replace: else if(type == 44) // line 551 { mLockOn.id = id; totalMsg_array.push(mLockOn); mLockOn.mText.textField.text = msg; mLockOn.gotoAndPlay(2); mLockOn._visible = true; } with if(type == 44) { return undefined; } ///////////// move message when ppl lock onto you to center: lockOnContainer._y = lib.info.AlignInfo.yRatioToPixel(70); // line 697 to lockOnContainer._y = lib.info.AlignInfo.yRatioToPixel(45); && party notice to center staticMessageContainer._y = lib.info.AlignInfo.yRatioToPixel(80); to staticMessageContainer._y = lib.info.AlignInfo.yRatioToPixel(55); ///////////// max killed lines change var maxBFLine = 3; to var maxBFLine = 5; ///////////// remove skill resets (via option F disabling) and applied effects/glyphs add after: myListener.OnGame_SystemMessage_Add = function(str, color, container, maxLine, size) { // line 725 if(!bShowType4 || str.indexOf("сброшено") == -1 && str.indexOf("reset") == -1) { if(size == undefined || size == "undefined" || size == "") { if(color == undefined || color == "undefined" || color == "" || color == 0) { if(str.indexOf("<") < 0) { return undefined; } } } if(str.indexOf("получает звание") >= 0) { return undefined; } if(str.indexOf("успешно зачаровал(а)") >= 0) { return undefined; } if(str.indexOf("получил(а)") >= 0) { return undefined; } if(str.indexOf("enchanted") >= 0) { return undefined; } if(str.indexOf("obtained") >= 0) { return undefined; } } ///////////// S1UI_Message (old) disable system messages: if(type == 1) { ... } // Line 1637 / change to if(type == 1) { return undefined; } = Push register18 1 Equals2 Not If label Push undefined Return label: ///////////// disable lock-on messages: if(type == 3) { ... } // Line 1645 / change to else if(type == 3) { if(Arguments == "0\t26\t0xFF9900" && msg.indexOf("size=") == -1) { return undefined; } addStaticMsg(id,msg,addParam[0],addParam[1],addParam[2]); } = Push register13 "0\t26\t0xFF9900" Equals2 PushDuplicate Not If label3 Pop Push "size=" 1 "msg" GetVariable Push "indexOf" CallMethod Push -1 Equals2 label3:Not If label4 Push undefined Return label4: ///////////// add debug information: var addParam = Arguments.split("\t"); } // Line 1637 / insert before myListener.OnGame_SystemMessage_Add(type + "\t" + Arguments + "\t" + msg,10040064,systemMessageContainer); = Push "systemMessageContainer" GetVariable Push 10040064 register18 "\t" Add2 Push register13 Add2 Push "\t" Add2 Push "msg" GetVariable Add2 Push 3 "myListener" GetVariable Push "OnGame_SystemMessage_Add" CallMethod Pop && _loc1_.txt.htmlText = str; // line 2184 to _loc1_.txt.text = str; ///////////// remove background: rewardBg texture ///////////// remove hotkey background: Message_I113 texture & text Pbtn text (edit it out) ///////////// pushBFMessage - remove BattleField kill messages ////////////// S1UI_Crosshair remove lock-on animation: _loc1_ = container_mc.attachMovie("lockMc","lockMc",3); // Line 220 _loc1_._x = 0; _loc1_._y = 0; var _loc2_ = _loc1_.attachMovie("lockonMc","lockonMc",_loc1_.getNextHighestDepth()); gs.TweenLite.to(_loc2_,0.2,{_width:76,_height:76,onComplete:playLockOn,onCompleteParams:[_loc1_]}); container_mc.lockNumFd._visible = true; to *nothing* = 961000070300000008620862070300000008001c9602000819528701000117960d000401081a0600000000000000004f960d000401081b0600000000000000004f960d000600000000000000000401081752960d00086308630703000000040108195287010002179612000864074c0000000865074c000000086608671c96090008680401070100000042960500070400000043961200069999c93f9a9999990402070300000008691c960200086a4e960200086b5217 to 020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202 & avoid removing normal crosshair container_mc.clear(); // Line 237 to *nothing* = 960b0006000000000000000008001c96020008015217 to 02020202020202020202020202020202020202020202 & avoid overlapping normal crosshair with itself lib.display.DrawBitmapData.draw(container_mc,UI[type + "BgBm"],UI[type + "Pos"],UI[type + "Pos"],0,0,UI[type + "Size"],UI[type + "Size"]); to *nothing* = 96020008021c96020008031c9602000804474e96020008021c96020008031c9602000804474e96140006000000000000000006000000000000000008021c96020008031c9602000805474e96020008021c96020008031c9602000805474e96020008021c96020008031c9602000806474e96020008001c960700070800000008071c96020008084e96020008094e960200080a5217 (3rd occur only) to 0202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202 ////////////// S1UI_Abnormality enlarge stack count text:
0
// DefineEditText(11) to0
&& Ymax to 500 && fontHeight to 400 & move it a bit to top: TranslateY = 480 // PlaceObject3 (11) in DefineSprite (107) to TranslateY = 350 change font from numberFont to normalFont: // (like it was before awekening update) $NumberFont // Other -> importassets2 -> string=GfxFontLib.swf to $NormalFont ///////////// S1UI_PaperDoll make dungeon clears visible: _loc1_.countFd._visible = visibleCount == "1"; // line 2024 to _loc1_.countFd._visible = "1"; = Push register1 "countFd" GetMember Push "_visible" "1" SetMember ///////////// S1UI_EpWindow make talents level numbers visible: container_mc.persentTxt.text = _loc2_ + "%"; // line 705 to container_mc.persentTxt.text = exp.split("\t").join(" / ") + " ( " + _loc2_ + "% )"; container_mc.persentTxt.autoSize = "center"; ///////////// S1UI_PCInventory autohide panel on character action: container_mc.titleFd._visible = bShow; // Line 13 to container_mc._visible = bShow; = 960200080B4E960400080C04 to 020202020202960400080C04 ///////////// remove background: container_mc.titleFd._visible = true; // Line 133 to container_mc.titleFd._visible = false; = 4e960400080C0501 to 4e960400080C0500 ///////////// remove draglimit to right: container_mc.UIDrager.adjustDragLimit(0,3000,0,0); = Push 0 0 3000 0 4 "container_mc" GetVariable Push "UIDrager" GetMember Push "adjustDragLimit" CallMethod Pop ///////////// S1UI_MainMenu invisible mainmenu border: 4F 96 02 00 08 07 1C 12 9D 02 00 63 00 96 0B 00 08 69 07 64 00 00 00 08 42 08 3F 1C 96 02 00 08 43 4E 96 02 00 08 44 4E 96 02 00 08 45 4E 96 0C 00 08 7F 07 01 00 00 00 07 03 00 00 00 43 96 0B 00 06 33 33 D3 3F 33 33 33 33 08 08 1C 96 02 00 08 38 4E 96 07 00 07 03 00 00 00 08 3F 1C 96 02 00 08 40 4E 96 02 00 08 46 52 17 99 02 00 58 00 to 4F 02 02 02 02 02 02 02 02 02 02 02 02 96 0B 00 08 69 07 00 00 00 00 08 42 08 3F 1C 96 02 00 08 43 4E 96 02 00 08 44 4E 96 02 00 08 45 4E 96 0C 00 08 7F 07 01 00 00 00 07 03 00 00 00 43 96 0B 00 06 33 33 D3 3F 33 33 33 33 08 08 1C 96 02 00 08 38 4E 96 07 00 07 03 00 00 00 08 3F 1C 96 02 00 08 40 4E 96 02 00 08 46 52 17 02 02 02 02 02 ///////////// no DragLimit for mainmenu: to container_mc.UIDrager.adjustDragLimit(-750,3000,40,60); // Line 89 = 96 1b 00 07 2e 00 00 00 07 32 00 00 00 07 ee 02 00 00 07 ee 02 00 00 07 04 00 00 00 08 08 to 96 1b 00 07 3c 00 00 00 07 28 00 00 00 07 b8 0b 00 00 07 12 fd ff ff 07 04 00 00 00 08 08 ///////////// hide mainmenu pinned guide 96020008094E960400080A0501 to 96020008094E960400080A0500 ///////////// S1UI_Chat2 (new) inspect on shift+click on name: inside function chatNameAction(data) // g4.view.chat.Chat change contents of condition below to this: if(_global.shift) { g4.model.GameModel.chatModel.ToGame_Chat_SendWriting(0,"/inspect " + _loc5_ + "",undefined,"/inspect " + _loc5_); } ///////////// use outlines edit at text (100): useoutlines 0 to useoutlines 1 //////////// enable copying of chat: edit at text (100): noselect 1 to noselect 0 && fix underline leak bug when noselect is set to 0: at the end of function chatNameAction(data) // g4.view.chat.Chat add: this.mainChat.updateWholeChat(); & inside function configUI() // g4.view.chat.MainChat add: _global.updateWholeChat = gfx.utils.Delegate.create(this,this.updateWholeChat); & at the end of function chatLinkAction(id) // g4.view.chat.ChatInput add: _global.updateWholeChat(); & inside function setWholeChat(text) // g4.view.chat.TextArea change: this.updateAfterTextFieldChanged(true); to this.updateAfterTextFieldChanged(false); ///////////// S1UI_Chat2 (old) change minimal basechat width: 96080009??0107d0020000 to 96080009??01072c010000 ///////////// &separate min chat width 960800093b0107fd010000 to 960800093b01072c010000 ///////////// enable copying of chat: text (105): noselect 1 to noselect 0 && fix underline leaking bug: @lines 2099, 2112, 2137, 2672 after everything add refreshTexts(); = Push 0.0 "refreshTexts" CallFunction Pop ///////////// disasble chat auto-scroll to end on opening input: delete line 2656: sc.scroll = sc.scrollMax; ///////////// fix large inter-line spacing: text (105): leading 120 to leading -60 ///////////// disable shout\notice background: 04014A9608000701000000092A023D4F960C to 05000202020202020202020202020202960C ///////////// disable shouts (rupors): 1C96030009CC014E960400087004014A9608000701000000092A023D to 1C96030009CC014E9604000870050002020202020202020202020202 & SetShout to NotShout ///////////// disable notices (events): SetNotice to NotNotice ///////////// change time after chat goes invisible: var invisibleSecond = 30; // Line 30 to var invisibleSecond = 5; = 9607000881071e000000 to 96070008810705000000 ///////////// auto-inspect (write inspect + name into chatfield) on shift\ctrl + click getURL("FSCommand:ToGame_Chat_ClickName",name + "\t" + chatType + "\t" + strTalk + "\t" + combinationKey); // Line 2074 to container_mc.input_mc.txt.text = "/inspect " + name; myListener.OnGame_Chat_ChangeChatMode(true); = Push "container_mc" GetVariable Push "input_mc" GetMember Push "txt" GetMember Push "text" "/inspect " register1 Add2 SetMember Push true 1 "myListener" GetVariable Push "OnGame_Chat_ChangeChatMode" CallMethod Pop or - for auto-inspect right away without writing into chat: myListener.OnGame_Chat_RemakeToHtml(1,"/inspect " + name,undefined); = Push undefined "/inspect " register1 Add2 Push 1 3 "myListener" GetVariable Push "OnGame_Chat_RemakeToHtml" CallMethod Pop ///////////// S1UI_TargetInfo: remove target buffs: _loc11_ = _loc5_.buff_container; // Line 835 buffTotalWidth = _loc5_.buff_array; _loc12_ = buffTotalWidth.length; _loc7_ = "buff_"; to §§pop(); return undefined; = 960400040508c5 (1st occur) to 17960100033E02 ///////////// S1UI_PartyWindow (new) move debuffs to right: function rearrangeSlotAtMainArea(array, startX, startY) // class g4.view.party.BuffArea { var buffTotalWidth = startX; var startXdebuff = 150; var startYdebuff = startY - 20; var NewSlot = undefined; var buffEntry = undefined; var i = undefined; var arraySize = array != null?array.length:0; if(!_global.bShowType6) // requires p-code fix after { startXdebuff = startX; startYdebuff = g4.view.party.PartyConstants.BUFF_SLOT_WIDTH + g4.view.party.PartyConstants.BUFF_SLOT_GAP + 1; } var debuffTotalWidth = startXdebuff; i = 0; while(i < arraySize) { buffEntry = (g4.view.party.BuffData)array[i]; // requires p-code fix after NewSlot = this.getOrCreateBuffSlot(buffEntry.id); NewSlot.setData(buffEntry); if(NewSlot.type == 0) // buff { NewSlot.__get__targetMovieClip()._x = buffTotalWidth; NewSlot.__get__targetMovieClip()._y = startY; NewSlot.__get__targetMovieClip()._visible = true; buffTotalWidth = buffTotalWidth + g4.view.party.PartyConstants.BUFF_SLOT_WIDTH + g4.view.party.PartyConstants.BUFF_SLOT_GAP; } else // debuff { NewSlot.__get__targetMovieClip()._x = debuffTotalWidth; NewSlot.__get__targetMovieClip()._y = startYdebuff; NewSlot.__get__targetMovieClip()._visible = true; debuffTotalWidth = debuffTotalWidth + g4.view.party.PartyConstants.BUFF_SLOT_WIDTH + g4.view.party.PartyConstants.BUFF_SLOT_GAP; } i = i + 1; } } && add option var customizeData = lib.gamedata.CustomizedUIDataCollection.getInstance(); // into main frame customizeData.valueOf(lib.gamedata.CustomizedUIDataKey.MESSAGE_TYPE6_VISIBLE,this,"messageType6Handler"); customizeData.addEventListener(gfx.events.EventTypes.VALUE_CHANGE,this,"valueChangeHandler"); function messageType6Handler(value) { if(value != null) { _global.bShowType6 = Number(value); } } function valueChangeHandler(event) { if(event.key == lib.gamedata.CustomizedUIDataKey.MESSAGE_TYPE6_VISIBLE) { messageType6Handler(Number(event.value)); } } ///////////// fix buff hiding settings not aplying untill settings window opened: this.wasfixed = false; function OnGameEventPartyWindowShow(memberID, bShow) // g4.view.party.Party { memberID = Number(memberID); bShow = g4.util.Converter.toBoolean(bShow); this.showUI(); if(bShow) { this.addMember(memberID); } else { this.removeMember(memberID); } if(!this.wasfixed) { setTimeout(this,"godlyFix",1000, true); this.wasfixed = true; } } function godlyFix(state) { if(state) { getURL("FSCommand:ToGame_PartyAbnormalitySetting_Open",""); // requires p-code fix after setTimeout(this,"godlyFix",100, false); } else { getURL("FSCommand:ToGame_PartyAbnormalitySetting_Close",""); // requires p-code fix after } } ///////////// S1UI_PartyWindow (old) remove party buffs: // for pre mage update _loc10_ = buffTotalWidth.buff_container; // Line 800 _loc4_ = buffTotalWidth.buff_array; _loc11_ = _loc4_.length; _loc6_ = "buff_"; to §§pop(); return null; = 9605000403090e01 (1st occur) to 17960100023E0202 ///////////// move debuffs right: (change formula for X coordinates) var buffTotalWidth = _loc4_ * (buffGap + buffWidth); // Line 496 to var buffTotalWidth = _loc4_ * buffGap + buffWidth; = 96020008(??)1C470C to 0C96020008(??)1C47 & (change variables for X coordinates) var buffGap = 3; // Line 1117 var buffWidth = 30; to var buffGap = 33; var buffWidth = 270; = 96070008??07040000003c96070008??071e000000 to 96070008??07210000003c96070008??070e010000 & (change Y coordinates) buffTotalWidth._y = 46; // Line 497 to buffTotalWidth._y = -43; = 08??072e000000 to 08??07d5ffffff ///////////// move debuffs to buffs place buffTotalWidth._y = 46; // Line 497 to buffTotalWidth._y = 0; = 08??072e000000 to 08??0700000000 ///////////// move buffs to debuffs place buffTotalWidth._y = 0; // Line 481 to buffTotalWidth._y = 46; = 0308??060000000000000000 (1st occur) to 0308??072e00000002020202 ///////////// change gage type for everyone to yellow: if(Class == 9) // Line 1389 to if(gageType > 0) = 9607000402070900000049 (1st occur) to 9607000403070000000067 ///////////// remove all gageBars if(Class == 9) // Line 1389 { gageType = 2; } to if(gageType > 0) { gageType = 0; } = 9607000402070900000049129D02000D009605000702 to 9607000405070000000067129D02000D009605000700 ///////////// S1UI_CharacterWindow delete stamina icon: container_mc.statMc.attachMovie("conditionMc","RestIcon",container_mc.statMc.getNextHighestDepth()); Push 0.0 "container_mc" GetVariable Push "statMc" GetMember Push "getNextHighestDepth" CallMethod Push "RestIcon" "conditionMc" 3 "container_mc" GetVariable Push "statMc" GetMember Push "attachMovie" CallMethod Pop 960b0006000000000000000008091c960200080d4e960200084e52960d00098c01093b02070300000008091c960200080d4e96020008505217 to 020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202020202 ///////////// HP bar = min \ max hpStrN = hp + "