Changeset 746
- Timestamp:
- Jan 10, 2014, 11:06:39 PM (11 years ago)
- Location:
- trunk
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Modules/Export/files/1.12.1/CzWoW/CzWoW.lua
r722 r746 5 5 local old_ItemTextFrame_OnEvent; 6 6 local old_ChatFrame_OnEvent; 7 local old_GossipFrameOptionsUpdate;7 --local old_GossipFrameOptionsUpdate; 8 8 local old_GossipFrameUpdate; 9 9 local oldTooltipText; … … 260 260 old_ItemTextFrame_OnEvent=ItemTextFrame_OnEvent; 261 261 old_ChatFrame_OnEvent=ChatFrame_OnEvent; 262 old_GossipFrameOptionsUpdate=GossipFrameOptionsUpdate;262 --old_GossipFrameOptionsUpdate=GossipFrameOptionsUpdate; 263 263 old_GossipFrameUpdate=GossipFrameUpdate; 264 264 … … 359 359 end; 360 360 361 GossipFrameOptionsUpdate=function(arg) 362 if (arg ~= nil) then 363 if select("#", arg)>0 then 364 old_GossipFrameOptionsUpdate(arg); 361 --NEW:delete 362 GossipFrameOptionsUpdate_zaloha=function(par) 363 if (par ~= nil) then 364 DEFAULT_CHAT_FRAME:AddMessage(par); 365 -- if select("#", par)>0 then 366 -- old_GossipFrameOptionsUpdate(par); 367 368 local titleButton; 369 local titleIndex = 1; 370 for i=1, arg.n, 2 do 371 if ( GossipFrame.buttonIndex > NUMGOSSIPBUTTONS ) then 372 message("This NPC has too many quests and/or gossip options."); 373 end 374 titleButton = getglobal("GossipTitleButton" .. GossipFrame.buttonIndex); 375 titleButton:SetText(arg[i]); 376 GossipResize(titleButton); 377 titleButton:SetID(titleIndex); 378 titleButton.type="Gossip"; 379 getglobal(titleButton:GetName() .. "GossipIcon"):SetTexture("Interface\\GossipFrame\\" .. arg[i+1] .. "GossipIcon"); 380 GossipFrame.buttonIndex = GossipFrame.buttonIndex + 1; 381 titleIndex = titleIndex + 1; 382 titleButton:Show(); 383 end 384 365 385 if CZWOW_EnableNPCs and type(CZWOW_NPCAction_count)=="number" then 366 for i=1, NUMGOSSIPBUTTONS, 1 do 386 for i=1, GossipFrame.buttonIndex, 1 do 387 titleButton=getglobal("GossipTitleButton" .. i); 388 titleButton:SetText("test"); 389 local en=trim(titleButton:GetText()); 390 for i=1, CZWOW_NPCAction_count, 1 do 391 if type(getglobal("CZWOW_NPCAction_"..i))=="table" and getglobal("CZWOW_NPCAction_"..i)[en] then 392 titleButton:SetText(prepare(getglobal("CZWOW_NPCAction_"..i)[en])); 393 GossipResize(titleButton); 394 end 395 end 396 end 397 end 398 -- end 399 end 400 end 401 402 GossipFrameUpdate=function() 403 old_GossipFrameUpdate(); 404 local cz=NPCTextTranslate(GossipGreetingText:GetText()); 405 if cz then GossipGreetingText:SetText(cz) end 406 407 408 --NEW: 409 for i=1, GossipFrame.buttonIndex, 1 do 367 410 titleButton=getglobal("GossipTitleButton" .. i); 368 411 local en=trim(titleButton:GetText()); … … 373 416 end 374 417 end 375 end 376 end 377 end 378 end 379 end 380 381 GossipFrameUpdate=function() 382 old_GossipFrameUpdate(); 383 local cz=NPCTextTranslate(GossipGreetingText:GetText()); 384 if cz then GossipGreetingText:SetText(cz) end 418 for i=1, CZWOW_QuestTitle_count, 1 do 419 if type(getglobal("CZWOW_QuestTitle_"..i))=="table" and getglobal("CZWOW_QuestTitle_"..i)[en] then 420 titleButton:SetText(prepare(getglobal("CZWOW_QuestTitle_"..i)[en])); 421 end 422 end 423 end 385 424 end; 386 425 -
trunk/includes/Version.php
r745 r746 6 6 // and system will need database update. 7 7 8 $Revision = 74 5; // Subversion revision8 $Revision = 746; // Subversion revision 9 9 $DatabaseRevision = 732; // Database structure revision 10 10 $ReleaseTime = '2014-01-08'; -
trunk/includes/global.php
r745 r746 144 144 145 145 function GetTranslateGoogle($text) { 146 146 global $System; 147 147 // $text = 'Balthule\'s letter is dire. This Cult of the Dark Strand is a thorn in my side that must be removed. I have been dealing with some of the Dark Strand scum northeast of here at Ordil\'Aran. One of their number possesses a soul gem that I believe holds the secret to the cult\'s power.$b$bBring it to me, and I will be able to decipher the secrets held within.'; 148 148 // $text = htmlspecialchars($text); 149 150 $text = str_replace('$B','$B ',$text); 149 151 $text = urlencode($text); 152 // $text = strtolower($text); 150 153 // $text = str_replace('&','',$text); 151 154 // $text = str_replace(' ','%20',$text); 152 // $text = str_replace('$B','$B%20',$text); 153 $url = 'http://translate.google.cz/?sl=en&tl=cs&text='.$text; 155 if ($System->User->Language == 2) 156 $lang = 'sk'; 157 else $lang = 'cs'; 158 $url = 'http://translate.google.cz/?sl=en&tl='.$lang.'&text='.$text; 154 159 155 160 … … 169 174 $data = $partbefore.' '.$partafter; 170 175 } 176 177 $data = utf8_encode($data); 171 178 172 179 $data = str_replace('$ ','$',$data); 180 $data = str_replace('$b $b','$b$b',$data); 173 181 $data = str_replace('| ','|',$data); 174 182
Note:
See TracChangeset
for help on using the changeset viewer.