David Négrier
ea1460abaf
Adding variables (on the front side for now)
2021-07-02 17:36:43 +02:00
David Négrier
5b4a72ea1f
Add new "query/answer" utility functions for the scripting API
...
So far, the scripting API was using events to communicate between WA and the iFrame.
But often, the scripting API might actually want to "ask" WA a question and wait for an answer.
We dealt with this by using 2 unrelated events (in a mostly painful way).
This commit adds a "queryWorkadventure" utility function in the iFrame API that allows us
to send a query, and to wait for an answer. The query and answer events have a unique ID to be
sure the answer matches the correct query.
On the WA side, a new `IframeListener.registerAnswerer` method can be used to register a possible answer.
2021-07-02 16:49:22 +02:00
GRL
e1611969ce
Merge branch 'develop' of github.com:thecodingmachine/workadventure into jonnytest1-tiles-start-positions
2021-07-02 14:35:28 +02:00
GRL
01d02124d1
Merge branch 'develop' of github.com:thecodingmachine/workadventure into metadataScriptAPIV2
2021-07-01 11:38:33 +02:00
David Négrier
bfcdd31ed2
Fixing NPM package generation
...
The generation was broken due to the refactoring in several classes (some of them where not properly exported).
Also, trying to generate the NPM package on every build now (to detect issues).
2021-06-30 10:15:55 +02:00
GRL
389ca25b6a
Cowebsite opened by script can use Iframe Api
2021-06-28 18:00:48 +02:00
David Négrier
1e57028e6e
Renaming changeTile
to setTiles
2021-06-28 14:58:49 +02:00
David Négrier
319db95bc8
Merge branch 'develop' of github.com:thecodingmachine/workadventure into metadataScriptAPIV2
...
# Conflicts:
# front/src/Api/iframe/room.ts
2021-06-28 14:50:26 +02:00
jonny
7f61e9addd
Merge remote-tracking branch 'remotes/upstream/develop' into tiles-start-positions
2021-06-25 18:14:40 +02:00
GRL
4903911d62
Merge branch 'develop' of github.com:thecodingmachine/workadventure into metadataScriptAPIV2
2021-06-24 11:33:29 +02:00
jonny
d1178b1a01
immutableData was never assigned
2021-06-23 20:19:38 +02:00
GRL
95d8cf9257
Change requested
2021-06-23 14:54:06 +02:00
GRL
24cc340cb9
Merge branch 'metadataScriptingApi' of github.com:thecodingmachine/workadventure into metadataScriptAPIV2
2021-06-23 12:02:29 +02:00
GRL
bdb32a29e1
New methods refactored
2021-06-23 11:32:11 +02:00
GRL
85fe92f604
Merge branch 'menu-commands-apiref' of github.com:jonnytest1/workadventure into metadataScriptingApi
2021-06-23 09:18:20 +02:00
GRL
be23db5bcf
Resolve import and LoadPageEvent issue
2021-06-22 16:07:31 +02:00
jonny
64a00481f0
fixed wrong import
2021-06-21 18:39:02 +02:00
jonny
ba1bcf226a
menu command api
2021-06-21 18:22:31 +02:00
David Négrier
6101548d89
Fixing bug where only one chat listener can be added.
2021-06-21 13:47:07 +02:00
David Négrier
620bd1ab2c
Splitting classes in separated files
2021-06-21 12:26:12 +02:00
David Négrier
9129ceede1
Improving refactoring of API following @jonnytest1 feedback
2021-06-21 11:48:39 +02:00
David Négrier
34dc5a0bc6
Refactoring WorkAdventureAPI.
...
Simplifying a lot what was done (even if the new code is a bit less automated, it allows to list exactly the methods we want to see deprecated and to add a notification message)
2021-06-18 17:22:56 +02:00
jonny
702f4fe4c0
converted goToRoom to typed call
2021-06-17 11:32:59 +02:00
jonny
318749e5a8
develop merge
2021-06-17 11:30:16 +02:00
David Négrier
f6554a1082
Merge branch 'develop' of github.com:thecodingmachine/workadventure into iframe-api-refactor
...
# Conflicts:
# front/src/iframe_api.ts
2021-06-17 11:23:56 +02:00
jonny
dab3f1f844
removed zoned popups
2021-06-03 22:01:42 +02:00
jonny
8a1376e966
refactored to key based types
2021-05-28 02:28:11 +02:00
jonny
5fd82c1188
minor cleanup
2021-05-28 01:50:58 +02:00
jonny
ab631c5dc4
register callbacks
...
should be done now
2021-05-28 01:46:08 +02:00
jonny
fd5b598b63
Bubble [WIP] (still need to do the javascript part)
2021-05-28 01:18:00 +02:00
jonny
540e5783b6
cowebsite
...
navigation
sound
player
extraction
2021-05-28 01:14:10 +02:00
jonny
cbe93d7164
[WIP] fixed cherry pick conflicts
2021-05-28 00:34:40 +02:00
jonny
2de2d114a1
added typedef for subobject types
...
extracted popup functions
# Conflicts:
# front/package-lock.json
# front/package.json
# front/src/iframe_api.ts
2021-05-28 00:30:51 +02:00
jonny
1a1ab30574
extraction idea
...
# Conflicts:
# front/src/Api/ScriptUtils.ts
# front/src/iframe_api.ts
2021-05-28 00:29:21 +02:00