Warning, /education/gcompris/src/activities/gnumch-equality/Diaper.qml is written in an unsupported language. File is not indexed.
0001 /* GCompris - Diaper.qml
0002 *
0003 * SPDX-FileCopyrightText: 2014 Manuel Tondeur <manueltondeur@gmail.com>
0004 *
0005 * Authors:
0006 * Joe Neeman (spuzzzzzzz@gmail.com) (GTK+ version)
0007 * Manuel Tondeur <manueltondeur@gmail.com> (Qt Quick port)
0008 *
0009 * SPDX-License-Identifier: GPL-3.0-or-later
0010 */
0011 import QtQuick 2.12
0012
0013 Monster {
0014 id: diaper
0015
0016 monsterType: "diaper"
0017 frames: 3
0018
0019 onMovingOnChanged: {
0020 if (movingOn == false && opacity == 1) {
0021 if (Math.random() > 0.5) {
0022 direction = Math.floor(Math.random()*4)
0023 }
0024 modelCells.regenCell(index)
0025 }
0026 }
0027 }