Learn what Felgo offers to help your business succeed. Start your free evaluation today! Felgo for Your Business

Stack With Friends Demo

 import QtQuick 2.0
 import Felgo 3.0

 EntityBase {
   entityType: "ceiling"

   // this gets used by the top wall to detect when the game is over
   signal collidedWithBox

   Row {
     x: 16
     Repeater {
       model: 26
       Image {
         source: "../../assets/img/ceiling.png"
         width: 16
         height: 16

   BoxCollider {
     anchors.fill: parent
     bodyType: Body.Static // the body shouldnt move

     fixture.onBeginContact: {
       // for access of the collided entity and the entityType and entityId:
       var collidedEntity = other.getBody().target;
       var collidedEntityType = collidedEntity.entityType;
       // avoid emitting the signal at collision with obstacle while in levelEditing mode
       // otherwise the game would be reset if an obstacle would collide with the top wall
       if(collidedEntityType === "box")
Qt_Technology_Partner_RGB_475 Qt_Service_Partner_RGB_475_padded