Skip to content

Commit

Permalink
Fix main menu timing
Browse files Browse the repository at this point in the history
  • Loading branch information
Tumppi066 committed Jun 29, 2024
1 parent f6750b7 commit a2fd900
Show file tree
Hide file tree
Showing 5 changed files with 15 additions and 4 deletions.
3 changes: 3 additions & 0 deletions blog/V1.11.Minor.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@ title: Version 1.11 > Minor
This changelog will contain all changes from 1.11.0 onwards before the next major version.
!!!

==- Version 1.11.51
Adjust crack message. Fix main menu update time display.
[!badge variant="dark" text="Tumppi066"] [!badge variant="ghost" text="Backend"] [!badge variant="ghost" text="MainUI"]
==- Version 1.11.50
Add check for a cracked game or DLCs, since the game will refuse to load DLLs in this case.
[!badge variant="dark" text="Tumppi066"] [!badge variant="ghost" text="Backend"]
Expand Down
3 changes: 2 additions & 1 deletion changelog.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
Add check for a cracked game or DLCs, since the game will refuse to load DLLs in this case.
1.11.50: Add check for a cracked game or DLCs, since the game will refuse to load DLLs in this case.
1.11.51: Fix main menu update time display.
4 changes: 3 additions & 1 deletion plugins/MainMenu/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,12 @@ def exampleFunction(self):
try:
updateTime = str(variables.LASTUPDATE).split(" ")
updateTime = updateTime[1:]
months = {"Jan": 1, "Feb": 2, "Mar": 3, "Apr": 4, "May": 5, "June": 6, "July": 7, "Aug": 8, "Sep": 9, "Oct":10, "Nov": 11, "Dec": 12}
months = {"Jan": 1, "Feb": 2, "Mar": 3, "Apr": 4, "May": 5, "Jun": 6, "Jul": 7, "Aug": 8, "Sep": 9, "Oct":10, "Nov": 11, "Dec": 12}
updateTime[0] = months[updateTime[0]]
updateText = f"{updateTime[1]}.{updateTime[0]}.{updateTime[3]} - {updateTime[2]} "
except:
import traceback
traceback.print_exc()
updateText = "-- Unknown --"

helpers.MakeLabel(self.root, f"Released {updateText}", 0, 1, columnspan=2, pady=0, autoplace=True)
Expand Down
7 changes: 6 additions & 1 deletion src/scsLogReader.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,17 @@
ets2FilePath = "C:/Users/" + variables.USERNAME + "/Documents/Euro Truck Simulator 2/game.log.txt"
currentFileHash = None
currentLines = []
hasShownCrackError = False

def CheckForCrackedGame(data):
global hasShownCrackError
crackIdentifier = "0000007E"
for line in data["log"]:
if crackIdentifier in line:
helpers.ShowFailure("\nThis is most likely because of a cracked game or DLCs.\nYou will have to buy the game / DLCs to continue!", "Error loading required DLLs")
if not hasShownCrackError:
helpers.ShowFailure("\nThis is almost certainly due to a cracked game or DLC. It might just be a broken DLL though.\nIf the app and game works then fine, but if you see this error we will not help with diagnosing the issue.", "DLL load error detected!")
print("Possible cracked game detected.")
hasShownCrackError = True


def plugin(data):
Expand Down
2 changes: 1 addition & 1 deletion version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.11.50
1.11.51

0 comments on commit a2fd900

Please sign in to comment.