Search Results
Search type | Search syntax |
---|---|
Tags | [tag] |
Exact | "words here" |
Author |
user:1234 user:me (yours) |
Score |
score:3 (3+) score:0 (none) |
Answers |
answers:3 (3+) answers:0 (none) isaccepted:yes hasaccepted:no inquestion:1234 |
Views | views:250 |
Code | code:"if (foo != bar)" |
Sections |
title:apples body:"apples oranges" |
URL | url:"*.example.com" |
Saves | in:saves |
Status |
closed:yes duplicate:no migrated:no wiki:no |
Types |
is:question is:answer |
Exclude |
-[tag] -apples |
For more details on advanced search visit our help page |
Phaser is a JavaScript framework for game development on desktop and mobile platforms.
1
vote
How to transfer drag control from one sprite to another? (Phaser)
Without code I'm not exactly sure what you're doing for the dragging now.
So, I see two options:
Spawn a new sprite where the old one was before and let the one that was being dragged continue to b …
1
vote
How do I get an attribute of a function?
someArray);
document.getElementById('placeholder').textContent = 'Length: ' + random.arln + ' Random item: ' + random.arst;
<div id="placeholder">
</div>
However, if you're going to continue using Phaser … you might want to look at how to extend sprites in Phaser. …
0
votes
Accepted
Setting a jump counter in my 2d platformer built with phaser
In Phaser 2, which it looks like you might be using:
jumpButton = this.game.input.keyboard.addKey(Phaser.Keyboard.SPACEBAR);
jumpButton.onDown.add(jump, this);
function jump() {
// Add your existing …
1
vote
Animations with individual images in Phaser.js
Since the asker ended up using a texture atlas, for those looking for the relevant code, preload the texture atlas as usual:
this.load.atlas('sheet', 'sheet.png', 'sheet.json', null,
Phaser.Loade …