Standard romset, with bin file for c1/m1/p1/s1/v* etc ...
Anata
Creator of
Recent community posts
non, tu ne peux pas savoir , mais dans le cas d'une collision, tu ne peux pas justement récupérer le sys_pain 9
si tu as du Palp entre deux, il va te renvoyer les degat de palp, et non le Collide
Donc je peux pas récupérer le sys_pain 9 , il me donnera forcement le 11

dans cet exemple, tu peux pas le récupérer, tu aura que le Palp, donc 11
for exemple :
you have an actor named "Map" with tilemap Renderer , and one layer
First , you need to get the tileMap with
let map = Sup.getActor("Map").tileMapRenderer.getTileMap()after that, you can get the TileID from your position with :
let tileID = map.getTileAt(0, Math.floor(this.actor.getX()), Math.floor(this.actor.getY()))
It's just an exemple
with Superpowers v0.19 , Electron have a probleme in 64bits in all platforms.
If you want to continue use this version, download the 32bits.
or download the last release , Superpowers lates version
For exemple , to use Kongregate with your export project :
Put this link into the Index.html after export;
<script src='https://cdn1.kongregate.com/javascripts/kongregate_api.js'></script>
And in Superpowers, you can directly use :
declare let window;
let kongregate = window.kongregateAPI.getAPI();
kongregate.services.connect();
or
declare let window; let kongregate = window["kongregateAPI"]["getAPI"](); kongregate["services"]["connect"]();
Mouse dont use normal coordinate.
0 is the center of the screen game
-1 for left, 1 for right
-1 for down, 1 for up
if you want to use pixel coordinate of game screen, you can use :
camera: Sup.Camera;
awake() {
this.camera = Sup.getActor("Camera").camera;
}
update() {
let mouse = Sup.Input.getMousePosition().unproject(this.camera);
}
class ballBehavior extends Sup.Behavior{
private ballActor: Sup.Actor;
private ballAngle: number;
private ballPosition: Sup.Math.Vector3;
private ballVelocity: number;
constructor(ball) {
super(ball);
this.ballActor = new Sup.Actor("Ball");
this.ballActor.setPosition(0, 0, 0);
this.ballAngle = 0;
this.ballPosition = new Sup.Math.Vector3;
this.ballVelocity = 0;
this.ballActor.addBehavior(ballBehavior);
}
update(){
this.ballAngle += this.ballVelocity;
//Constrains the angle between 0 and 2pi
if(this.ballAngle > Math.PI * 2) this.ballAngle = 0 + this.ballAngle - Math.PI * 2;
}else if (this.ballAngle < 0) this.ballAngle = Math.PI - this.ballAngle + Math.PI * 2;
//Maybe a little spinback on the pointer?
this.ballPosition = new Sup.Math.Vector3(Math.cos(this.ballAngle) * wheelActor.getLocalScaleX() * 100 / 100, Math.sin(this.ballAngle) * wheelActor.getLocalScaleX() * 100 / 100, 0);
if(Sup.Input.wasKeyJustPressed("LEFT")) this.ballVelocity = 0.5;
}
}
dont declare all variables into constructor, always on top of this









