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 axyd

Hi, I checked some games made with Impact and they looks really cool.
I would like to create simplified tower defence like RTS strategy game, and have doubts about the limits of Impact, what is possible and what's not.

Can You please clarify these questions - is it possible to do this with Impact:

- multiple unit selection with mouse (via rectangular selection tool, like WarCraft 2)
- scrolling map/screen with mouse by moving it to the borders of game window (like WarCraft 2)

Is there any other caveats? If I would like to rebuild WarCraft 2 clone, what features would be impossible to do (for me It seems that it's quite possible, there maybe a performance problems but it depends on concrete case)?

Thanks.

1 decade ago by Hareesun

As IMPACT uses javascript, and there have been javascript RTS attempts (can't remember where) I'm gonna say yeah, this is totally possible. Both points.

1 decade ago by paularmstrong

1. Multiple Selection: Should be fairly trivial by getting the rectangular space from mouse down to current mouse position and then checking the intercept of that for each entity.

2. Scroll with Mouse: Definitely possible. Just check ig.mouse for the mouses current position on update from your main game class (or a plugin) to change ig.game.screen.x/y

Your limitations will be on number of entities needing to be drawn across the board and framerate. But then again, this all depends on how complex your sprites are as well. I'm sure you can pull it off. I say go for it!

1 decade ago by Graphikos

I wouldn't think there would be any way to really capture the mouse to the bounds of the canvas making edge screen scrolling a bit difficult. You could scroll if you move the mouse to the edge of the canvas but if you go too far it'll stop scrolling.

Just a thought.

1 decade ago by dominic

Impact only draws those entities that are currently visible. So you should be okay with a few thousand entities spread over your map.

And Graphikos is correct - there's no way to "trap" the mouse cursor, but I don't think it's a problem for an RTS. Even if the cursor leaves the game screen, you could still keep scrolling in the last scroll direction.

Not beeing able to trap the cursor is more an issue for first person shooters at the moment.

1 decade ago by Graphikos

Well although it is true you could keep scrolling in the last direction you wouldn't be able to change directions unless you hover back over the canvas. Personally I'd stay away from edge screen scrolling.

1 decade ago by axyd

This is good, thanks for answers :).
Page 1 of 1
« first « previous next › last »