1. A new version of the Alpha has been released! (July 1st)
    50 new levels for a total of 100, new art, cutscenes and much more. Download the new Alpha now!
    http://godisacube.com/for...

News - 2015 March 08 - [1 video] Cubes walking on walls and roofs

Discussion in 'News and Announcements' started by King_Kadelfek, Mar 8, 2015.

  1. King_Kadelfek

    King_Kadelfek Administrator Staff Member Age of DNA - Alpha member

    The cube direction was editable, now the cube referer is editable too. Thanks to this, you can ask cubes to walk on walls rather than the ground.



    I also changed the gravity rules to allow a momentum when the cube is on the edge. Now the cube falls only if it has no edge in contact with a terrain cube to its referer side.

    I added several runes to change referers and directions, as well as rotate them. This way, cubes can change rotate their direction / referer to go from the ground to a wall.

    Here is the complete schematics. It allows cubes to walk in concave and convex shapes, as seen in the video.
    There are surely other ways to do this. The "Rotate Direction" cubes are at the right and the bottom of the schematics.


    2015_05_08-walk_on_walls.png


    These features will be available in the next update v00.05.00.07 "Salmon Dirt".
  2. Sykodeus

    Sykodeus Member Age of DNA - Alpha member

    Looks neat.

    Is there a reason why you did not simply add vertical movement through "move" + "up", instead of that referer system ? It looks kinda complicated.
  3. King_Kadelfek

    King_Kadelfek Administrator Staff Member Age of DNA - Alpha member

    There is no "up" in space.
    When you ask a cube to go to "its left", you have in mind the fact that the cube's referer is the ground (down direction).

    When you are working on 6-axis gravity, there is no longer a main referer such as the ground.

    labyrinth-04.jpg

    Yes, it's complicated. The human mind doesn't not really think in 3D, because almost everything is attached to the ground, so it's like 2D. To work correctly with 6-axis, you have to define referers as well as directions (and "his directions").
    I go far much further with AI, up to the gifs you have seen with 3D pathfinding. At this point, you have easily 15 or 20 actions and detections one after another.
    To give you an idea, I started the whole DNA system just to write this referer / direction AI. Because it was almost impossible to write this AI using "if then" in normal code.

    That's also why there will be high level DNA. This whole schematics will be inside a cube, and you will not have to look at it:

    [​IMG]

    If you want a cube moving like in the video, you will just have to use the high level DNA containing this schematics, instead of the "Move Rune" you already know.

    Later, these kind of high level DNAs will have parameters blocks, so instead of being forced to have a "High Level Move Forward", the Forward part will be editable into a "Back" or "Left", etc.
  4. King_Kadelfek

    King_Kadelfek Administrator Staff Member Age of DNA - Alpha member

    *reread my notes and think mroe about what you said*

    For now, rules about gravity are saying that cubes fall when they are trying to make an impossible move, such as being on the edge and trying to do one more step.

    Technically, if the cube is face to the wall and try to move up, it still has a support and it should be a valid move. Therefore, Move+Up should work.

    (I talked to you about 6-axis gravity and now I realize that my current check gravity code is too much based on one-axis gravity)
  5. Sykodeus

    Sykodeus Member Age of DNA - Alpha member

    I'm a little confused by your whole explanation.

    I thought you would handle the vertical movement by something like a "climb" rune or make "move" + "up" act like a climb rune, and that would only work if there is a wall next to it. That would keep the referer always on the bottom.
    That referer system looks pretty confusing, partly because the icons are hard to understand (being a 2D representation of a 3D element), but also because, well, it is complicated.
  6. King_Kadelfek

    King_Kadelfek Administrator Staff Member Age of DNA - Alpha member

    Yes, I will implement it like that. Gravity check will look if there is a support such as a wall, and allow this move.

    The new Rune you can see on the schema is "Rotate Direction". You are walking on the ground, and you face a wall: you rotate your head to the up and now you are walking on walls.

    The referer system will not be obligatory. People will still be allowed to use Directions (such as Left) rather than His Directions (such as His Left).
    I had to implement the referer system so cubes can have their own point of view, instead of our human view "everything is sticked to the ground", "up means up".
    Thanks to the referer system, even if from our point of view the situations are different (because there are walls or ground), for the cubes they are treated the same way:

    2015_03_09-God_is_a_Cube-08h46m53s-mod.png 2015_03_09-God_is_a_Cube-08h47m10s-mod.png 2015_03_09-God_is_a_Cube-08h47m44s-mod.png
    Cube walking on ground, Cube walking on wall upward, Cube walking on wall downward

    But yes, it's complicated. It's a kind of "now you have to think with cubes". It takes time to wrap your mind around this concept.
    In a lot of situations, you can work with only one-axis gravity.


    I made a schema to help, with the world axis and the relative cubes axis:

    2015_03_09-GiaC-coordinates.png

    In Unity, I have some special views to show me the referer and the directions of the cubes. I remember you asked for a way to see them as well, I will look for a way to do so.
  7. Sykodeus

    Sykodeus Member Age of DNA - Alpha member

    So, that means you will still be able to climb a wall without having to use these referers ? That would be great, because let's say you want to make a cube that can "jump" over fences, or climb stairs, having to change referer to do this sounds over the top, since it's something a normal human can do in a simple manner.

    Could you walk on ceiling without changing referer ? It'd probably be okay if you can't, since it's an "unnatural" action for a normal being.

    I understand the referer concept now, I just find it maybe a little unnecessarily complicated. Maybe having both is a good option.
  8. King_Kadelfek

    King_Kadelfek Administrator Staff Member Age of DNA - Alpha member

    I think that I have to make the difference between the Referer and the Move Referer, the same way we have a difference between the Direction and the Move Direction.
    Whatever direction your cube is facing, you can ask him to go one step on the X Move direction. So I think the same thing could work for referers: whatever referer your cube is using, you can ask him to go one step on the X Move direction, the cube will use the Move Referer available to do this move.

    So you could walk on ceiling too.

    Note that you can also move cubes only by using Directions such as Front, and never His Directions such as His Front. This way, you don't have to care about the cube's direction or referer.

    The problem you will face is when you quit the ground: Front will still correspond to the Front direction of the Planet. If you want your cube to behave the same way on the walls or roof than it does on the ground (using His Front and such), you will have to use the cube's direction and referer.

    Before the end of the Alpha, I will implement high level DNA, so we will start to have complex structures into black boxes.
    High Level DNA is God is a Cube - Age of DNA alpha's last big part.

Share This Page