Impact

This forum is read only and just serves as an archive. If you have any questions, please post them on github.com/phoboslab/impact

1 decade ago by hallsofvallhalla

Not sure where to put this but started a tutorial series on impact and node.socket.io

First three videos are done

http://youtu.be/adwOLUpQF0I

http://youtu.be/KlrQuiD4mWU

http://www.youtube.com/watch?v=RdpJe6lBwJ0&feature=youtu.be

or find the videos and source here
http://indie-resource.com/forums/viewforum.php?f=99

1 decade ago by Graphikos

Tutorials have a nice place to live over at http://www.pointofimpactjs.com

1 decade ago by hallsofvallhalla

they are welcome to put it up there.

1 decade ago by Graphikos

Hehe... well I built it so developers could post things themselves. It's community driven. Go post it! ;)

1 decade ago by alexandre

build it and they will come... think again

Sorry. Couldn't help it. :)


EDIT
I uploaded one of my plugins to your site, graphikos.

1 decade ago by hallsofvallhalla

oh i didnt know you built it, great site. I will post it there then thanks!

I will also put it on my next video

1 decade ago by Graphikos

Quote from hallsofvallhalla
oh i didnt know you built it, great site. I will post it there then thanks!

I will also put it on my next video


Thanks in advanced for the plug! ;)

1 decade ago by Xaan

I can't wait till you start going over the nodejs part of it. This is great, keep it up!

1 decade ago by hallsofvallhalla

Thanks! Node is about 2-3 videos away, will be this week.

1300+ views to video 2 over the weekend!

http://www.youtube.com/watch?v=KlrQuiD4mWU

1 decade ago by Xaan

I've decided to go ahead and try out Faye, so I'm working on a mini MMO (not exactly an MMO, more just like a lobby with some functionality), but I really can't wait for your node videos. :)

1 decade ago by drailing

heyho hallsofvallhalla,

ive made a nodejs/socket.io plugin a few month ago, but i stuck a bit with lags over the internet.

if you are interested to work together on some improvements or put our work together in a new plugin, ill be glad to hear from you :-)

http://impactjs.com/forums/code/impactconnect-another-node-socket-io-plugin

1 decade ago by Graphikos

Quote from Xaan
I've decided to go ahead and try out Faye, so I'm working on a mini MMO (not exactly an MMO, more just like a lobby with some functionality), but I really can't wait for your node videos. :)

A faye plugin can be found here: http://pointofimpactjs.com/plugins/view/2/multiplayer-via-publish-subscribe-messaging-system

It's quick and easy to get up and running.

1 decade ago by Xaan

Quote from Graphikos
A faye plugin can be found here: http://pointofimpactjs.com/plugins/view/2/multiplayer-via-publish-subscribe-messaging-system

It's quick and easy to get up and running.


Graphikos, I am aware of your excellent site. That is where I came across Faye a few weeks ago, but only had the courage to pick it up two days ago. I'm happy to say that I've got the skeleton for my diabolical little game in place and the server can already track a player's position. I'm working on representing other players in the client right now.

:)

1 decade ago by Graphikos

Right on... and everyone should be aware at this point but I have to plug it when I can! ;)

1 decade ago by hallsofvallhalla

I gave it a nice plugin in the last video as well :)

I am working on the Node tutorials right now. Might help to get you in the right direction on adding other players

1 decade ago by stahlmanDesign

@hallsofvallhalla

I watched your videos but never did figure out where to download the source code. Can you provide a link?

1 decade ago by hallsofvallhalla

http://indie-resource.com/forums/viewforum.php?f=99

1 decade ago by Xaan

Yep I'm a little stuck with adding other players at the moment. All I do is draw them and they keep flickering and its really slow... There are much better ways to do it, I'm sure. I'm really looking forward to your video!

1 decade ago by hallsofvallhalla

as promised here are the node/socket tutorials


video 6
http://www.youtube.com/watch?v=KnQIkKHrdFY
video 7
http://www.youtube.com/watch?v=ptvEn3iYKVY

source is here
http://www.mediafire.com/?tkb6b9k6185n7lh

1 decade ago by hallsofvallhalla

next video

http://www.youtube.com/watch?v=hARvsRQpWVE

1 decade ago by Xaan

These are great, clarified some stuff I've been wondering about. Plus, you made it to the front page of Hacker News, nice!

I do have a question though,
In the new model where you send only the command data to the server, does this also mean that you're going to have to do collision detection on the server as well? Doesn't this mean that you won't be able to use Impact's easy to use collision? Are you going to write your own collision algorithms? Or is there a way to make an Impact client on the server that still uses the collision stuff that comes with Impact?

1 decade ago by hallsofvallhalla

Wow made Hacker news? Very awesome!

Collision will be done on the client and client only. Is actually quite simple and will become clear in next few videos.

1 decade ago by Xaan

Please tell me that you're going to release more videos :)?

1 decade ago by hallsofvallhalla

yes i am, just got real busy with work.

1 decade ago by hallsofvallhalla

K I should have some new videos out very soon. Sorry for delay

1 decade ago by PhillipSchmidt

I need some help,

I want do do a "doubleshoot", when you press "x", you shoot two bullets, the second a bit after the first.
How can I do this?

I had written this, for a single shot.

// shoot
if( ig.input.pressed('shoot') ) {
ig.game.spawnEntity( this.activeWeapon, this.pos.x, this.pos.y, {flip:this.flip} );
this.shootSFX.play();
}
if( ig.input.pressed('switch') ) {
this.weapon ++;
if(this.weapon >= this.totalWeapons)
this.weapon = 0;
switch(this.weapon){
case(0):
this.activeWeapon = "EntityBullet";
break;
case(1):
this.activeWeapon = "EntityGrenade";
break;
}
this.setupAnimation(this.weapon);

1 decade ago by dungeonmaster

easiest way is to use the ig.timer and a boolean

set two properties in your ig.game extends (main.js)
myDoubleShootTimer :  new ig.timer,
secondShot : false,

in your game definition
pack your shoot block into a function
check key press in your main update loop and call this.shoot() if 'x' is pressed
if( ig.input.pressed('shoot') ) {
    this.myDoubleShootTimer.set(1);
    this.secondShot : true;  
    this.shoot();
}

below is your shoot function
shoot: function () {
    ig.game.spawnEntity( this.activeWeapon, this.pos.x, this.pos.y, {flip:this.flip} );
    this.shootSFX.play();
}
//1 seconds 

then somewhere in your update function put this
if (this.secondShot && this.myDoubleShootTimer > 0) {
    this.secondShot = false;
    this.shoot();
}

Plenty of room for optimisation but should basically work (not checked)
Page 1 of 1
« first « previous next › last »