From 01f04c4229303bbaa732f194124a1c75804b668e Mon Sep 17 00:00:00 2001 From: Fabien Benetou Date: Mon, 10 Apr 2023 15:14:38 +0200 Subject: [PATCH] example of jumping (tested on desktop only, assuming ground at 0) --- index.html | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/index.html b/index.html index 5a14356..1b1573f 100644 --- a/index.html +++ b/index.html @@ -3005,6 +3005,10 @@ AFRAME.registerComponent('collision-check', { } }); +function jump(){ + document.getElementById("rig").emit(`jump`, null, false) +} + // used for testing AFRAME.registerComponent('startfunctions', { init: function () { @@ -3040,7 +3044,7 @@ AFRAME.registerComponent('startfunctions', { - +