stock code scoring
by Donald Teal · in Torque 3D Professional · 11/03/2010 (4:52 pm) · 2 replies
am I the only one that the stock scoring doesn't work for? I went all the way back to 1.0.1 and in there when you kill an opponent it says they took their own life and gives them -1 points. the shooter gets nothing. In 1.1 betas you get nothing at all other than a death count. I have even tested this in the example FPS. I understand that these are not complete games or are generic packages for various uses but if something is going to be part of the code I feel it should work as its supposed to. Does anyone know if this is a planned fix or will it continue to be ignored?
About the author
#2
11/03/2010 (7:15 pm)
game ranking system sounds like it might be useful. currently using the client host for server but will be moving to dedicated server once I get some issues worked out. I am currently using the UAiSK for teams and scoring but it has bothered me for a long time that the included scoring system doesn't function. That was why I posted about it, to help bring it back up for the QA department to finally take a look at it. I will keep an eye out for your system. it will be handy indeed.
Torque Owner Jules
Something2Play
you could do something like this;
in; gameCore.cs add:
In function GameConnection::onConnect(%client, %name) add: %client.score = 0; then add: function GameConnection::updateScore(%client) { %scoreToUpdate = %client.score; echo ("Players Score " @ %scoreToUpdate); // echo the score out in the console commandToClient(%client, 'PlayerScore', %scoreToUpdate); } In a text field in play GUI echo out the string in the variable line %scoreToUpdate to show your score. In function GameCore::onDeath(%game, %client, %sourceObject, %sourceClient, %damageType, %damLoc) add: if (%obj.getState() $= "Dead") { if (isObject(%sourceClient)) { %sourceClient.score+=1; this.updateScore(); } }Totally from my head and untested. edited.. missed a bit out :)
Also, I can't remember if your game used dedicated server, if it is you may be interested in the Game Ranking System that I'm finally launching as a tool in the next week (Torque script, php scripts for website, mysql and management backend system). Its more for tracking scores and league tables for multiple servers, and placing the scores in league tables in a database or website. Can also be used for single player game where internet access is available to also track scores.