1. This forum is obsolete and read-only. Feel free to contact us at support.keenswh.com

[Guide] Programmable Block - Block Properties

Discussion in 'Programming Guides and Tools' started by Textor, Jan 6, 2015.

Thread Status:
This last post in this thread was made more than 31 days old.
  1. Textor

    Textor Junior Engineer

    Messages:
    775
    The following are observed outputs of different block types. Universal properties are listed first, then it goes into the normal block types. Any block not listed has no unique properties, and inherits all properties from other types. You may want to use your browser's search function if you are looking for something in particular:
    Property Name Result Derived Class Notes
    BackExtend Float IMySensorBlock How far back the sensor range is
    BottomExtend Float IMySensorBlock How far down the sensor range is
    DetectAsteroids Bool IMySensorBlock Detecting asteroids?
    DetectFloatingObjects Bool IMySensorBlock Detecting floating objects?
    DetectLargeShips Bool IMySensorBlock Detects large ships?
    DetectPlayers Bool IMySensorBlock Detects players?
    DetectSmallShips Bool IMySensorBlock Detect small ships?
    DetectStations Bool IMySensorBlock Detects stations?
    FrontExtend Float IMySensorBlock How far forward sensor range is
    IsActive Bool IMySensorBlock Actively detecting something?
    LeftExtend Float IMySensorBlock How far to the left the sensor range is
    RightExtend Float IMySensorBlock How far to the right the sensor range is
    TopExtend Float IMySensorBlock How far up the sensor range is
    CollectAll Bool IMyShipConnector Is collecting materials to itself?
    IsLocked Bool IMyShipConnector "True = magnetized OR locked, false = not in range"
    ThrowOut Bool IMyShipConnector Throws items out of it into space
    ControlThrusters Bool IMyShipController Controls a ship’s thrusters?
    ControlWheels Bool IMyShipController Controls a ship’s wheels?
    DampenersOverride Bool IMyShipController Are the dampeners on?
    HandBrake Bool IMyShipController
    AccumulatedDamage Float IMySlimBlock How much damage does this have?
    BuildIntegrity Float IMySlimBlock ???
    BuildLevelRatio Float IMySlimBlock Completion %? (Unsure)
    CubeGrid IMyCubeGrid IMySlimBlock What grid the block is on
    CurrentDamage Float IMySlimBlock
    DamageRatio Float IMySlimBlock
    FatBlock IMyCubeBlock IMySlimBlock ???
    HasDeformation Bool IMySlimBlock Deformed?
    IsDestroyed Bool IMySlimBlock Block destroyed (assuming it’ll be garbage collected before this is useful)
    IsFullIntegrity Bool IMySlimBlock At full health
    IsFullyDismounted Bool IMySlimBlock ???
     
    Last edited: Apr 13, 2015
    • Informative Informative x 3
  2. Textor

    Textor Junior Engineer

    Messages:
    775
    UseConveyorSystem Bool IMyCollector/IMyLargeConveyorTurretBase/IMyProductionBlock/IMyReactor/IMyShipDrill/IMyShipToolBase/IMySmallGatlingGun/IMySmallMissileLauncher/IMySmallMissileLauncher
    Property Name Result Derived Class Notes
    BlockDefinition String IMyCubeBlock Varies by block type.
    CheckConnectionAllowed Bool IMyCubeBlock
    CubeGrid IMyCubeGrid IMyCubeBlock "Grid, including size. Example: Grid S Large 2959 {100E06F3103FCED}"
    DefinitionDisplayNameText String IMyCubeBlock Block’s Name
    DiassassembleRatio Float IMyCubeBlock
    DisplayNameText String IMyCubeBlock haven’t found anything that seems to set this yet
    IsBeingHacked Bool IMyCubeBlock
    IsFunctional Bool IMyCubeBlock
    IsWorking Bool IMyCubeBlock
    Max Vector3I IMyCubeBlock "Returns coordinites, best I can figure is that it involves the space it takes up. Example: [X:1, Y-7, Z:-15]"
    Min Vector31 IMyCubeBlock "Returns coordinates, like Max. Example (From same block as max): [X:1, Y:-8, Z:-15]"
    NumberInGrid Int IMyCubeBlock You know the number it sticks at the end of the name of a block when you’ve got multiple copies? This is that number.
    Orientation Vrage.MyBlockOrientation IMyCubeBlock I’d assume that this is the orientation of the block.
    OwnerId Long IMyCubeBlock "Returned 0 for me. I’d assume that since it is a long, it probably is the steam ID of the owner."
    Position Vector3I IMyCubeBlock Spatial coordinates relative to the world.
    CustomName String IMyTerminalBlock "The name of the block, as seen in the control panel."
    CustomNameWithFaction String IMyTerminalBlock
    DetailedInfo String IMyTerminalBlock Info from the Details part of the control panel.
    ShowOnHUD Bool IMyTerminalBlock Is the block transmitting location on HUD?
    Enabled Bool IMyFunctionalBlock Block on or off?
    HasCapacityRemaining Bool IMyBatteryBlock Is there any capacity left?
    Radius Float IMyBeacon/ IMyGravityGeneratorSphere/ IMyLightingBlock/ IMyRadioAntenna/ IMySoundBlock Range
    Blocks List<IMyTerminalBlock> IMyBlockGroup List of blocks in group
    CubeGrid IMyCubeGrid IMyBlockGroup Grid the group is on?
    Name String IMyBlockGroup Name of the group
    AnyoneCanUse Bool IMyButtonPanel Checkbox for anyone can use.
    UseConveyorSystem Bool IMyCollector/ IMyLargeConveyorTurretBase/ IMyProductionBlock/ IMyReactor/ IMyShipDrill/ IMyShipToolBase/ IMySmallGatlingGun/ IMySmallMissileLauncher
    Ma:woot:eformation Float IMySlimBlock Assuming this is how much deformation it can take before it is destroyed
    MaxIntegrity Float IMySlimBlock How much HP this has
    Position Vector3I IMySlimBlock Position relative to the world
    ShowParts Bool IMySlimBlock Show parts needed to construct? Not sure.
    StockpileAllocated Bool IMySlimBlock Assuming this is true when you’ve filled up the amount of parts required to construct it.
    StockpileEmpty Bool IMySlimBlock "Assuming this is the opposite of above, most likely will result in trash collection."
    IsSoundSelected Bool IMySoundBlock Sound is selected for block
    LoopPeriod Float IMySoundBlock How long the loop is
    Volume Float IMySoundBlock How loud it is
    IsCountingDown Bool IMyTimerBlock Is the timer currently active?
    TriggerDelay Float IMyTimerBlock How long until event triggered
    DetonationTime Float IMyWarhead Delay until Boom.
    IsCountingDown Bool IMyWarhead I’d probably evacuate the ship if this is true.
    ThrustOverride Float IMyThrust How much force the thrust override is set to.
    BlockDefinition String IMyCubeBlock Varies by block type.
    CheckConnectionAllowed Bool IMyCubeBlock
    CubeGrid IMyCubeGrid "IMyCubeBlockGrid, including size. Example: Grid S Large 2959 {100E06F3103FCED}"
    DisplayNameText String IMyCubeBlockBlock
    DiassassembleRatio Float IMyCubeBlock
    DisplayNameText String IMyCubeBlock haven’t found anything that seems to set this yet
    IsBeingHacked Bool IMyCubeBlock
    IsFunctional Bool IMyCubeBlock
    IsWorking Bool IMyCubeBlock
    Max Vector3I IMyCubeBlock "Returns coordinites, best I can figure is that it involves the space it takes up. Example: [X:1, Y-7, Z:-15]"
    Min Vector3I IMyCubeBlock "Returns coordinates, like Max. Example (From same block as max): [X:1, Y:-8, Z:-15]"
    NumberInGrid Int IMyCubeBlock You know the number it sticks at the end of the name of a block when you’ve got multiple copies? This is that number.
    Orientation Vrage.MyBlockOrientation IMyCubeBlock "I’d assume that this is the orientation of the block.OwnerIdLongIMyCubeBlockReturned 0 for me. I’d assume that since it is a long, it probably is the steam ID of the owner."
    Position Vector3I IMyCubeBlock "Spatial coordinates relative to the world.CustomNameStringIMyTerminalBlockThe name of the block, as seen in the control panel."
    CustomNameWithFaction String IMyTerminalBlock
    DetailedInfo String IMyTerminalBlock Info from the Details part of the control panel.
    ShowOnHUD Bool IMyTerminalBlock Is the block transmitting location on HUD?
    Enabled Bool IMyFunctionalBlock Block on or off?
    HasCapacityRemaining Bool IMyBatteryBlock Is there any capacity left?
    Radius Float IMyBeacon/ IMyGravityGeneratorSphere/ IMyLightingBlock/ IMyRadioAntenna/ IMySoundBlockRangeBlocksListIMyBlockGroup List of blocks in groupCubeGridIMyCubeGridIMyBlockGroupGrid the group is on?
    Name String IMyBlockGroup Name of the group
    AnyoneCanUse Bool IMyButtonPanel Checkbox for anyone can use.
     
    Last edited: Apr 13, 2015
    • Informative Informative x 3
  3. Textor

    Textor Junior Engineer

    Messages:
    775
    BackExtend Float IMySensorBlock How far back the sensor range is
    BottomExtend Float IMySensorBlock How far down the sensor range is
    DetectAsteroids Bool IMySensorBlock Detecting asteroids?
    DetectFloatingObjects Bool IMySensorBlock Detecting floating objects?
    DetectLargeShips Bool IMySensorBlock Detects large ships?
    DetectPlayers Bool IMySensorBlock Detects players?
    DetectSmallShips Bool IMySensorBlock Detect small ships?
    DetectStations Bool IMySensorBlock Detects stations?
    FrontExtend Float IMySensorBlock How far forward sensor range is
    IsActive Bool IMySensorBlock Actively detecting something?
    LeftExtend Float IMySensorBlock How far to the left the sensor range is
    RightExtend Float IMySensorBlock How far to the right the sensor range is
    TopExtend Float IMySensorBlock How far up the sensor range is
    CollectAll Bool IMyShipConnector Is collecting materials to itself?
    IsLocked Bool IMyShipConnector True = magnetized OR locked, false = not in range
    ThrowOut Bool IMyShipConnector Throws items out of it into space
    ControlThrusters Bool IMyShipController Controls a ship’s thrusters?
    ControlWheels Bool IMyShipController Controls a ship’s wheels?
    DampenersOverride Bool IMyShipController Are the dampeners on?
    HandBrake Bool IMyShipController
    AccumulatedDamage Float IMySlimBlock How much damage does this have?
    BuildIntegrity Float IMySlimBlock ???
    BuildLevelRatio Float IMySlimBlock Completion %? (Unsure)
    CubeGrid IMyCubeGrid IMySlimBlock What grid the block is on
    CurrentDamage Float IMySlimBlock
    DamageRatio Float IMySlimBlock
    FatBlock IMyCubeBlock IMySlimBlock ???
    HasDeformation Bool IMySlimBlock Deformed?
    IsDestroyed Bool IMySlimBlock Block destroyed (assuming it’ll be garbage collected before this is useful)
    IsFullIntegrity Bool IMySlimBlock At full health
    IsFullyDismounted Bool IMySlimBlock ???
     
    Last edited: Apr 13, 2015
    • Informative Informative x 3
  4. Textor

    Textor Junior Engineer

    Messages:
    775
    Ma:woot:eformation Float IMySlimBlock Assuming this is how much deformation it can take before it is destroyed
    MaxIntegrity Float IMySlimBlock How much HP this has
    Position Vector3I IMySlimBlock Position relative to the world
    ShowParts Bool IMySlimBlock Show parts needed to construct? Not sure.
    StockpileAllocated Bool IMySlimBlock Assuming this is true when you’ve filled up the amount of parts required to construct it.
    StockpileEmpty Bool IMySlimBlock "Assuming this is the opposite of above, most likely will result in trash collection."
    IsSoundSelected Bool IMySoundBlock Sound is selected for block
    LoopPeriod Float IMySoundBlock How long the loop is
    Volume Float IMySoundBlock How loud it is
    IsCountingDown Bool IMyTimerBlock Is the timer currently active?
    TriggerDelay Float IMyTimerBlock How long until event triggered
    DetonationTime Float IMyWarhead Delay until Boom.
    IsCountingDown Bool IMyWarhead I’d probably evacuate the ship if this is true.
    ThrustOverride Float IMyThrust How much force the thrust override is set to.
     
    Last edited: Apr 13, 2015
    • Informative Informative x 3
  5. Textor

    Textor Junior Engineer

    Messages:
    775
    Please let me know if you discover anything interesting about any of these, and I'll add it to the notes.
     
    • Like Like x 1
  6. Kuu Lightwing

    Kuu Lightwing Senior Engineer

    Messages:
    1,503
    so, it IS possible to distinguish grids?
     
    Last edited by a moderator: Jan 6, 2015
  7. Digi

    Digi Senior Engineer

    Messages:
    2,393
    OwnerId most likely leads to the player ID and not to a steam ID because of how permadeath works.

    CustomNameWithFaction should be the name of the block with the faction prefix that shows when it's broadcasted.
     
    Last edited by a moderator: Jan 6, 2015
  8. Arcturus

    Arcturus Senior Engineer

    Messages:
    1,649
    CurrentDamage is the current damage, counting up from zero, in terms of integrity (HP).

    MaxIntegrity is the block HP.

    Ma:woot:eformation is the current deformation of the block, in metres.
    (there is no true max deformation as far as I can tell, but large blocks tend to disappear before the value exceeds 2.5 m)

    ***The above, along with IsFunctional, could be used to make a program that gives a ship "Damage Report". However, we don't have a good UI to report the damage with!


    AccumulatedDamage is always 0 and probably has something to do with adding up multiple sources of damage during large events. One of the classes had an ApplyAccumulatedDamage() function or something like that.
     
  9. DarrikVkir

    DarrikVkir Trainee Engineer

    Messages:
    80
    FatBlock

    This is the cubeblock associated with the slimblock. Gives you a way back to the functional data if you are starting from the slimblock (such as from the CubeGrid getblocks function).
     
  10. Sirhan Blixt

    Sirhan Blixt Apprentice Engineer

    Messages:
    467
    Textor-- since you have private messaging disabled, I have to pollute your thread.

    The Min and Max properties of an IMyCubeBlock describe the corners (vertices) of the cube closest and furthest from the world origin on one edge. If you know what edge that is, you can derive the positions of the other six vertices and, therefore, the extents of the entire cube (and, therefore, the space that it takes up).

    I was thinking that Min and Max were the vertices closest and furthest from the origin, respectively, as this would put them on opposite corners of the cube and also satisfy the requirement for getting the positions of the other six vertices, but your example shows that this is not the case.
     
  11. Textor

    Textor Junior Engineer

    Messages:
    775
    I've fixed this, now. Thanks for letting me know.

    This was generated by building a small thruster onto a station and returning Min/Max.ToString(), and then posting the results as the example of what it contains. Make of that what you will. If it helps, the thruster was labeled "Down"
     
    Last edited by a moderator: Jan 8, 2015
  12. Chevalie12

    Chevalie12 Trainee Engineer

    Messages:
    34
    How do you set the values of these properties to a certain number/string? I can't find any documentation on this poorly written website, I'm starting to get really frustrated and feeling like punching a neckbeard who decided to write this.
     
  13. Textor

    Textor Junior Engineer

    Messages:
    775
    You would use the SetValue() method.

    Code:
    public static void SetValue&lt;T>(IMyTerminalBlock block, string propertyId, T value)
    
    &lt;T>- The type of value you are setting. If it is a boolean, then you would put bool here. If it is a float, you'd use float, etc.
    block - You can omit this if you are calling SetValue from a terminal block.
    propertyId - the string name of the property. For instance, "Radius"
    value - The value you are setting it to.

    For instance:

    Code:
    IMyRadioAntenna antenna;
    /*truncating initialization code*/
    antenna.SetValue&lt;float>("Radius", 10.5f); /*sets broadcast radius to 10.5*/
    
     
    • Like Like x 1
  14. Shabazza

    Shabazza Junior Engineer

    Messages:
    689
    Code:
    IMyThrust dwnThruster = GridTerminalSystem.GetBlockWithName("Small Thruster 5") as IMyThrust;
    if (null != dwnThruster)
    {
        dwnThruster.SetValue&lt;float>("ThrustOverride", 12000.0f);
    }
    
    This is not doing anything. Override stays at "0.0". I double-checked the name of the thruster.
    What am I doing wrong?
    I need to set the override immediately.
     
    Last edited by a moderator: Feb 28, 2015
  15. JoeTheDestroyer

    JoeTheDestroyer Junior Engineer

    Messages:
    573
    The property name is "Override". You should check the list, as often the Terminal Property name is not the same as Field (c# property) name used to read the same value (e.g. dwnThruster.ThrustOverride vs. "Override").
     
    Last edited by a moderator: Feb 28, 2015
  16. Shabazza

    Shabazza Junior Engineer

    Messages:
    689
    Thanks! That clarifies it.
    But then the list of properties here is kind of pointless, isn't it? It would be better if it had both, the terminal property name and the C# field name listed.
    I would also have expected Keen to give us a full API documentation of available methods ands properties until now. :(
    Having to look at a dozen different user-created places to puzzle out those infos is not really efficient.
     
  17. JoeTheDestroyer

    JoeTheDestroyer Junior Engineer

    Messages:
    573
    They have, the link I provided is the official guide provided by Keen. There is also an API doc provided with your game in the Tools folder. The OP predates the information in (or existence of) these, but there's no point in updating it when all the information can now be had from official sources.
     
  18. plaYer2k

    plaYer2k Master Engineer

    Messages:
    3,160
    Min and Max do represent the smallest X,Y,Z and the biggest X,Y,Z coordinate the block occupies. Thus a 1x1x1 block has the same Min and Max while a 1x1x2 block has only one value increased by one for Max over Min.
    A 3x3x3 block for example with Min = (X, Y, Z) has Max = Min + (2, 2, 2) as for all three dimensions the block increased by 2 blocks.

    Thus the block volume can be easily determined by Max - Min + (1, 1, 1).
     
  19. Igneous01

    Igneous01 Apprentice Engineer

    Messages:
    266
    Unfortunately that documentation is very VERY barebone. It lists what intellisense already provides. They still need to add descriptions as well as examples where it is used.
     
  20. JoeTheDestroyer

    JoeTheDestroyer Junior Engineer

    Messages:
    573
    If you're using visual studio, I suppose so. As for descriptions/examples, I wasn't expecting much to begin with in that department. The other games I've played around with scripting/modding in were also pretty bare as far as official documentation went...
     
  21. Igneous01

    Igneous01 Apprentice Engineer

    Messages:
    266
    I'm not sure what games you've played, but the ones that I played and scripted in (Arma, DCS: World) Do have proper wiki's with descriptions regarding what calls / functions / etc does what. So you could say I'm used to seeing documentation ;)
     
  22. johnwhile

    johnwhile Trainee Engineer

    Messages:
    45
    Someone can explain me why this programmable block's script crash and generate a "system memory violation" in Space Engineers 32 bit or a zero matrix in 64 bit ?
    Code:
    void Main()
    {
        List&lt;IMyTerminalBlock> panels = new List&lt;IMyTerminalBlock>();
        GridTerminalSystem.GetBlocksOfType&lt;IMyTextPanel>(panels);
        IMyTextPanel screen = (IMyTextPanel)panels[0];
        IMyMotorStator block = (IMyMotorStator)GridTerminalSystem.GetBlockWithName("Test");
        Matrix matrix = new Matrix();  
        block.Orientation.GetMatrix(out matrix);
        screen.WritePublicText(MatrixToString( matrix));
        screen.ShowPublicTextOnScreen();
    }
    public string MatrixToString(Matrix matrix)
    {
        return string.Format("{0:0.0} {1:0.0} {2:0.0} {3:0.0}\n{4:0.0} {5:0.0} {6:0.0} {7:0.0}\n{8:0.0} {9:0.0} {10:0.0} {11:0.0}\n{12:0.0} {13:0.0} {14:0.0} {15:0.0}", 
            matrix.M11, matrix.M12, matrix.M13, matrix.M14,
            matrix.M21, matrix.M22, matrix.M23, matrix.M24,
            matrix.M31, matrix.M32, matrix.M33, matrix.M34,
            matrix.M41, matrix.M42, matrix.M43, matrix.M44);
    }
    
     
  23. JoeTheDestroyer

    JoeTheDestroyer Junior Engineer

    Messages:
    573
    Element properties on matrices (.M11,etc) and vectors (.X,.Y,etc) are known to not work. Use the GetDim() function for vectors and GetRow() plus the previous for matrices.

    Both matrix and vector have ToString() methods, use those for debugging output.
     
    Last edited by a moderator: Mar 23, 2015
  24. johnwhile

    johnwhile Trainee Engineer

    Messages:
    45
    is not a problem of function... same issue for all struct get by classes, seem game lost memory pointer of struct, so when i stamp, it write always zero values.
    GetRow, GetCol, etc... use a unsafe function with a fixed pointer inside it, is a possible reason ?
    Example for this code return only row1 and don't write other vectors , if i run another time game crash.
    In 64 bit version don't crash but return alway zero values.

    Code:
    void Main()
    {
        List&lt;IMyTerminalBlock> panels = new List&lt;IMyTerminalBlock>();
        GridTerminalSystem.GetBlocksOfType&lt;IMyTextPanel>(panels);
        IMyTextPanel screen = (IMyTextPanel)panels[0];
        IMyMotorStator block = (IMyMotorStator)GridTerminalSystem.GetBlockWithName("Test");
        Matrix matrix = new Matrix();  
        block.Orientation.GetMatrix(out matrix);
        
        Vector4 v0 = matrix.GetRow(0);
        Vector4 v1 = matrix.GetRow(1);
        Vector4 v2 = matrix.GetRow(2);
        Vector4 v3 = matrix.GetRow(3);
        
        screen.WritePublicText(v0.ToString()+"\n");
        screen.WritePublicText(v1.ToString()+"\n");
        screen.WritePublicText(v2.ToString()+"\n");
        screen.WritePublicText(v3.ToString()+"\n");
        
        screen.ShowPublicTextOnScreen();
    }
    
    

    Log :
    Orientation properties is a [FONT= &#39]public struct MyBlockOrientation

    But work in some other case like [/FONT]Position , Min, Max etcc...
     
    Last edited by a moderator: Mar 23, 2015
  25. JoeTheDestroyer

    JoeTheDestroyer Junior Engineer

    Messages:
    573
    WritePublicText() overwrites (not appends) by default, so you will only see the value of v3 after that code runs.

    As for your crash, I'm confused how it could crash in "Program.MatrixToString" when you have no call to that there.

    I can say that I have personally used every function call and property you use in that (your most recent) code without incident. In particular, I can say that MyBlockOrientation.GetMatrix() works fine (although it may not do what you expect it to).

    ---

    I can't say for sure what causes these problems, though my guess would the editing Keen does to make in-game scripting safer. From what I've seen so far, functions/methods are generally safe (I can tell you for a fact that GetRow() works). Properties are hit-or-miss (Matrix.Left, .Forward work, but .Up doesn't give the expected results). Fields (such as Matrix.M11 or Vector3.X) almost never work (give garbage values in 64bit or crash in 32bit).
     
  26. johnwhile

    johnwhile Trainee Engineer

    Messages:
    45
    sorry, i put another code...

    but yes, for me crash sometime, not always:
    Code:
    block[COLOR= #666600].[/COLOR][COLOR= #660066]Orientation.Left[/COLOR]
    work but
    Code:
    block[COLOR= #666600].[/COLOR][COLOR= #660066]Orientation.Forward[/COLOR]
    Not, first time return empty value, second time crash.
     
  27. JoeTheDestroyer

    JoeTheDestroyer Junior Engineer

    Messages:
    573
    Yes, these fit with what I said too. "Orientation.Forward" is a field, so I would expect it not to work. "Orientation.Left" is a property, so it shouldn't crash and it may work (I haven't personally tested it).

    I am a C++ guy, not a C# guru (first time I touched it was about 6 months ago), so I can't tell you for certain what's going on. If I had to guess, though, it's that properties are function calls under the hood. So when you use one, you are calling Keen's code and it works. When you access a field, generated code accesses it directly, and something in the way Keen is editing that code is causing it to not work properly (hence results that look like bad pointer accesses).

    The only way around these (at the moment) is to keep looking for other ways to get what you want. For example, as I said Matrix.Up doesn't work but Matrix.Forward and Matrix.Left do. The workaround is that you can use a cross-product to get .Up from the other two.
     
  28. johnwhile

    johnwhile Trainee Engineer

    Messages:
    45
    i need only some working orientation data, matrix or direction is the same, but all ways fail. I'm waiting that dev release a new patch about mod api.
     
    Last edited by a moderator: Mar 23, 2015
  29. JoeTheDestroyer

    JoeTheDestroyer Junior Engineer

    Messages:
    573
    You'll be waiting a long time, as the dev's are glacially slow about patching anything related to the PB. The problem with switch statements was noted practically as soon as the PB was released, and we only just got a fix, 3.5 months later.

    Here are some examples of working with blocks' orientation: 1 &amp; 2. Both have been verified working in-game (single player, 64bit) by me (and presumably others).

    A warning though: If you think that MyCubeBlock.Orientation will tell you how a block is oriented in the world then you'll be disappointed. All it does is say how the block is oriented on the local grid. You have to do quite a bit more work to find out it's world orientation (see 2 above).
     
  30. Viking

    Viking Trainee Engineer

    Messages:
    15
    Hello Textor,
    I'm not sure if you already noticed that... Seems that all tables you created in your first posts in this thread were not correctly migrated to the new Forum Software.
    Instead showing tables I see the pure html code - it's not readable...
    Your table was a great help for ingame scripting! But now I cannot use it any more... :(
    Or is it only me having this problem...?
     
Thread Status:
This last post in this thread was made more than 31 days old.