Fehlende CSS beim Bau von Schiffen und Verteidungsanlagen?

    This site uses cookies. By continuing to browse this site, you are agreeing to our Cookie Policy.

    • Fehlende CSS beim Bau von Schiffen und Verteidungsanlagen?

      Hi@all,

      ich schreib jetzt mal in meiner Muttersprache ;)

      Ich nutze aktuell 2Moons 1.8 mit einigen Mods.
      Alles Wunderbar. Bis auf ein paar Kleinigkeiten.

      Derzeit veruche ich einen Rahmen inkl. Hintergrund für die Bauzeiten bei Schiffen und Verteidungsanlagen geregelt zu bekommen.
      Auf dem Bild sieht man, dass diese fehlen:



      Ich weiss aber beim besten Willen nicht, WO ich das ändern kann bzw. soll.
      Hat ihr jemand den helfenden Tipp für mich?

      Danke schon mal.
    • if for example you open buildings if you look at building process you can add
      <div class = "element_row {if $ List @ first} active_row {/ if}" style = "background: url (./ styles / theme / gow / gebaeude / {$ ID} .gif)">

      which looks like this for me

      <div style = "overflow-y: hidden;">
      <div id = "buildlist" class = "buildlist">
      <div class = "buildtitle">
      <div id = "build_process" class = "bui4era">
      {foreach $ Queue as $ List}
      {$ ID = $ List.element}
      <div class="element_row {if $List@first}active_row{/if}" style="background:url(./styles/theme/gow/gebaeude/{$ID}.gif)">
      -
      and your css add:
      }
      #build_process {
      border: 1px solid # 000;
      background: # 030c1b;
      height: 75px;
      display: flex;
      overflow-x: auto;
      overflow-y: hidden;
      max-width: 100%;
      margin: 0;
      margin-left: 12px;
      margin-right: 1.2%;
      -webkit-box-shadow: inset 0 1px 1px rgb (13, 33, 66), inset 0 -1px 0px rgba (63, 59, 113, 0.2), 0 9px 16px 0 rgba (0, 0, 0, 0.3) , 0 4px 3px 0 rgba (0, 0, 0, 0.3), 0 0 0 1px # 040f1f;
      -moz-box-shadow: inset 0 1px 1px rgb (13, 33, 66) inset 0 -1px 0px rgba (63, 59, 113, 0.2), 0 9px 16px 0 rgba (0, 0, 0, 0.3), 0 4px 3px 0 rgba (0, 0, 0, 0.3), 0 0 0 1px # 040f1f;
      box-shadow: inset 0 1px 1px rgb (13, 33, 66), inset 0 -1px 0px rgba (63, 59, 113, 0.2), 0 9px 16px 0 rgba (0, 0, 0, 0.3), 0 4px 3px 0 rgba (0, 0, 0, 0.3), 0 0 0 1px # 040f1f;
      -moz-border-radius: 3px;
      -webkit-border-radius: 3px;
      border-radius: 3px;
      margin-bottom: 7px;
      }
    • also add in css
      -
      .bui4era {
      1. background: # 030c1b url (./ img / content / sfondobui.png) no-repeat! important;
      2. background-size: 35%! important;
      3. background-position: right! important;
      4. max-width: 100%;
      5. margin: 0;
      6. margin-left: 12px;
      7. margin-right: 1.2%;
      }
    • Can you tell me what css?
      Is this correct?

      styles\resource\css\ingame\main.css

      And what is this?

      ./img/content/sfondobui.png

      I don't have this picture and I also don't know what it looks like ;)
    • yes you can open it up in an editor at the bottom of the page paste it in just make sure when u pate it in their is only "}" one in the beginning..when thats done clear your cache and borrower history
    • I edited my main.css.

      I cleared the cache and so on. But nothing changed.

      This is the end of my css:

      Source Code

      1. #resourceTable td{
      2. min-width: 100px;
      3. }
      4. }
      5. #build_process {
      6. border: 1px solid # 000;
      7. background: # 030c1b;
      8. height: 75px;
      9. display: flex;
      10. overflow-x: auto;
      11. overflow-y: hidden;
      12. max-width: 100%;
      13. margin: 0;
      14. margin-left: 12px;
      15. margin-right: 1.2%;
      16. -webkit-box-shadow: inset 0 1px 1px rgb (13, 33, 66), inset 0 -1px 0px rgba (63, 59, 113, 0.2), 0 9px 16px 0 rgba (0, 0, 0, 0.3) , 0 4px 3px 0 rgba (0, 0, 0, 0.3), 0 0 0 1px # 040f1f;
      17. -moz-box-shadow: inset 0 1px 1px rgb (13, 33, 66) inset 0 -1px 0px rgba (63, 59, 113, 0.2), 0 9px 16px 0 rgba (0, 0, 0, 0.3), 0 4px 3px 0 rgba (0, 0, 0, 0.3), 0 0 0 1px # 040f1f;
      18. box-shadow: inset 0 1px 1px rgb (13, 33, 66), inset 0 -1px 0px rgba (63, 59, 113, 0.2), 0 9px 16px 0 rgba (0, 0, 0, 0.3), 0 4px 3px 0 rgba (0, 0, 0, 0.3), 0 0 0 1px # 040f1f;
      19. -moz-border-radius: 3px;
      20. -webkit-border-radius: 3px;
      21. border-radius: 3px;
      22. margin-bottom: 7px;
      23. }
      24. .bui4era {
      25. background: # 030c1b url (./img/content/sfondobui.png) no-repeat;
      26. background-size: 35%;
      27. background-position: right;
      28. max-width: 100%;
      29. margin: 0;
      30. margin-left: 12px;
      31. margin-right: 1.2%;
      32. }
      Display All

      And what to do with this:

      Source Code

      1. if for example you open buildings if you look at building process you can add
      2. <div class = "element_row {if $ List @ first} active_row {/ if}" style = "background: url (./ styles / theme / gow / gebaeude / {$ ID} .gif)">
      3. which looks like this for me
      4. <div style = "overflow-y: hidden;">
      5. <div id = "buildlist" class = "buildlist">
      6. <div class = "buildtitle">
      7. <div id = "build_process" class = "bui4era">
      8. {foreach $ Queue as $ List}
      9. {$ ID = $ List.element}
      10. <div class="element_row {if $List@first}active_row{/if}" style="background:url(./styles/theme/gow/gebaeude/{$ID}.gif)">
      Display All
      Please explain it exactly to me. In which template I have to insert or edit this lines?
      I'm really absolute new at this things!

      I'm very very sorry about this!

      Is the correct template page.shipyard.default.tpl?
      I want to edit the building time for ships and defense.

      But I can't find your "element_row" class??

      This is in my template:

      Source Code

      1. {block name="title" prepend}{if $mode == "defense"}{$LNG.lm_defenses}{else}{$LNG.lm_shipshard}{/if}{/block}
      2. {block name="content"}
      3. {if !$NotBuilding}<table width="70%" id="infobox" style="border: 2px solid red; text-align:center;background:transparent"><tr><td>{$LNG.bd_building_shipyard}</td></tr></table><br><br>{/if}
      4. {if !empty($BuildList)}
      5. <table style="width:760px">
      6. <tr>
      7. <td class="transparent">
      8. <div id="bx" class="z"></div>
      9. <br>
      10. <form action="game.php?page=shipyard&amp;mode={$mode}" method="post">
      11. <input type="hidden" name="action" value="delete">
      12. <table>
      13. <tr>
      14. <th>&nbsp;</th>
      15. </tr>
      16. <tr>
      17. <td><select name="auftr[]" id="auftr" size="10" multiple><option>&nbsp;</option></select><br><br>{$LNG.bd_cancel_warning}<br><input type="submit" value="{$LNG.bd_cancel_send}"></td>
      18. </tr>
      19. <tr>
      20. <th>&nbsp;</th>
      21. </tr>
      22. </table>
      23. </form>
      24. <br><span id="timeleft"></span><br><br>
      25. </td>
      26. </tr>
      27. </table>
      28. <br>
      29. {/if}
      30. {if $NotBuilding}<div style="text-align:center; width:100%;"><input type="submit" value="{$LNG.bd_build_ships}" class="build_submit" style="color:#fff; font-weight:bold; width:100px; text-align:center; border:1px solid #000; border-radius: 5px; height:34px; background:green; vertical-align:center; "></div>{/if}
      31. {foreach $elementList as $ID => $Element}<form action="game.php?page=shipyard&amp;mode={$mode}" method="post">
      32. <div style="position:relative; border-radius: 5px; width:172px; margin:5px; border:1px solid #000; height:284px; overflow:hidden; float:left; background:rgba(0,0,0,0.95);">
      33. <div onclick="return Dialog.info({$ID})" style=" width:172px; height:172px; background:url('{$dpath}gebaeude/{$ID}.gif'); background-size:100% 100%;"><div style="background:rgba(13, 16, 20, 0.95); height: 30px; border-bottom: 1px solid #000; padding-left:2px; width:100%;"><a class="tooltip" data-tooltip-content="<div style='max-width:200px;'>{$LNG.shortDescription.{$ID}|replace:'"':'\''}<br><br> {$LNG.bd_remaining|replace:'"':'\''}<br>
      34. {foreach $Element.costOverflow as $ResType => $ResCount}
      35. {$LNG.tech.{$ResType}|replace:'"':'\''}: <span style='font-weight:700'>{$ResCount|number}</span><br>
      36. {/foreach} </div>" style="font-weight:bold; font-size:1.1em;" href="#" onclick="return Dialog.info({$ID})">
      37. {$LNG.tech.{$ID}}</a><span id="val_{$ID}">{if $Element.available != 0} ({$LNG.bd_available} {$Element.available|number}){/if}</span>
      38. </div></div>
      39. <div>{$LNG.fgf_time}:<span style="float:right;">{$Element.elementTime|time}</span></div>
      40. <div style="; height:60px; text-align:right;" >
      41. <span>{foreach $Element.costResources as $RessID => $RessAmount}
      42. <b><span style="color:{if $Element.costOverflow[$RessID] == 0}lime{else}red{/if}">{$RessAmount|number}</span></b> <img src="{$dpath}images/{$RessID}.gif" alt="{$LNG.tech.{$RessID}}" width="30" height="20"><br>
      43. {/foreach}</span>
      44. </div>
      45. {if $Element.AlreadyBuild}<div style="text-align:center; border:1px solid #000; border-radius: 5px; height:34px; background:red;"><span style="color:#fff">{$LNG.bd_protection_shield_only_one}</span></div>
      46. {elseif $NotBuilding && $Element.buyable}
      47. <div style="text-align:center;"><input type="text" style="padding:0px; width:70px" name="fmenge[{$ID}]" id="input_{$ID}" size="{$maxlength}" maxlength="{$maxlength}" value="0" tabindex="{$smarty.foreach.FleetList.iteration}"><input style="width:90px" type="button" value="{$LNG.bd_max_ships} {$Element.maxBuildable|number}" onclick="$('#input_{$ID}').val('{$Element.maxBuildable}')">
      48. <input type="submit" value="{$LNG.bd_build_ships}" class="build_submit" style="color:#fff; font-weight:bold; min-width:100%; margin:0px; text-align:center; border:1px solid #000; border-radius: 5px; height:19px; background:green; vertical-align:center; "></div>
      49. {/if}
      50. </div></form>
      51. {/foreach}
      52. {/block}
      53. {block name="script" append}
      54. <script type="text/javascript">
      55. data = {$BuildList|json};
      56. bd_operating = '{$LNG.bd_operating}';
      57. bd_available = '{$LNG.bd_available}';
      58. </script>
      59. {if !empty($BuildList)}
      60. <script src="scripts/base/bcmath.js"></script>
      61. <script src="scripts/game/shipyard.js"></script>
      62. <script type="text/javascript">
      63. $(function() {
      64. ShipyardInit();
      65. });
      66. </script>
      67. {/if}
      68. {/block}
      Display All

      The post was edited 5 times, last by Vertex ().

    • I found a solution for me. Not really nice, but working.



      In page.shipyard.default.tpl I edited following line:

      Line 8:

      Source Code

      1. <div id="bx" class="z" style="background:rgba(13, 16, 20, 0.70); padding:10px; margin:auto; width:40%;"></div>


      Line 24:

      Source Code

      1. <br><div style="background:rgba(13, 16, 20, 0.85); padding:10px; margin:auto; width:30%;">Restbauzeit: <span id="timeleft"></span></div><br><br>


      But now I asked myself how can I get a progressbar for building instead of a countdown??