Comments (6)
Hey @oliverbhull which file are you trying to modify? It seems that certain files are regenerated by the system (mainly config.json
, intentSchema.json
, scenes.json
and utterances.txt
). I'm looking at adding similar functionality myself.
from skill-sample-nodejs-adventure-game.
In intentHandlers_default.js I was able to create a session.attributes.key and set it equal to 0. If GetKetIntent was called session.attributes key = 1 and added a line to the UseKeyIntent that if key = 1 the door opens else an error message is returned
from skill-sample-nodejs-adventure-game.
Interesting approach storing the items as game flags in the session attributes. I spent several hours try to retrofit items into the editor without much luck as it's tricky to see how riot passes around the data loaded from the scenes.json
file.
Doesn't seem like intentHandlers_default.js
gets regenerated so your approach should in theory work. Unless you're modifying GetKeyIntent
and UseKeyIntent
that was generated in intentHandlers_generated
?
There are gulp
tasks available to just zip and upload the files to AWS Lambda without regenerating them, so you might want to try adding the following lines to gulp-tasks/_default.js
:
gulp.task('upload', function () {
runSequence('upload');
});
Running gulp upload
from the Terminal while in the root folder of the project should upload the files.
from skill-sample-nodejs-adventure-game.
If you're interested I've implemented extra functionality to allow scene flags to be set on entry or exit of a scene. This can allow the user to pick up items (e.g. keys) which can then be used to access other scenes (e.g. opening locked doors). You could use the same system to create combination lock door puzzles where the user must flip switches in the right combination in order to open a door.
It has the GUI to support this in the editor and generates the correct JSON and other files to upload. I still need to add support for an alternate scene description if the user has specific scene flags set (e.g. not showing that there is a key in the room if the user has already picked up the key).
You can see the progress here on my feature branch.
from skill-sample-nodejs-adventure-game.
Just jumping in to confirm @HAZARDU5's comments. We're generating the skill assets so you can't really modify them directly. Looking forward to see how your feature branch progresses, these sound like great additions!
from skill-sample-nodejs-adventure-game.
I've now implemented alternate scene descriptions and fixed a few bugs which caused it to show the original scene description when the "repeat scene" or "go back" utterance. The session flags also now reset when using the "reset skill" utterance. There is also in-line help provided for most of the new fields in the edit scene panel.
I have an example game on my examples/items branch which showcases these new features.
from skill-sample-nodejs-adventure-game.
Related Issues (20)
- Build Error during npm install HOT 2
- Error During NPM Start HOT 2
- Guy's how do I record my name on alexa? and Reprompt it so....E HOT 1
- Where is gamebook.zip ? HOT 3
- Windows install missing files
- No .ask folder in repo HOT 3
- Could not open file: /index.js HOT 4
- Cannot
- Cannot "ask deploy"... Saying no skill.json or root! Also git error! HOT 18
- What does this line do? const linksRegex = /\[\[([^\|\]]*)\|?([^\]]*)\]\]/g; HOT 3
- ask deploy gives error HOT 6
- Unable to fine gamebook.zip file as mentioned in the instructions HOT 8
- What happened to the original version??!! HOT 7
- Repository not found HOT 4
- Request is not valid - Error parsing the requested content. Please validate the input HOT 5
- The repository link in the ReadMe.md file is incorrect HOT 1
- Instructions out of date in building template HOT 1
- Cannot find module 'alexa-sdk' HOT 1
- Inventory System
- Twine Variables Not Resolving
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from skill-sample-nodejs-adventure-game.