Suggested Programmable Logic Block

    Joined
    Aug 20, 2016
    Messages
    19
    Reaction score
    5
    It will be nice to have a customisable (programmable/scriptable) logic block in game. For example, it can be a block that has a text editor to write some scripts (programm its behaviour), or simle window to edit its truth table, etc.

    Offtopic: is there any way to change delay time in delay block?
     
    • Like
    Reactions: rocketman221

    NeonSturm

    StormMaker
    Joined
    Dec 31, 2013
    Messages
    5,110
    Reaction score
    617
    • Wired for Logic
    • Thinking Positive
    • Legacy Citizen 5
    No change in delay times, you can search for "faster clocks" or "speed clocks".

    You have to wait for CPU-builds in the logic forum to finish and use my Quantum-ROM.

    I have made a Quantum-ROM topic (logic-forum).
    *joking around* But to effectively program it, you have to spend 1 year linking blocks for 1 MB program code :D
    *seriously now* you can get 1 KB program code in about a week of work.

    You could cut the time needed by writing a script which outputs a blueprint.sment file.
    Activation+NOT address blocks (binary 111 = 4+2+1 = 5)
    - - V linking V - -
    And-Blocks
    - - V linking V - - (these links store information – 1 bit per link)
    Or-Blocks which display stored information between 1*AND and N*OR
    JavaScript:
    //note: Memory-Size = orArray.length * andArray.length
    Pos3D activationArray = new Pos3D[ n ];
    Pos3D notArray = new Pos3D[ activationArray.length ];
    Pos3D andArray = new Pos3D[ 2^n ];
    Pos3D orArray = new Pos3D[ m ];
    SMLink linkArray = new SMLink[ (notArray.length * andArray.length)+(andArray.length * orArray.length)];
    int itLink = 0;
    
    for( i=0; i<notArray.length; i++ )
      {
      //activation to NOT
      linkArray[ itLink++ ] = new SMLink( activationArray[i], notArray[i] );
    
      //activation&NOT to AND
      for( ii=0; ii<andArray.length; ii++ )
        {
        if( ii=2^i ) linkArray[ itLink++ ] = new SMLink( activationArray[i], andArray[ii] );
        else linkArray[ itLink++ ] = new SMLink( notArray[i], andArray[ii] );
     
        //AND to OR
        for( iii=0; iii<orArray.length; iii++)
          {
          byte = inputStream.nextByte();
          if( byte &0x01 )linkArray[ itLink++] = new SMLink( andArray[ii], orArray[iii] );
          else ++itLink;
          if( byte &0x02 )linkArray[ itLink++] = new SMLink( andArray[ii], orArray[iii] );
          else ++itLink;
          if( byte &0x04 )linkArray[ itLink++] = new SMLink( andArray[ii], orArray[iii] );
          else ++itLink;
          if( byte &0x08 )linkArray[ itLink++] = new SMLink( andArray[ii], orArray[iii] );
          else ++itLink;
          if( byte &0x10 )linkArray[ itLink++] = new SMLink( andArray[ii], orArray[iii] );
          else ++itLink;
          if( byte &0x20 )linkArray[ itLink++] = new SMLink( andArray[ii], orArray[iii] );
          else ++itLink;
          if( byte &0x40 )linkArray[ itLink++] = new SMLink( andArray[ii], orArray[iii] );
          else ++itLink;
          if( byte &0x80 )linkArray[ itLink++] = new SMLink( andArray[ii], orArray[iii] );
          else ++itLink;
          }
        }
      }
     
    Last edited:
    Joined
    Jun 13, 2016
    Messages
    100
    Reaction score
    9
    Direct editing of the sment file...mm interesting. Something I'll have to explore
     
    Joined
    Aug 20, 2016
    Messages
    19
    Reaction score
    5
    I mean, logic (control) system will become overhelmingly better than minecraft's one or spaceengineers' one only if we will be able to directly control some complicated systems, for example: a block (with written program), connected to some actuators, can control their exact position and movement ( on button pushed or hotkey used turn rotator 78 counterclockwise, wait 7.8 seconds and activate pusher or turn on light with 67% brightness).
     
    Last edited:

    NeonSturm

    StormMaker
    Joined
    Dec 31, 2013
    Messages
    5,110
    Reaction score
    617
    • Wired for Logic
    • Thinking Positive
    • Legacy Citizen 5
    a block (with written program), connected to some actuators, can control their exact position and movement ( on button pushed or hotkey used turn rotator 78 counterclockwise, wait 7.8 seconds and activate pusher or turn on light with 67% brightness).
    no 78 in starmade and no 7.8 seconds and no 67% brightness.
    45° and 90° or 7.5sec and 8sec or 0% and 100% brightness - that's SM. You can use collisions for 78° maybe, but collisions are evil.

    It is nice that you can watch logic in action, but in my opinion you can scrap HP-points on logic blocks to make them more potent - and then make them meta-data with blocks only showing a copy, sot that they are more reliable. It's not like a silicon board IRL could get hit by firearms and still work. (Logic bit = damaged?, 9 HP-bits= logic if undamaged and even a parity-bit)
     
    Joined
    Mar 10, 2015
    Messages
    122
    Reaction score
    50
    • Community Content - Bronze 1
    • Purchased!
    • Legacy Citizen 5
    Hasn't been mentioned here yet, but one thing brought up all the other times this is suggested is that text based programming has a much higher entry barrier than logic blocks, and most people just want light switches or simple rail doors. Scriptable blocks adds a whole bunch of issues; it'll make your logic simpler, but it won't necessarily fix lag problems. It also makes it easier to share complex builds, which means anyone can build a lag monstrosity. At the very least, if you want to build a lag monstrosity now, you need an ass ton of blocks. If you really have an inkling for complex logic, you should probably just pick up a compiler and have at it on your own machine.
     
    Joined
    Aug 20, 2016
    Messages
    19
    Reaction score
    5
    Planets and ships can rotate on 78% and one light can be brighter than another, and I wish we have an opportunity to make any delay duration we want, engine can provide such things. I suggest (ask) to realize this things in game.
     
    Joined
    Jan 25, 2015
    Messages
    964
    Reaction score
    225
    • Wired for Logic
    • Councillor 2 Gold
    • Legacy Citizen 5
    Sorry to say gd80 but programming has been suggested many times. It does seem though, that you were talking about controlling the ship, is that true? Because then you'd be talking about a way people could create their own AIs, which is, I think, pretty awesome/needed. If
     
    Joined
    Feb 25, 2016
    Messages
    1,362
    Reaction score
    268
    Here's the thing---because of how light blocks work, to my understanding they are either in an "on" state or an "off" state.

    Rotation should be more doable, but it depends on how its coded. And you could wait 7.8 seconds---but not without a coding system (Delay blocks work in .5 sec intervals). And coding's not always a popular idea.
     
    Joined
    Aug 20, 2016
    Messages
    19
    Reaction score
    5
    It does seem though, that you were talking about controlling the ship, is that true? Because then you'd be talking about a way people could create their own AIs, which is, I think, pretty awesome/needed.
    Well, it could be used to create own simple "AI" (more like control system) to operate ships/action blocks/turrets/rails/your own ship (with hotkey use while in core). Its wide topic to discuss. I would be very happy if I will have opportunity just to do this through one programmed control block:
    button pushed or hotkey used turn rotator 78 counterclockwise, wait 7.8 seconds and activate pusher or turn on light with 67% brightness
    or something like that (just example).
     
    • Like
    Reactions: HolyCookie