Torque backups ( help me )
by Mark Junior · in Torque Game Engine · 11/08/2007 (6:28 am) · 14 replies
Hello everybody
well ive just figured out why all my engine code changes have not worked.. Because my torque backupping. I first make a backup of the WHOLE torque folder. Then i put the backed up torque folder in a safe place somewhere in the C drive. Then i compile the whole engine. And then i go to the torque directory and all that stuff. ( not the backed up directory ) and then i do well this and that on the .cs files and i notice they dont compile anymore :O? i deleted game.cs.dso and then i couldnt run my new game at all! is this to do because i took a backup of it or is it something else? Im probably not making much sense
EDIT: Uh oh. Now i deleted the torque directory and put the backed up version back in and it still doesnt compile .cs files anymore PLEASE someone help me?
well ive just figured out why all my engine code changes have not worked.. Because my torque backupping. I first make a backup of the WHOLE torque folder. Then i put the backed up torque folder in a safe place somewhere in the C drive. Then i compile the whole engine. And then i go to the torque directory and all that stuff. ( not the backed up directory ) and then i do well this and that on the .cs files and i notice they dont compile anymore :O? i deleted game.cs.dso and then i couldnt run my new game at all! is this to do because i took a backup of it or is it something else? Im probably not making much sense
EDIT: Uh oh. Now i deleted the torque directory and put the backed up version back in and it still doesnt compile .cs files anymore PLEASE someone help me?
About the author
#2
11/08/2007 (6:39 am)
I did cleandso and now it deleted all the dsos, i launch my torquedemo.exe and it still doesn't load my mission. I went back to my game folder and it seemed to load about 4 dsos but nothing else. HMM may this be possible because it says i have 1 script error in game.cs?
#3
11/08/2007 (6:47 am)
Nope fixed the errors those are not it, can the reason be that i have 1 time saved my games directory and reinstalled an whole new fresh torque and put my game file back in there. Is that the case? that my game directory shouldve sticked with my old non fresh copy of torque?
#4
I have no idea why it wouldn't be parsing your .cs files. Are you exec'ing them?
11/08/2007 (6:57 am)
What was the script error in game.cs?I have no idea why it wouldn't be parsing your .cs files. Are you exec'ing them?
#5
11/08/2007 (9:00 am)
Yep all that ive checked. Every single thing is the way it should be. But it just wont work. Does this have anything at all to do with the torquedemo.exe having wierd engine changes or something?
#6
11/08/2007 (9:28 am)
It shouldn't. There shouldn't be anything different between the "demo" and a compiled version of the engine.
#7
EDIT: well it seems that starter.fps and starter.racing work fine. The problem is my game only :S
11/08/2007 (9:49 am)
Well ill try look around. Tell me if youve got more tips or ideas on what is wrong.EDIT: well it seems that starter.fps and starter.racing work fine. The problem is my game only :S
#8
11/08/2007 (10:08 am)
Ok, well now i have figured out nothing else is wrong except, that game.cs has some script errors maybe which is causing the mission not to launch and ofcourse all the other files that compile when mission is loading to not compile if you could look through my whole game.cs code maybe? You probably wouldn't have time to though.
#9
11/08/2007 (10:25 am)
I wish I had more time. Perhaps if you posted some of the error points, we could help.
#10
also, if you want to Do It Right (tm), install a source-control app like Tortoise Subversion and use it often. this will let you easily roll back to previously working versions when something goes wrong, and is an essential tool for any serious development.
11/08/2007 (10:31 am)
Saska - i recommend starting over, with a 100% fresh install of the codebase into a brand-new directory, and then re-implementing your changes one at a time, checking that things haven't broken at each step.also, if you want to Do It Right (tm), install a source-control app like Tortoise Subversion and use it often. this will let you easily roll back to previously working versions when something goes wrong, and is an essential tool for any serious development.
#11
If you have script errors in a TorqueScript file, that file will not compile, and therefore changes you have made within that file simply will not be applied. The short answer is, if you have errors in a script file, you have to fix them :)
Now, if you have a previously existing .cs.dso file for your file with the script errors (for example, if your file containing errors is game.cs, and a game.cs.dso file exists), that means that Torque will "fall back" to the last successful compile of that file--the .dso. Since this file (if it exists) does not contain the changes you made, it will operate just like it did when you first compiled it.
See above. If you still have errors in your game.cs, then your exec's aren't working (things are not in fact the way they should be).
11/08/2007 (11:01 am)
Just to give a bit of insight:If you have script errors in a TorqueScript file, that file will not compile, and therefore changes you have made within that file simply will not be applied. The short answer is, if you have errors in a script file, you have to fix them :)
Now, if you have a previously existing .cs.dso file for your file with the script errors (for example, if your file containing errors is game.cs, and a game.cs.dso file exists), that means that Torque will "fall back" to the last successful compile of that file--the .dso. Since this file (if it exists) does not contain the changes you made, it will operate just like it did when you first compiled it.
Quote:
What was the script error in game.cs?
I have no idea why it wouldn't be parsing your .cs files. Are you exec'ing them?
Quote:
Yep all that ive checked. Every single thing is the way it should be. But it just wont work.
Quote:
Ok, well now i have figured out nothing else is wrong except, that game.cs has some script errors maybe which is causing the mission not to launch and ofcourse all the other files that compile when mission is loading
See above. If you still have errors in your game.cs, then your exec's aren't working (things are not in fact the way they should be).
#12
function pickSpawnPoint()
{
%groupName = "MissionGroup/PlayerDropPoints";
%group = nameToID(%groupName);
if (%group != -1) {
%count = %group.getCount();
if (%count != 0) {
%index = getRandom(%count-1);
%spawn = %group.getObject(%index);
return %spawn.getTransform();
}
else
error("No spawn points found in " @ %groupName);
}
else
error("Missing spawn points group " @ %groupName);
// Could be no spawn points, in which case we'll stick the
// player at the center of the world.
return "0 0 300 1 0 0 0";
}
11/09/2007 (4:38 am)
Well the script error in game.cs is VERY VERY ODD because its from the code that came with the engine that has the error on it for somereason :function pickSpawnPoint()
{
%groupName = "MissionGroup/PlayerDropPoints";
%group = nameToID(%groupName);
if (%group != -1) {
%count = %group.getCount();
if (%count != 0) {
%index = getRandom(%count-1);
%spawn = %group.getObject(%index);
return %spawn.getTransform();
}
else
error("No spawn points found in " @ %groupName);
}
else
error("Missing spawn points group " @ %groupName);
// Could be no spawn points, in which case we'll stick the
// player at the center of the world.
return "0 0 300 1 0 0 0";
}
#13
11/09/2007 (7:19 am)
I don't have time to pick apart and solve the errors directly related to this thread, but I can throw out one very big helpful suggestion: SOURCE CONTROL. Learn it, use it, love it and thank it later for preventing this kind of train wreck. Good luck.
#14
11/09/2007 (8:00 am)
What's the error?
Associate David Montgomery-Blake
David MontgomeryBlake