Hi everyone, i've decided to make my entry with a pbbg! I've always found pbbg's to be special and really fun, and i've always had the desire to make one and that lead me to halls tutorials and this awesome commnity.
So enough of that.
A. Working name of Game
Population (may change in future).
B. Technology behind the game.
- Node.js: with other node packages such as socket.io, mongo-lite and momentJs
- ImpactJS html5 engine: I find it way easier drawing things on the canvas element, instead of using lots of divs and nesting imgs or text inside of them and impact is just simply amazing.
- MongoDB: As my database
- PHP: will use very little though, for now it's just for the login/authentification stuff.
C: Story
Coming soon!
D: Some features
- A full browser multiplayer game.
- Dyamic interface with no refreshing the page.
- RTS like game with lots of action.
- lots of resources from apples to gold which you can exchange with your allies and some are necessary for building powerful units!
- real time combat system which can be crucial on decisive battles. You could be fighting a huge battle against your enemies and calling you allies for reinforcement can change history.
- momentum: is a bonus value that will make your armies stronger, and you can only increase it by winning battles and crushing enemies, but you can lose it by losing a battle.
- Alliances: you can team up with 2, 10 or more allies to take over the lone and weak ones.
- fog of war. Working hard on this, but hopefully, will be implemented.
Some features may change and some may be added!
If any great feature or idea just came to your mind right now, go ahead and feel free to comment it. The game is made from scratch and there're lots of things that could be added.
Working on a playable alpha so stay tuned!
Population[title WIP!]
Re: Population[title WIP!]
Sounds like a great layout. Good luck
- hallsofvallhalla
- Site Admin
- Posts: 12026
- Joined: Wed Apr 22, 2009 11:29 pm
Re: Population[title WIP!]
Good luck!
- Ringmaster
- Posts: 29
- Joined: Tue Nov 13, 2012 10:28 pm
Re: Population[title WIP!]
Nice to see Node JS and Mongo on your list.
Good Luck
Good Luck
Re: Population[title WIP!]
How's progress on the game going?
Re: Population[title WIP!]
Hi community, I haven't updated this post but the game is progressing. Thanks ringmaster those technologies are great ^^. Thanks callan for the reminder, here's the progress so far!
Devlog 1
So far so good, managed to get things from paper to the browser

already got to manage to center your city to the camera and understand mongodb.
Mongo it's pretty easy. This is a pretty simple registration and authentification code.
Mongodb simplicity makes it great, instead of tables they're collections. And you don't need to create a database beforehand, the database will only be created if you store data in it.
Also for the example above you need php_mongo extension installed on your php (A special thanks to Elvar for showing me mongo and helping me installing).
Would write more but i'm in a hurry, more progress will come!
Bye and thanks for reading.
Devlog 1
So far so good, managed to get things from paper to the browser

already got to manage to center your city to the camera and understand mongodb.
Mongo it's pretty easy. This is a pretty simple registration and authentification code.
Code: Select all
if($_POST['intro'] == 'register') {
$user = mysql_real_escape_string($_POST['username']);
$pass = mysql_real_escape_string($_POST['password']);
$pass2 = mysql_real_escape_string($_POST['password2']);
$m = new Mongo();
$db = $m->population;
$playerInfoColl = $db->playerinfo;
if($playerInfoColl->findOne( array(
"name" => $user
))) {
die('The name is already taken');
}
if($pass != $pass2) {
die('passwords doesn\'t match');
}
$document = array(
"name" => $user,
"password" => $pass
);
$playerInfoColl->insert($document);
$randPosX = mt_rand(0, 1200);
$randPosY = mt_rand(0, 1200);
$cityName = $user . '\'s city';
require_once 'functions.php';
$entityId = randId(8);
$document = array(
'cityName' => $cityName,
'cityOwner' => $user,
'cityPos' => array(
'x' => $randPosX,
'y' => $randPosY
),
'cityGold' => 500,
'entityId' => $entityId,
'capital' => true,
'entity' => 'EntityCity'
);
$citiesColl = $db->cities;
$citiesColl->insert($document);
echo '<script type=\'text/javascript\'> alert(\'register complete\') </script>';
// go to game.php ?
}
else {
$user = mysql_real_escape_string($_POST['username']);
$pass = mysql_real_escape_string($_POST['password']);
$m = new Mongo();
$db = $m->population;
$playerInfoColl = $db->playerinfo;
if($playerInfoColl->findOne( array(
"name" => $user,
"password" => $pass
))) {
session_start();
$_SESSION['player'] = $user;
echo 'login success';
header("Refresh: 2; url='game.php'");
}
else {
echo 'login failed';
}
}
}
Also for the example above you need php_mongo extension installed on your php (A special thanks to Elvar for showing me mongo and helping me installing).
Would write more but i'm in a hurry, more progress will come!
Bye and thanks for reading.
Orgullo Catracho
- hallsofvallhalla
- Site Admin
- Posts: 12026
- Joined: Wed Apr 22, 2009 11:29 pm
Re: Population[title WIP!]
great update.
- Jackolantern
- Posts: 10891
- Joined: Wed Jul 01, 2009 11:00 pm
Re: Population[title WIP!]
Glad to see some nice updates, and I like that you posted some images of your work 

The indelible lord of tl;dr