xNova Revolution 5.9 Development and bugfixes

Status
Not open for further replies.
Newbie Spellweaver
Joined
Jan 28, 2007
Messages
19
Reaction score
13
Hello community!
Currently I'm in the process of hosting and fixing/improving an xNova Revolution 5.9 release.
A few years ago I helped with bug fixes of an older release, a release which eventually proved to contain too many bugs and non-developed things that I decided not to proceed trying to fix them myself. A couple of weeks ago I wanted to take a look at how far the development had come, but noticed that nothing here is actively being developed! I decided to download the latest release of xNova Revolution to have a look at how well it functions, as well as hosting it for my friends to play.


Overall, the game already functions very nicely and is very playable, but I believe there is still a lot of room for improvement and there are a number of bugs that remain to be fixed. So, I thought to continue working on this release, since still a lot of people are interested and the original developers have stopped their development.

I will use this thread to post updates and bug-fixes as I continue to improve my currently running version of the game. If anyone has suggestions to add or improve, or has any bugs or problems they would like to see fixed, let me know and I will see if I can fix it!

A few bug fixes I already made; see my posts at: http://forum.ragezone.com/f421/xnova-revolution-5-8-xnovarev-877250/index3.html#post8365606


If anyone would like to help out with the development feel free to lend me a hand and send me a message.

 
Fixed building times and research times, and fixed resourceTicker (auto refresh resource values)

Research times fix:
Replace includes/functions/GetBuildingTime.php with:


Resource Ticker:
Add this to the bottom of styles/templates/overall_topnav.tpl:
Code:
<script type="text/javascript">
window.setTimeout(function(){
    var curTime = serverTime.getTime()-1000;
    resourceTicker({ cur: {round($metal)}, limit: {$js_metal_max}, hr: {$js_metal_hr}, elem: "current_metal", startTime: curTime }, true);
    resourceTicker({ cur: {round($crystal)}, limit: {$js_crystal_max}, hr: {$js_crystal_hr}, elem: "current_crystal", startTime: curTime }, true);
    resourceTicker({ cur: {round($deuterium)}, limit: {$js_deuterium_max}, hr: {$js_deuterium_hr}, elem: "current_deuterium", startTime: curTime }, true);
    resourceTicker({ cur: {round($norio)}, limit: {$js_norio_max}, hr: {$js_norio_hr}, elem: "current_norio", startTime: curTime }, true)
}, 1000);
</script>
And replace the code in scripts/topnav.js with:
Code:
function resourceTicker(res, init) {
    if(typeof init !== "undefined" && init === true)
        window.setInterval(function(){resourceTicker(res)}, 1000);
    var element    = document.getElementById(res.elem);
    var nrResource = Math.round(res.cur + res.hr / 3600 * (serverTime.getTime() - res.startTime) / 1000);
    if (nrResource < res.limit)
        element.innerHTML = "<b>"+NumberGetHumanReadable(nrResource)+"</b>";
    else
        element.innerHTML = "<b><span style='color:#ff0000'>"+NumberGetHumanReadable(res.cur)+"</span></b>";
}
 
I'm planning on making a little script to have bot players / AI in my server.
This will be planets owned by either 'Pirates' or 'Aliens' that develop on their own and can even attack people if they wish to.

In order to get this right I need some suggestions however, does anyone have any idea on how this could be done best?
Or perhaps functionality that you want to see? I'd like to implement this but need ideas on how to make this work!
 
I'm planning on making a little script to have bot players / AI in my server.
This will be planets owned by either 'Pirates' or 'Aliens' that develop on their own and can even attack people if they wish to.

In order to get this right I need some suggestions however, does anyone have any idea on how this could be done best?
Or perhaps functionality that you want to see? I'd like to implement this but need ideas on how to make this work!

Hi,

Can you share your xNova Revolution 5.9 files? I can't find it anywhere.

About the AI/Bot Players, i think it's best if they adapt to real players level, resources...etc. That will make them more "real" than normal "Bots".

Thanks.
 
Since I'm currently working on adding bots (I have them as far as following a select buildorder), my source code is still a mess that only myself would be able to make any sense out of, any edit I made before starting to develop the bots can be found in this thread or the one in releases and you can fix those bugs yourself by following those posts.
When I'm done with adding bots (or give up because of the complexity xD) I'll post my source code of the xNova 5.9 i'm using, so you'll have a bit more tidied up release
 
I'm planning on making a little script to have bot players / AI in my server.
This will be planets owned by either 'Pirates' or 'Aliens' that develop on their own and can even attack people if they wish to.

In order to get this right I need some suggestions however, does anyone have any idea on how this could be done best?
Or perhaps functionality that you want to see? I'd like to implement this but need ideas on how to make this work!

hi i love to see how you make out on this as well
and i post a fix to add for you as well

hello all i have the fix here for the chat

will start with the chat.js on line 46
Code:
		LastGet = serverTime.getTime() / 1000 - 1;

change to this
Code:
               LastGet = serverTime.getTime() / - 1;

and then open in the includes\pages\class.ShowChatPage.php
look for line 91
Code:
				$template->execscript("showMessage();setInterval(showMessage, 10000);");
change to this
Code:
				$template->execscript("showMessage();setTimeout(showMessage, 1000);");

and now your chat will work fully
this will work for the 2moons as well ..

from the other page if find and fix any thing i'll post it here to help out..
 
I'm planning on making a little script to have bot players / AI in my server.
This will be planets owned by either 'Pirates' or 'Aliens' that develop on their own and can even attack people if they wish to.

In order to get this right I need some suggestions however, does anyone have any idea on how this could be done best?
Or perhaps functionality that you want to see? I'd like to implement this but need ideas on how to make this work!

i'll say with corn jobs may work with set times for the Ai's to be doing thing at less to start with let me know how it works out for you
i may try this as well for my game at this time i was working on making a 3rd class a 'Pirates' and or 'Aliens' class add as a AI only
wood be great..
 
Why bother with a cron? Make a time stamp from when it last ran and input into DB. then add mt_rand(value, value); to make it look like real people. add one if and your done...
 
Status
Not open for further replies.
Back