Skip to content

Commit 2dd75bb

Browse files
committed
Update to b150
1 parent 86c3df1 commit 2dd75bb

File tree

11 files changed

+642
-15
lines changed

11 files changed

+642
-15
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# mlogv32
22

3-
RISC-V processor in Mindustry logic that runs Linux. Requires Mindustry build 149+.
3+
RISC-V processor in Mindustry logic that runs Linux. Requires Mindustry build 150+.
44

55
<img width="1823" height="1008" alt="linux" src="https://github.com/user-attachments/assets/9b1fd6fa-ba4c-4498-9892-ae87a81d4588" />
66

mod/.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
!/libs/**/*.jar

mod/build.gradle.kts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,10 +23,15 @@ toxopid {
2323
repositories {
2424
mavenCentral()
2525
anukeXpdustry()
26+
// FIXME: remove when toxopid updates
27+
flatDir {
28+
dir("libs/Mindustry")
29+
}
2630
}
2731

2832
dependencies {
29-
compileOnly(toxopid.dependencies.arcCore)
33+
// FIXME: uncomment when toxopid updates
34+
// compileOnly(toxopid.dependencies.arcCore)
3035
compileOnly(toxopid.dependencies.mindustryCore)
3136

3237
implementation(libs.kotlin.stdlib)

mod/libs/Mindustry/LICENSE

Lines changed: 619 additions & 0 deletions
Large diffs are not rendered by default.

mod/libs/Mindustry/core-v150.jar

69.7 MB
Binary file not shown.

mod/mod.hjson

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ displayName: mlogv32-utils
33
author: object-Object
44
description: Companion mod for mlogv32.
55
version: 0.1.0
6-
minGameVersion: "149"
6+
minGameVersion: "150"
77
dependencies: [
88
override-lib
99
// kotlin-runtime

mod/src/main/kotlin/gay/object/mlogv32/ProcessorAccess.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -335,7 +335,7 @@ private inline fun <reified T : Building> buildVar(build: LogicBuild, name: Stri
335335
// why
336336
private fun linkedBuild(build: LogicBuild, name: String) =
337337
build.links
338-
.firstOrNull { it.active && it.valid && it.name == name }
338+
.firstOrNull { it.valid && it.name == name }
339339
?.let { Vars.world.build(it.x, it.y) }
340340

341341
private fun LVar.numu() = num().toUInt()

python/src/mlogv32/preprocessor/parser/mlog.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -170,6 +170,8 @@ def check_unsaved_variables(ast: Iterable[ASTNode]):
170170
pass
171171
case Statement(name="set", args=[var, *_]):
172172
pass
173+
case Statement(name="select", args=[var, *_]):
174+
pass
173175
case Directive(name="start_fetch"):
174176
state = "fetch"
175177
continue

src/peripherals/debugger.mlog.jinja

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,12 @@
1818
#% set UART3 = 'bank4'
1919

2020
#% macro print(col, row)
21-
#{{'\n'}} draw print {{ 11 + col * 7 }} {{ 512 - 6 - row * 13 }} topLeft
21+
#{{'\n'}} draw print {{ 5 + col * 7 }} {{ 500 - row * 13 }} @topLeft
2222
drawflush {{DISPLAY}}
2323
#% endmacro
2424

2525
#% macro rect(col, row, width, height)
26-
#{{'\n'}} draw rect {{ 11 + col * 7 }} {{ 512 - 6 - row * 13 - 3 }} {{ width * 7 }} {{ height * -13 }}
26+
#{{'\n'}} draw rect {{ 5 + col * 7 }} {{ 500 - row * 13 - 3 }} {{ width * 7 }} {{ height * -13 }}
2727
#% endmacro
2828

2929
reset:

src/peripherals/display.mlog

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ loop__newline:
6868
loop__no_overflow_y:
6969

7070
loop__print_now:
71-
draw print cur_x cur_y topLeft
71+
draw print cur_x cur_y @topLeft
7272
set cur_x next_x
7373
set cur_y next_y
7474

@@ -100,7 +100,7 @@ loop__no_print:
100100
read wptr UART 511
101101
jump loop notEqual rptr wptr
102102

103-
draw print cur_x cur_y topLeft
103+
draw print cur_x cur_y @topLeft
104104
set cur_x next_x
105105
set cur_y next_y
106106

0 commit comments

Comments
 (0)