Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Topics - Bauklotz

Pages: 1 2 3 4 5 [6]
76
Modification Help / Console Command Guide
« on: February 15, 2010, 07:36:50 AM »
Quote
Title: Fun Console Commands
 Author: Bauklotz                    

Table of Contents:
   1. Description
   2. The Console
   3. Special rules
   4. Commands
   5. Support

────────────────────────────────────────

1. Description

Blockland is a fun game, though it can be funnier by using special commands in Torque Game Engine.
I've seen many topics around with titles like 'REQUEST: console commands' or 'How do I mount a player to a player?',
so I decided making a big large tequila with alot of 'em.

2. The Console

The console is like your (Windows: Command Prompt | Mac: Terminal), a window where you can send
commands to the program using the it. Blockland also has a console. If you are using Windows, a
Black/White window (looking like command prompt) with lots of messages will appear before the actual
Blockland menu. This is the console. You can either use this one, or the in-game one (which i prefer)
To open the in-game one, press ~ on your keyboard. If you are using a non-english
keybaord, it is the button below Escape, left to 1 and over tab.

3. Special rules

In Torque, functions can be inside objects, like ObjectID.doStuff(); where ObjectID is the object.
Several functions in this guide could look like this: CLIENT.doStuff(); or PLAYER.doStuff();
If you encounter this, you can use Badspot's findClientBy* functions. If you want to find by name,
instead of CLIENT, type findClientByName("Name here"), so for example
findClientByName("Bauklotz").doStuff(); - If you want to find by BL_ID, use
findClientByBL_ID(8788).doStuff(); If you encounter PLAYER, use something like this:
findClientBy<yourMethod>(<input>).player.doStuff(); - Now, comes the commands - Enjoy!

4. Commands

==> Talking as CONSOLE. (Host-Only)
Open up the console, and type the following command:
talk("You can type your own message here!");

==> Quitting Blockland
Open up the console, and type the following command:
quit();

==> Toggling jets
Open up the console, and type the following command:
jet(N);
Replace N with either 1, for yes, or 0, for no.

==> Automatic hold down of LMB
Open up the console, and type the following command:
mousefire(N);
Replace N with either 1, for yes, or 0, for no.

==> Graphical fixes
Open up the console, and type the wanted command:
Fix a completely black screen when you spawn - resetlightning();
Fix random-sized and colored lines - flushtexturecache();

==> Crash Blockland
Open up the console, and type the following command:
crash();
Result: Freezes Blockland and gives a message that Blockland stopped working.

==> Clear datablocks
Open up the console, and type the following command:
deletedatablocks();
Result: Clears all registered datablocks from your game, and crashes.

==> Find out various commands
Open up the console, and type the following command:
dumpConsoleClasses();
You may also use:
Open up the console, and type the following command:

==> Change max speed of vehicles (Host-Only)
Open up the console, and type the following commands:
<VehicleNameWithoutSpaces>Vehicle.maxWheelSpeed = <speed>;
<VehicleNameWithoutSpaces>Vehicle.maxWheelSpeed = <speed>;
Note: Both of these commands are required.
Not working? Be sure to respawn vehicles to make it work.

==> Make someone admin/SA without a message (Host-Only)
If you wish to make someone admin, type these commands:
CLIENT.isAdmin = 1;
commandToClient(CLIENT,'setAdminLevel',1);
If you wish to make someone SA, type these commands:
CLIENT.isAdmin = 1;
CLIENT.isSuperAdmin = 1;
commandToClient(CLIENT,'setAdminLevel',2);

==> Toggle Crouch
Open up the console, and type the following command:
crouch(N);
Replace N with either 1 for yes, or 0 for no.

==> Toggle Jump
Open up the console, and type the following command:
jump(N);
Replace N with either 1 for yes, or 0 for no.

==> Explode bedroom clock (Host-Only)
Open up the console, and type the following command:
explodeclock();

==> Mount a object to a player (Host-Only)
Look at a object, and type /getid in the chat.
You should recieve a object ID.
Open up the console, and type the following command:
PLAYER.mountobject(<ObjectID>,<NodeNumber0-7>);

==> Change player size (Host-Only)
PLAYER.setPlayerScale("X Y Z");
Replace X, Y and Z with each their number from 0 to 5.

==> Ban someone (Admin-Only)
Open up the console, and type the following command:
commandToServer('ban',0,<VictimBLID>,<Time>,"Your reason here!");

==> Set chasing effect on camera
Open up the console, and type the following command:
serverConnection.chaseCam(N);
Replace N with a number that may not be lower than 0, and also not too high.

==> Force people to talk (Host-Only)
Open up the console, and type the following command:
serverCmdMessageSent(CLIENT,"The message to say");

==> Start people's auto-updater (Host-Only)
Open up the console, and type the following command:
commandToClient(CLIENT,'doUpdates');
Result: Makes the person leave and start their auto-updater.

==> Control vehicles (Host-Only)
Open up the console, and type the following command:
CLIENT.setControlObject(<VehicleSpawnName>.vehicle);

==> Change datablocks (Host-Only)
Open up the console, and type the following command:
PLAYER.changeDatablock("<DataBlockName>");
Note: Datablock names can be confusing, some examples:
PlayerStandardArmor = Standard Player
HorseArmor = Horse
TankTurretPlayer = The turret on a Tank.
PlayerNoJet = No jet player
Ask someone on the forums for datablock names.

==> Delete players (Host-Only)
Open up the console, and type the following command:
PLAYER.delete();
Result: Glitches the person alot, and only allows him to talk.
How to end: Type CLIENT.instantRespawn(); in console.

==> Kill players (Host-Only)
Open up the console, and type the following command:
PLAYER.kill();

==> Unmount players (Host-Only)
Open up the console, and type the following command:
PLAYER.dismount();
Result: Makes the player go off the thing the person is mounted to, but if that person isdriving, does not stop driving.

==> Announce messages (Host-Only)
Open up the console, and type the following command:
announce("Your message here!");

==> And now for something completely diffirent, another way to crash the game.
Open up the console, and type the following command:
getNonsense();

==> Change weapon projectiles (Host-Only)
Open up the console, and type the following command:
<WeaponNameWithoutSpaces>Image.projectile = <ProjectileNameWithoutSpaces>Projectile;
Examples of weapons and projectiles:
Gun = Gun Weapon but also projectile
RocketLauncher = RocketLauncher Weapon but also projectile

==> Put messages in console
Open up the console, and type the following command:
echo("Your message here!");

==> Build a wall (Glitched)
Open up the console, and type the following command:
buildwall();

==> Build a floor
Open up the console, and type the following command:
buildfloor2();

==> Build some confetti
Open up the console, and type the following command:
buildconfetti();

==> Bottom print text to everyone (Host-Only)
Open up the console, and type the following command:
BottomPrintAll("Your message here!",<Seconds>);

==> Center print text to everyone (Host-Only)
Open up the console, and type the following command:
CenterPrintAll("Your message here!",<Seconds>);

==> Chat message text to everyone (Host-Only)
Open up the console, and type the following command:
MessageAll('',"Your message here!");
Notice: The first '' is not a ", but two of these: '

==> Crash your computer
Open up the console, and type the following command:
while(true) { }

==> Spawn a bot at your player (Host-Only)
Open up the console, and type the following command:
%bot = new aiPlayer(){datablock=playerStandardArmor; position=localClientConnection.player.getPosition();};

==> Change your local timescale
Open up the console, and type the following command:
clientCmdTimescale(<TimescaleNumber>);
Note: Setting the number higher than the servers will only lag you.

==> Build some stairs
Open up the console, and type the following command:
buildstairs();

5. Support

Torque needs perfect instructions, if you give it something it can't understand, it will cancel and give a error.
The most common error is 'Syntax error in input.' (red), if you see this, you have typed something wrong.
Things to check:
> Did you type something wrong?
> Remember that you always need the same amount of '}'s as you have typed '{'s.
> Did you use CLIENT::doStuff() instead of CLIENT.doStuff();?
If it still doesn't work, contact me or another person on the forums.

I'll add some more commands as soon as I get home.

EDIT: I see the fail:
Quote
you have typed something wrong.
Things to check:
> Did you type something wrong?

EDIT: No replys? Come on...

Pages: 1 2 3 4 5 [6]