Read by Schine Semi-vague Lua Computer Suggestion

    therimmer96

    The Cake Network Staff Senior button unpusher
    Joined
    Jun 21, 2013
    Messages
    3,603
    Reaction score
    1,053
    No, no you can't! Not unless there's a way to link the computer directly to a block and we just established its not going to work that way. Linking 1 computer to 1 display is not an issue, but for the setup you showed you'd need multiple displays linked to a single computer and thats where shit goes wrong. I was assuming that's what you wanted which is why i didnt get the OP, but according to the OP this wouldn't be possible either. Keep in mind that displays can't just be copy pasted with the blueprints because they have to be in specific positions depending on the ship, so now people downloading the scripts need to redo these connections all over again.
    Read the title and opening lines, "Semi-Vague Computer Suggestion" and
    Forgive my crappy laid out suggestion, I'm doing 20 different things
    I intentionally didn't say "THIS IS HOW IT HAS TO WORK AND THERE IS NO ROOM FOR CHANGE". You could link a computer to the display with C/V, or just place the computer next to it, or something like that. I dunno, that's down to schine.


    What is with all this password nonsense, that's not necessary. Having a password block would be a much simpler way of doing this , where you just activate it, get a prompt, and it outputs logic if right. If programming is added then the logic system might not see useful blocks added because "lol just use the computers, here's a script you can download" another reason they shouldn't coexist.
    Yes, there's other possible solutions, I've never debated that, I still stand by my belief that a computer system would be a welcome addition that would add alot.

    ACCESSIBLE??? Programming is a huge obstacle, not to you because you know it, but to every other fucking person on earth, NO IT IS NOT ACCESSIBLE.
    No, it's not a huge obstacle, so much so that it is taught to young children in school, using games like Minecraft!
    Getting Started with Minecraft Pi | Raspberry Pi Learning Resources
    ComputerCraftEdu
    It just takes learning it. It's like logic, just with words instead of blocks, and a slightly different way to think things through. Instead of dealing with strictly binary logic systems and gates, you build a list of instructions. Perhaps you should look into the proposed systems instead of blindly blocking them Making a Password Protected Door - ComputerCraft Wiki

    You dont need to know how to program Java to play starmade
    You don't need to know how to program to play the game if this got added, just like you don't need to learn the logic system, or use the faction mechanics, or fit weapons to your ship, or use the boarding mechanics.


    EXCEPT THEY WONT WANT TO AND I JUST EXPLAINED WHY. Also the complex shit you're talking about is totally unnecessary for the game, like making your own metro or having programmable computers; they're neat but they don't fucking matter to the game.
    Neither do the rails or logic we have, they barely add anything in the way of gameplay, all I can think off is automating factories. There's no need for ships like the Tigerlilly, we don't need chaindrives, we don't need LOD blocks. They're in the game because they're cool. Tigerlilly is used as promotional material for the game now, chain drives are fitted to every ship, LOD blocks add no gameplay, yet are now featured on most builds.

    They let us build better things. This suggestion would allow better things.
    Any idiot who takes 5 minutes to understand reactor lines can make efficient power system; That's in no fucking way comparable to programming. Hell you can figure them out on your own with a little experimentation. Im not saying don't add it because its not immediately obvious; what you're asking for is fucking complicated, YOU just know how it works.
    I started using computercraft with no prior experience in progrmaming. It taught me the basic concepts that I needed when I went into education. I've taught class mates with no prior experience in programming the basics of C#, allowing them to create simple things.

    People learn. They learn't the logic system, a programming language in it's own right. It's comprable to visual scripting systems like PlayMaker, and scratch, which lets you learn programming by arranging blocks.




    That's like calling star wars obscure.
    No, it's like calling starmade obscure, which it is. There's a reason that starmade hasn't seen the mass adoption, well, there's many, but it's always going to be a niche game. It's one thing to spend a few hours watching a film, it's another to sink hours into space LEGO. Speaking of which, LEGO has their own programming line that gets used in schools.

    The idea that programming is something that only nerds do and is closed off to everyone else because of some arbitrary skill barrier is stupid.

    Again, explain to me why a game about building should limit building to people with programming skills, since people who can't program are going to be limited to an inferior system? And no, making these obscure gimmicky machines aren't a good reason to do that.
    It's not limiting, it's not making logic inferior, it's just getting past a barrier that many people are annoyed by. I know several people that prefer to use a visual programming system over a real one, logic would still have a place in the game. It's just that computers could help improve that system.
     

    nightrune

    Wizard/Developer/Project Manager
    Joined
    May 11, 2015
    Messages
    1,324
    Reaction score
    577
    • Schine
    • Top Forum Contributor
    • Thinking Positive
    I think most of these issues miss the biggest problem with any kind of computer or scripting.

    Limiting exploits and overuse. If it's a block you can place and attached an arbitrary script to. It'll get weaponized to hell with bad code. The steps around this limit the massive usefulness of the block.

    So while people would love this. In a server environment the admin would likely have to vet every script and we'd need to limit the amount of computers on an entity. So you would be limited to the scripts they've let on. Especially since the only secure way to run the scripts would be on the server.

    So how do you stop malicious code?
     

    therimmer96

    The Cake Network Staff Senior button unpusher
    Joined
    Jun 21, 2013
    Messages
    3,603
    Reaction score
    1,053
    I think most of these issues miss the biggest problem with any kind of computer or scripting.

    Limiting exploits and overuse. If it's a block you can place and attached an arbitrary script to. It'll get weaponized to hell with bad code. The steps around this limit the massive usefulness of the block.

    So while people would love this. In a server environment the admin would likely have to vet every script and we'd need to limit the amount of computers on an entity. So you would be limited to the scripts they've let on. Especially since the only secure way to run the scripts would be on the server.

    So how do you stop malicious code?
    What type of malicous code are we talking about? Something that runs endlessly? Cap it to X amount of time to run before crashing it. If you want it to sit there waiting for something to happen, use an event style system, CC does this [Lua] Too long without yielding
     

    nightrune

    Wizard/Developer/Project Manager
    Joined
    May 11, 2015
    Messages
    1,324
    Reaction score
    577
    • Schine
    • Top Forum Contributor
    • Thinking Positive
    What type of malicous code are we talking about? Something that runs endlessly? Cap it to X amount of time to run before crashing it. If you want it to sit there waiting for something to happen, use an event style system, CC does this [Lua] Too long without yielding
    That still doesn't help since I can just plop down 50 or 60 of them.

    As well all the computers are going to get timesliced on the server. That jump in and out overhead for the 100 to 1000 entities starmade is going to get expensive for the server.

    Are there examples of large servers with multiplayer computer craft?
     
    Joined
    Jul 30, 2013
    Messages
    398
    Reaction score
    282
    • Wired for Logic Gold
    • Legacy Citizen 8
    • Purchased!
    One posible solution can be "set a default input frecuency"; that "computer blocks" must have a logic input clock like actual sensor blocks work, so it need a logic "control signal" to operate any program inside, so if one player write a bad program/script, it only work if clock is ON.

    That still doesn't help since I can just plop down 50 or 60 of them.

    As well all the computers are going to get timesliced on the server. That jump in and out overhead for the 100 to 1000 entities starmade is going to get expensive for the server.

    Are there examples of large servers with multiplayer computer craft?
    And yess, i play on servers with computercraft with hundreds of players ( well, not all of that players use it ) and it work really well
     

    kiddan

    Cobalt-Blooded Bullet Mirror
    Joined
    May 12, 2014
    Messages
    1,131
    Reaction score
    358
    • Top Forum Contributor
    • Legacy Citizen 4
    • Purchased!
    Clients don't need to get sent/ask for info from computers/terminals/etc unless those computers actually affect blocks/entities outside (in some cases, this includes monitors). So even if Bob has 100 computers just calculating numbers, as long as Bill doesn't look at an output of those 100 computers (or input, in some cases), the data doesn't ever have to be sent to Bill. The data doesn't even exist in Bill's client-side world most of the time!

    Edit:

    Do take-note; A real-world machine still does have to calculate the 100 numbers on Bob's computers. But the point is, it doesn't have to be the server or Bill. If you make 100 computers, your real-world machine should have to calculate everything. Not someone else's.
     
    Last edited:
    Joined
    Nov 30, 2015
    Messages
    855
    Reaction score
    75
    Accessibility is fucking important, not to mention that some of us prefer not to spend hours writing code in a shitty text window instead of building actual stuff.
    Aren't you the guy that spent 4 pages hating on block based AI because you wanted scripting?
     
    • Like
    Reactions: Reilly Reese
    Joined
    Nov 30, 2015
    Messages
    855
    Reaction score
    75
    And yess, i play on servers with computercraft with hundreds of players ( well, not all of that players use it ) and it work really well
    Was this starmade? I don't remember open modding, or hundred player servers.
     
    Joined
    Dec 4, 2013
    Messages
    8
    Reaction score
    1
    • Purchased!
    • Legacy Citizen 3
    Could the performance of a computer block system be done so that hundreds of players could play on the same server comfortably at the same time? Yes.

    Is it easy?
    No.

    However it can be done.
    I'll (again) refer you to the way computercraft works, if a piece of code isn't letting the server run, the server stops it. "Putting down 50 of them" shouldn't change this, computers should be run per player (or per faction) each player (or faction) should get an equal (maybe greater % for factions?) timeslice every tick, if they can't run all of their code in that timeslice, their code stops. It does so before any hiccup happens in the game loop. There would be situations with large fleets and complicated encounters where things would break, but tbh there are ways of warning against this and the scripts would have to be badly written or doing expensive things a lot. Yes, server admins would need to be able to control computers to some extent, but they shouldn't have to audit every piece of code. The server should simply quarantine the scripts to game-world only calls and shut them down if they hang, then notify the admin.

    Now...malicious code is a complicated topic, but first I'd like to point out that nothing is ever entirely secure. Any environment where you can trigger unintentional behavior, is an environment which can be hacked. To what degree it can be hacked is a whole different story but let me just say that code is not a problem as long as you regulate it. Shine, you have already done this with logic blocks. No one is asking for you to allow code that can access real files. All we want is a way to consolidate logic into smaller space.

    ----
    The reason I am firmly for the consolidation of logic is here: Intelligence Systems and Ship Insturments
    TLDR, I want a way to get information about the game world.

    We can already write to screens with logic, we can already make doors open and close, we can make elevators, but let's face it, the game doesn't allow us to ask what's happening through logic, we have to take special care to keep the logic state in sync with game state, this is not ideal. The real world works with sensors, please let us have them.
    ----

    Okay now that my shameless plug for better intelligence systems is out of the way, Lua is just a language, and there's nothing innately wrong with running it, but you would have to write a scheduler into the main loop somehow. I understand that that's not easy, but it could also clean up lag from large logic arrays and while your at it you could use the scheduler for all kinds of asynchronous tasks that you might need to do as the game increases in complexity.

    Personally I find that, in its current state, the game is barely worth playing as an action-rpg space sim. This is not only because it's unfinished and most of the major elements don't work yet in that regard, but also because my creativity is limited to the "surface" creation of ships, e.g. what they look like, not really how they work, lua would solve this, plain and simple.

    EDIT:
    Also, can I just take a moment to say that Lua is so easy to learn. It is my opinion that everyone being educated today should have to learn about basic programming anyway, but even if you disagree, Lua is something you can learn the basics of in a day. If you want to do something really complicated it will take time, but that's the case for everyone. It's not like knowing how to code is some magic power that allows you to instantly create functionality where there was none before. Most programmers are learning all the time, during every project, so accessibility is more of a perception issue than an actual accessibility one.
     
    Last edited:
    • Like
    Reactions: Winterhome
    Joined
    Jun 29, 2016
    Messages
    80
    Reaction score
    39
    Also, can I just take a moment to say that Lua is so easy to learn. It is my opinion that everyone being educated today should have to learn about basic programming anyway, but even if you disagree, Lua is something you can learn the basics of in a day.
    IMHO this is pretty beside the point though. I take your point about wanting to better interact with the universe, but I think in this kind of game that it better done by integrating sensor blocks with the existing logic blocks. While it may be possible for most people to learn Lua, it's exceedingly frustrating for people disadvantaged in that regard, or people who just don't find coding fun. If in order to get the same results as a Lua controlled ship a person needs to learn to do something they find totally boring, that is a massive turn off. If Lua was added, I wouldn't want to see it doing things that can't be done with alternate blocks, or it creates a two class system in the game. Otherwise, Lua should be restricted to single-player.

    Personally, I think a block-building game should aim as much a possible to be playable by someone who is totally illiterate. It's part of the charm and one can make things happen just by placing blocks, and I do hope Schine sticks to a solely block-based system of logic and sensors.
     

    Valiant70

    That crazy cyborg
    Joined
    Oct 27, 2013
    Messages
    2,189
    Reaction score
    1,167
    • Thinking Positive
    • Purchased!
    • Legacy Citizen 4
    The idea of ingame Lua computers has come up before, and I believe it is something the game could really benefit from. Lua is lightweight and simple to learn, so it is appropriate. I'll look over this thread more thoroughly later.
     
    Joined
    Dec 4, 2013
    Messages
    8
    Reaction score
    1
    • Purchased!
    • Legacy Citizen 3
    IMHO this is pretty beside the point though. I take your point about wanting to better interact with the universe, but I think in this kind of game that it better done by integrating sensor blocks with the existing logic blocks. While it may be possible for most people to learn Lua, it's exceedingly frustrating for people disadvantaged in that regard, or people who just don't find coding fun. If in order to get the same results as a Lua controlled ship a person needs to learn to do something they find totally boring, that is a massive turn off. If Lua was added, I wouldn't want to see it doing things that can't be done with alternate blocks, or it creates a two class system in the game. Otherwise, Lua should be restricted to single-player.

    Personally, I think a block-building game should aim as much a possible to be playable by someone who is totally illiterate. It's part of the charm and one can make things happen just by placing blocks, and I do hope Schine sticks to a solely block-based system of logic and sensors.
    I agree that it's not for everyone, but I also feel that it would allow enough functionality to justify adding it for those who do want it. Simply make it a config option, allow servers to enable the block if they want it. As pointed out before, even those who do not want to write a line of code could benefit from the software others write, and plenty of people in the community do want to automate functionality in a more compact way, it doesn't even have to be Lua (although I believe that would be the most powerful way to do so). Just give us a block that allows us to compact logic arrays.

    Frankly, as implied in the intel thread, creating ship instruments is very difficult without programming. The devs can give us basic instrumentation but what they've given so far is wholly inadequate for tactical and strategic thought to shine, and a lot of ship builders put a huge amount of time into thinking about the game-mechanical implications of their designs, huge capital ship battles are, at this point, chaotic and hard to follow, often ship functionality is quickly reduced to nothing, and the players can't do anything about it because they don't have good information on the status of either ship. "Here wait let me orbit the camera to try to get a better look at their port ventral plating to see if it's damaged enough to justify maneuvering to torpedo it" is something that takes too long in the heat of battle. You need to just know.

    If the devs want to give us an EVE-level tactical UI that's great, but I doubt this is high on their todo, give the players the ability to make this happen!
     
    Joined
    Jul 30, 2013
    Messages
    398
    Reaction score
    282
    • Wired for Logic Gold
    • Legacy Citizen 8
    • Purchased!
    In my humble opinion, I know that if some type of programming is added to the game, only 10-15% of players will know how to use it, but once given the necessary tools, everyone will benefit from the creations of that minority.

    REGEX commands are fine, but to do certain things, they are very limited, or you must use a lot of display blocks ... and that is increasing, to perform certain tasks the number of blocks used is very great.

    I will program a little in LÚA, and if I can create small programs-applications for other players, I will feel very honored.
     
    Last edited:
    Joined
    Jun 29, 2016
    Messages
    80
    Reaction score
    39
    [...] even those who do not want to write a line of code could benefit from the software others write, and plenty of people in the community do want to automate functionality in a more compact way,
    Two points here:

    1. This is where the main problem with Lua comes in. Those that can will keep the best stuff for themselves, and --wherever it creates a tactical advantage-- those that can't will get the reduced functionality publicly released scripts only. This is natural, as those that take the time to write the scripts want the biggest rewards, but it is what will create first and second class StarMade citizens.

    2. Miniaturisation of existing logic is turning the game from what it is into something else. First and foremost this is a block-building-game. I don't think it should be possible to replace existing logic with one display block full of code - it's like competing with someone who is not even playing the same game, who is then able to to make the same thing as you but with a fraction of the mass, because they don't have to follow the same rulebook.

    Again, neither is an issue in single-player, but in multi-player it becomes a problem. I suspect though that allowing it in single player only would just create pressure for it to be allowed in multi-player, and as an option, server admins would in turn be pressured to enable it to attract the 'best' players onto their servers.
     
    Last edited:

    kiddan

    Cobalt-Blooded Bullet Mirror
    Joined
    May 12, 2014
    Messages
    1,131
    Reaction score
    358
    • Top Forum Contributor
    • Legacy Citizen 4
    • Purchased!
    Maybe the mentioned info warfare could play a part in balancing compact logic? A computer could be easier to find via some sort of scan depending on how many external blocks it affects.
     
    • Like
    Reactions: jayman38
    Joined
    Dec 4, 2013
    Messages
    8
    Reaction score
    1
    • Purchased!
    • Legacy Citizen 3
    Two points here:

    1. This is where the main problem with Lua comes in. Those that can will keep the best stuff for themselves, and --wherever it creates a tactical advantage-- those that can't will get the reduced functionality publicly released scripts only. This is natural, as those that take the time to write the scripts want the biggest rewards, but it is what will create first and second class StarMade citizens.

    2. Miniaturisation of existing logic is turning the game from what it is into something else. First and foremost this is a block-building-game. I don't think it should be possible to replace existing logic with one display block full of code - it's like competing with someone who is not even playing the same game, who is then able to to make the same thing as you but with a fraction of the mass, because they don't have to follow the same rulebook.

    Again, neither is an issue in single-player, but in multi-player it becomes a problem. I suspect though that allowing it in single player only would just create pressure for it to be allowed in multi-player, and as an option, server admins would in turn be pressured to enable it to attract the 'best' players onto their servers.
    Alright zombie mouse, I see your point, and it's a good one. In the end, the devs can't keep everyone happy, but whether this is a block-building game or not, it's also a space game and I feel that they've already let us build computers with logic blocks, it just feels wrong that simple logic takes so much room!

    So let me ask you, Schine, and the rest of the community, would you be happier with a block that allows you to build in a "virtual" environment with logic blocks? That way you could reduce mass and space requirements for everyone, and in essence programming this block would still be a "block-building" activity.

    Additionally schine would only have to do visual block state calculations when players are visiting the "virtual programming world" which would reduce logic-block overhead when they are used in the "computer" block.

    I feel that programming like this is just harder and more tedious than with Lua or another scripting language, but if it's important to the community that logic blocks remain the only way to do what a computer does, I would be willing to work with them exclusively.
     

    jayman38

    Precentor-Primus, pro-tempore
    Joined
    Jul 13, 2014
    Messages
    2,518
    Reaction score
    787
    • Purchased!
    • Thinking Positive
    • Legacy Citizen 4
    ...
    So let me ask you, Schine, and the rest of the community, would you be happier with a block that allows you to build in a "virtual" environment with logic blocks? That way you could reduce mass and space requirements for everyone, and in essence programming this block would still be a "block-building" activity.
    ...
    There was a recent suggestion about "alternate building dimensions", where I hinted at a "logic" dimension, where logic can be built in its own space in the ship's bounding box, without effecting the physical blocks. This way, logic would still use blocks, and would still be limited by the size of the ship, but could be bigger and more in-depth, without interfering with the ship's physical layout.

    There is a certain charm when a logic system is damaged and starts malfunctioning, and we'd lose that malfunction if the logic were moved to an alternate "dimension" in the ship entity's space, but I think it would be worth it. Control inputs and logic and rail outputs would still have to be placed on the physical layer, and that's where the logic could be damaged.
     
    • Like
    Reactions: Valiant70
    Joined
    Dec 4, 2013
    Messages
    8
    Reaction score
    1
    • Purchased!
    • Legacy Citizen 3
    There was a recent suggestion about "alternate building dimensions", where I hinted at a "logic" dimension, where logic can be built in its own space in the ship's bounding box, without effecting the physical blocks. This way, logic would still use blocks, and would still be limited by the size of the ship, but could be bigger and more in-depth, without interfering with the ship's physical layout.

    There is a certain charm when a logic system is damaged and starts malfunctioning, and we'd lose that malfunction if the logic were moved to an alternate "dimension" in the ship entity's space, but I think it would be worth it. Control inputs and logic and rail outputs would still have to be placed on the physical layer, and that's where the logic could be damaged.
    You could also limit this dimension's size based on cost of the "computer" block, (e.g. you could have really expensive big computers, but if they're destroyed you lose all that functionality, or you could have small computers with limited space that are cheaper to produce and buy, but then you're forced to modularize your logic.

    This keeps some of the charm anyway.
     

    Valiant70

    That crazy cyborg
    Joined
    Oct 27, 2013
    Messages
    2,189
    Reaction score
    1,167
    • Thinking Positive
    • Purchased!
    • Legacy Citizen 4
    That still doesn't help since I can just plop down 50 or 60 of them.

    As well all the computers are going to get timesliced on the server. That jump in and out overhead for the 100 to 1000 entities starmade is going to get expensive for the server.

    Are there examples of large servers with multiplayer computer craft?
    Computercraft is not the best example. A better one is OpenComputers, which limits the processing power of each computer and requires in-game power to run. Official documentation of OpenComputers [OpenComputers]
    Resource cost and power use are some of the ways starmade could de-incentivise computing overload.