Forums Index >> Modding >> Something doesn't work...



Page : <1> :


I try to use some of the objects on a mod,but they won't work! :S

It used to work perfectly!

Thursday, June 10, 2004 at 9:12:01 PM

Read the top, if you are modding, don't post here. BT doesn't support it.

Saturday, June 12, 2004 at 6:38:16 PM
-z-

Thread move to modding forum

 

 

 

 

Saturday, June 12, 2004 at 7:25:00 PM

Ok, my comment above no longer applies ;)

Saturday, June 12, 2004 at 8:44:27 PM

Thats what the delete button is for :)

Saturday, June 12, 2004 at 8:45:09 PM

Okkaaaayyyy. Didn't read the notice sorry,anyway,My think tanks game does't work altogether now! And all I did was download modwizard and install it!

Saturday, June 12, 2004 at 9:53:43 PM
-z-

Then it sounds like you have made a mistake with copying the couple of lines of code into "main.cs". If you have even just omitted a semi colon or put it in the wrong place, it is probably throwing up errors when you try and run it - thus think tanks wont start. Take another look at "main.cs" and triple check what you added. If you cant see any error, then your best bet is to reinstall ThinkTanks.

 

 

 

 

Sunday, June 13, 2004 at 4:12:55 AM

Thank ya -Z-! I'll do it!

For those who want details...(Thought I doubt there is any) When I double click the short cut,ThinkTanks absorbs all of my CPU spaces,and never runs.

Sunday, June 13, 2004 at 4:45:12 AM

Run a dedicated server (thinktanks/dedicated/any of the missions) and look for it to have errors.

Sunday, June 13, 2004 at 12:28:36 PM

If ur main.cs has errors it wont work, here's wut mine looks like

//-----------------------------------------------------------------------------

// Torque Game Engine

//

// Copyright (c) 2001 GarageGames.Com

// Portions Copyright (c) 2001 by Sierra Online, Inc.

//-----------------------------------------------------------------------------

$baseMods = "common";

$userMods = "game";

$displayHelp = false;

//-----------------------------------------------------------------------------

// Support functions used to manage the mod string

Function pushFront(%list, %token, %delim)

{

If (%list !$= "")

Return %token @ %delim @ %list;

Return %token;

}

Function pushBack(%list, %token, %delim)

{

If (%list !$= "")

Return %list @ %delim @ %token;

Return %token;

}

Function popFront(%list, %delim)

{

Return nextToken(%list, unused, %delim);

}

Function doCompileAll()

{

For(%file = findFirstFile("*.cs"); %file !$= ""; %file = findNextFile("*.cs"))

{

If (strstr(%file,"/CVS/") != -1)

Continue;

Compile(%file);

}

For(%file = findFirstFile("*.gui"); %file !$= ""; %file = findNextFile("*.gui"))

{

If (strstr(%file,"/CVS/") != -1)

Continue;

Compile(%file);

}

%misfile = new FileObject();

If (%misfile.openForWrite("game/data/missions/missions.txt"))

{

Exec("common/server/missionInfo.cs");

%misfile.writeLine("[name]");

For (%file = findFirstFile("*.mis"); %file !$= ""; %file = findNextFile("*.mis"))

{

If (strstr(%file,"/TT") == -1 && strstr(%file,"Brain") == -1)

Continue;

If (strstr(%file,"/CVS/") != -1)

Continue;

BuildLoadInfo(%file);

While (strstr(%file,"/") != -1)

%file = getSubStr(%file,strstr(%file,"/")+1,strlen(%file)-strstr(%file,"/")-1);

%file = getSubStr(%file,0,strlen(%file)-4);

%misfile.writeLine(%file @ "=" @ MissionInfo.name);

}

%misfile.close();

ClearLoadInfo();

}

%savePref = $pref::Terrain::useSmall;

$pref::Terrain::useSmall = false;

For(%file = findFirstFile("*.ter"); %file !$= ""; %file = findNextFile("*.ter"))

{

If (strstr(%file,"/TT") == -1)

Continue;

If (strstr(%file,"/CVS/") != -1)

Continue;

%terr = new TerrainBlock() {

TerrainFile = %file;

SquareSize = "8";

Tile = "0";

BlockShift = "7";

};

If (%terr.blockShift == 7)

{

// possible that terrain was already 6, even though

// block shift was set to 7 in constructor above...

//...that's why this is conditional.

Echo("Reducing terrain :" @ %file);

%terr.blockShift = "6";

%terr.resave("","_LO");

}

%terr.delete();

}

$pref::Terrain::useSmall = %savePref;

}

//------------------------------------------------------------------------------

// Process command line arguments

For ($I = 1; $I < $Game::argc ; $I++)

{

$arg = $Game::argv[$I];

$nextArg = $Game::argv[$I+1];

$hasNextArg = $Game::argc - $I > 1;

$logModeSpecified = false;

Switch$ ($arg)

{

//--------------------

Case "-log":

$argUsed[$I]++;

If ($hasNextArg)

{

// Turn on console logging

If ($nextArg != 0)

{

// Dump existing console to logfile first.

$nextArg += 4;

}

SetLogMode($nextArg);

$logModeSpecified = true;

$argUsed[$I+1]++;

$I++;

}

Else

Error("Error: Missing Command Line argument. Usage: -log <Mode: 0,1,2>");

//--------------------

Case "-demo":

$argUsed[$I]++;

$Game::DemoMode = true;

//--------------------

Case "-show":

// A useful shortcut for -mod show

$userMods = strreplace($userMods, "show", "");

$userMods = pushFront($userMods, "show", ";");

$argUsed[$I]++;

//--------------------

Case "-console":

EnableWinConsole(true);

$argUsed[$I]++;

//--------------------

Case "-compileAll":

$argUsed[$I]++;

EnableWinConsole(true);

// call doCompileAll() below...

//--------------------

Case "-jSave":

$argUsed[$I]++;

If ($hasNextArg)

{

Echo("Saving event log to journal: " @ $nextArg);

SaveJournal($nextArg);

$argUsed[$I+1]++;

$I++;

}

Else

Error("Error: Missing Command Line argument. Usage: -jSave <journal_name>");

//--------------------

Case "-jPlay":

$argUsed[$I]++;

If ($hasNextArg)

{

PlayJournal($nextArg,false);

$argUsed[$I+1]++;

$I++;

}

Else

Error("Error: Missing Command Line argument. Usage: -jPlay <journal_name>");

//--------------------

Case "-jDebug":

$argUsed[$I]++;

If ($hasNextArg)

{

PlayJournal($nextArg,true);

$argUsed[$I+1]++;

$I++;

}

Else

Error("Error: Missing Command Line argument. Usage: -jDebug <journal_name>");

//-------------------

Case "-help":

$displayHelp = true;

$argUsed[$I]++;

//-------------------

Case "-test":

$Game::testMode=true;

$argUsed[$I]++;

}

}

//-----------------------------------------------------------------------------

// The displayHelp, onStart, onExit and parseArgs function are overriden

// by mod packages to get hooked into initialization and cleanup.

Function onStart()

{

// Default startup function

}

Function onExit()

{

// OnExit is called directly from C++ code, whereas onStart is

// invoked at the end of this file.

Disconnect();

}

Function parseArgs()

{

// Here for mod override, the arguments have already

// been parsed.

}

Package Help {

Function onExit() {

// Override onExit when displaying help

}

};

Function displayHelp() {

ActivatePackage(Help);

// Notes on logmode: console logging is written to console.log.

// -log 0 disables console logging. (default)

// -log 1 appends to existing logfile; it also closes the file

// (flushing the write buffer) after every write.

// -log 2 overwrites any existing logfile; it also only closes

// the logfile when the application shuts down.

Error(

"ThinkTanks command line options: "@

" -log <logmode> Logging behavior; see main.cs comments for details "@

" -console Open a separate console "@

" -jSave <file_name> Record a journal "@

" -jPlay <file_name> Play back a journal "@

" -jDebug <file_name> Play back a journal and issue an int3 at the end "@

" -test Test launch the app "@

" -help Display this help message "

);

}

//--------------------------------------------------------------------------

// Default to a new logfile each session.

If (!$logModeSpecified) {

SetLogMode(0);

}

// Set the mod path which dictates which directories will be visible

// to the scripts and the resource engine.

$modPath = pushback($userMods, $baseMods, ";");

SetModPaths($modPath);

// Get the first mod on the list, which will be the last to be applied... This

// does not modify the list.

NextToken($modPath, currentMod, ";");

// Execute startup scripts for each mod, starting at base and working up

Echo("--------- Loading MODS ---------");

Function loadMods(%modPath)

{

%modPath = nextToken(%modPath, token, ";");

If (%modPath !$= "")

LoadMods(%modPath);

Exec(%token @ "/main.cs");

}

LoadMods($modPath);

Echo("");

// Parse the command line arguments

Echo("--------- Parsing Arguments ---------");

ParseArgs();

// Either display the help message or startup the app.

If ($displayHelp)

{

EnableWinConsole(true);

DisplayHelp();

}

Else if ($Game::argc==2 && $Game::argv[1] $= "-compileAll")

{

DoCompileAll();

Quit();

}

Else

{

OnStart();

Echo("Engine initialized...");

}

// Display an error message for unused arguments

For ($I = 1; $I < $Game::argc; $I++) {

If (!$argUsed[$I])

Error("Error: Unkown command line argument: " @ $Game::argv[$I]);

}

Exec("game/client/scripts/wingman/loader.cs");

}

Exec("game/server/scripts/emitters.cs");

}

Exec("game/client/scripts/camswitcher.cs");

}

// ModWizard

Exec("game/server/scripts/ModWizardMain.cs");

If (!$Server::Dedicated) {

MoveMap.bindCmd(keyboard, "m", "", "exec("game/client/scripts/ModWizardBindings.cs");");

}

//Nametoggler script by Nathan

Function toggleNames(%val)

{

If(%val)

{

For(%i = 0;%i < PlayGui.getCount(); %i++)

{

%obj = PlayGui.getObject(%i);

If(%obj.getClassName()$="GuiShapeNameHud")

{

%obj.visible = !%obj.visible;

Return;

}

}

}

}

MoveMap.bind(keyboard,"ctrl n",toggleNames);

}

If (!$server::dedicated) { moveMap.bindCmd(keyboard, "p", "", "commandToServer('messageSent', "----------PASS--------");");

}

RadarHud.dotWidth = "16";

RadarHud.dotHeight = "8";

}

 

Sunday, June 13, 2004 at 12:59:51 PM

But it will tell you if it execed it or not.

Sunday, June 13, 2004 at 2:47:44 PM

Solved it,needed to reinstalll.

Sunday, June 13, 2004 at 10:59:16 PM

Page : <1> :

insert quote insert url insert email insert image bold italic underline superscript subscript horizontal rule : : Help on using forum codes

Add comment:

HTML is disabled within comments, but ZBB Code is enabled.

Back to the top

Web site designed, maintained and funded by -z- and Dan MacDonald