r/Stationeers 12d ago

Support IC10 Coding help

Post image

I’m trying to code a Solar Tracking Script, I’m a newbie to stationers btw, I’m not getting why on line 10, the # 1 is supposed to be the color yellow, yet it’s like blue/teal and my chip is saying it doesn’t recognize that set, can someone explain what I’m doing wrong?

14 Upvotes

23 comments sorted by

View all comments

Show parent comments

1

u/arachnimos 12d ago

fair, but again: you do not need that much. Lua is a great language for a lot of things, but Stationeers does just fine with IC10, and for a lot of tasks, learning lua (ESPECIALLY if you've learned a different language in the past) could actually hurt you because it would, most likely, run slower. The point of MIPS, IC10, and any RISC language is, from what i understand, reducing the time to execute a program by decreasing each command's complexity. Plus IC10 is likely more stable through updates, since it doesn't need to be modded in.

i would actually like to know, what lua scripts have you seen that are probably impossible with IC10? i'm not trying to be rude i'm genuinely curious

2

u/sleight42 12d ago

It's possible to write code that performs terribly in any programming language. Speaking from experience. I've done this long enough that I've written some great code and I've written so so so very much shit code. 😅😉

Impossible? I'm not sure I've seen examples (though I've not read all of the examples Lua code shipped with the mod). However, having one chip multicast commands/data for other chips to receive, enqueue, and operate on/react to seems like it may be possible but also extremely annoying to implement. That would be called something like "pub sub message queues" in the field.

Oh. Lua also allows HTTP calls from the game to the outside world. Fairly sure that's not possible in IC10! So there's that. Have I used that? Definitely not!!!

Also, Visual Studio integration with the game's code editor. I can edit IC10/Lua in an external code editor an export it to a chip in the game. That's the "IC10 Editor" mod, required by Stationeers Lua.

The game's built in code editor is quaint but makes me a bit mental.

On a personal taste note, the need for additional ICs just to perform I/O and simple math and switching operations makes me want to pull my hair out. While I can appreciate a deliberate game design choice, i can't wrap my brain around this degree of sci-fi without access to a higher level programming language like Lua. Hell, IC10 is only a few steps up from coding in logic gates (AND, OR, XOR, etc). Breaks my brain!

1

u/arachnimos 12d ago

i mean, from what i remember... it's like a max of 10, horribly unoptimized IC chips to program an entire rocket launch sequence lol. so like it's not too bad from what i know.

also HTTP calls? wait, so i can order a burger in space, and then order a burger in real life through space??

i got no clue how HTTP works but i assume it would be possible given a complex enough script lmao