samfcmc / bombermanandroid Goto Github PK
View Code? Open in Web Editor NEWBomberman game in Android
Bomberman game in Android
After droping a bomb, the explosion stays there forever but nothing happens when the player touches it
Check this out
http://greenrobot.github.io/EventBus/
I implemented the animated movement. Now you can see the movement depending of the speed but... For instance, you click -> <- the Bomberman will go to right and after that go to left. But, usually, when we perform a sequence like this, we just want to cancel the right moving and move to left instead (and that can save us from being touched by a robot). Well... with our implementation, that is just impossible because we execute all the received commands no mather what!...
Do we really want something like this? Will not be better to have just one command and when the player presses one direction overrides the previous one? Because... remember... that can save your life (in the game of course)
The collision detection system has a simple approach, when a player press a button to execute a movement, the action is performed only if the element on the adjacent cell is not a collidable element. To refine this implementation we need to consider the concept of interpenetration of elements, but i don't know if it is really necessary implement this functionality for a simple game like ours.
There are hardcoded strings in Run Game Activity code to update text in some text views. That strings should go to strings.xml file instead
To detect a collision between two movables, the method checkDeadlyCollision make a cast from Model type to Movable type. Even that we can assure that Model object is indeed a Movable object, sh*t could happens.
If there's no more levels, go back to the first one
As you can see, the robots now can... Eat each other. When a robot goes to a cell where there is another robot, one of them simple disappear. That's because one cell can only contain one model at a time.
But... I think we should consider some cells to have multiple "layers". For instance, in multiplayer, it's easy for any player to block any other player's way. I think it's not fair, we should only kill other players with bombs and not block their way too.
My ideia is to change the grid to have a matrix of blocks instead of models. We could have two kinds of blocks, SimpleLayerBlock, which only contains one model and MultiLayerBlock that can contain several models. It's easier to do than it sounds.
Another example where this can be useful is when a player drops a bomb. The bomb should appear behind the bomberman, in the same position where the bomberman is.
We should do a brainstorming about this. What do you think?
I think the deltas for animated movement are not being calculated in the right way. We have a speed of 2 in Bomberman but no way it makes it. The speed is in the number of cells per second. To calculate the deltas the formula is:
delta = (INTERVAL * speed * cell_size) / 1000
where INTERVAL is the time interval which we used to schedule the game thread and cell_size is the size of each cell (All cells have the same size of course)
Is this math wrong? We should ask this to the teacher...
We should discuss how to implement the multiplayer mode.
Are we going start implementing the centralized version or go straight to wifi direct instead?
Can be an activity with a button to create a new game and a list with games around the user
The module responsible to implement the CDS change the positions at the grid right after that detects that there are no collision between the elements. I need to change that to be coherent with the approach that is used at the movement branch
The collision system is already implemented, but still need some improvements, namely the cases in that the Bomberman collides with a enemy and dies, and the case when two enemies collides, and change both their direction.
Need to fix the grid aspect radio to fit in the canvas properly.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.