It is currently Thu Nov 26, 2009 10:28 pm

Welcome
Welcome to <strong>tssmods</strong>.

You are currently viewing our boards as a guest, which gives you limited access to view most discussions and access our other features. By joining our free community, you will have access to post topics, communicate privately with other members (PM), respond to polls, upload content, and access many other special features. Registration is fast, simple, and absolutely free, so please, <a href="/profile.php?mode=register">join our community today</a>!


Post a new topicPost a reply Page 1 of 1   [ 9 posts ]
Author Message
 Post subject: Tweaks
PostPosted: Sat Dec 01, 2007 2:34 pm 

Joined: Sat Dec 01, 2007 1:54 pm
Posts: 5
Here's a couple of things I found you could do:

Car Name


In case anyone needs to know, you can make a box in the botton right that says the car name.

Fine these lines in Hud.tsl:
Code:
$CarName = create ('TTextWindow', $hud);
$CarName.top = 0.675;
$CarName.left = 0.500;
$CarName.right = 0.975;
$CarName.bottom = 0.750;
$CarName.backGround = ARGB(128, 255, 128, 0);
$CarName.borderWidth = 0.002;
$CarName.visible = 0;
$CarName.color = ARGB(255, 255, 255, 255);
$CarName.shadowColor = ARGB(128, 0, 0, 0);
$CarName.fontSize = 0.04;


Code:
event carEnter($human) {
if ($human == $engine.player) {
  $speedometer.valueAddress = $engine.player.car.speedAddress;
  $speedometer.fadeTo(1);
  $RPMmeter.valueAddress = $engine.player.car.RPMAddress;
  $RPMmeter.fadeTo(1);
  //$CarName.text = $engine.player.car.name;
  //$CarName.fadeTo(1);
  //global $carNameTimer = timeOut(3.0, '$CarName.fadeTo(0)');
}
}

event carExit($human) {
if ($human == $engine.player) {
  $speedometer.valueAddress = 0;
  $speedometer.fadeTo(0);
  $RPMmeter.valueAddress = 0;
  $RPMmeter.fadeTo(0);
  //cancelTimeOut($carNameTimer);
  //$CarName.fadeTo(0);
}
}


I just took out the // slashes and changed "$CarName.visible = 0;" to a 1 value.
It should look like this:
Code:
$CarName = create ('TTextWindow', $hud);
$CarName.top = 0.675;
$CarName.left = 0.500;
$CarName.right = 0.975;
$CarName.bottom = 0.750;
$CarName.backGround = ARGB(128, 255, 128, 0);
$CarName.borderWidth = 0.002;
$CarName.visible = 1;
$CarName.color = ARGB(255, 255, 255, 255);
$CarName.shadowColor = ARGB(128, 0, 0, 0);
$CarName.fontSize = 0.04;


Code:
event carEnter($human) {
if ($human == $engine.player) {
  $speedometer.valueAddress = $engine.player.car.speedAddress;
  $speedometer.fadeTo(1);
  $RPMmeter.valueAddress = $engine.player.car.RPMAddress;
  $RPMmeter.fadeTo(1);
  $CarName.text = $engine.player.car.name;
  $CarName.fadeTo(1);
  global $carNameTimer = timeOut(3.0, '$CarName.fadeTo(0)');
}
}

event carExit($human) {
if ($human == $engine.player) {
  $speedometer.valueAddress = 0;
  $speedometer.fadeTo(0);
  $RPMmeter.valueAddress = 0;
  $RPMmeter.fadeTo(0);
  cancelTimeOut($carNameTimer);
  $CarName.fadeTo(0);
}
}



at least that's what I did. You may not need the bottom section.

Console

No, I can't tell you how to get the console. But I did notice these lines (in Console.tsl, obviously):

Code:
function TssRocks {
for ($i=0; $i<20; $i++) {
  CreateTssObj('TTssObject', 'Ball.obj', 3000+Random(-10, 10), 50, 3000+Random(-10, 10), false);
}
}

function ItRains {
$Engine.Sky.PosX = 0.3;
$Engine.Sky.PosZ = 0.3;
}


This looks like if you type "TssRocks" it makes a ball and if you type "ItRains" it starts raining.

Music

To add your own music for the radio (i'm sure a lot of you can figure this out...)

In freeride.tsl:

1.Put your music in the "Music" folder (We'll use example.wav)

2.Find these lines:


Code:
event carEnter($human) {
if ($human == $engine.player) {
  $engine.musicName = ['funkkis.ogg', 'trance.ogg', 'rokki.ogg'][random(3)];
  $engine.musicVolume = 1.0;
}
}

event carExit($human) {
if ($human == $engine.player) {
  $engine.musicName = 'Noise.mp3';
  $engine.musicVolume = 0.6;
}
}


by changing these lines you can change the music that plays on the radio, the volume, and the music/ambience that plays outside.

Here's what you change. This is if you want to add "example.wav" to the radio at a less volume and "Amibience.mp3" OR "Noise.mp3" for the noise outside AND change it to be a little louder.

Code:
event carEnter($human) {
if ($human == $engine.player) {
  $engine.musicName = ['funkkis.ogg', 'trance.ogg', 'rokki.ogg', 'example.wav'][random(4)];
  $engine.musicVolume = 0.8;
}
}

event carExit($human) {
if ($human == $engine.player) {
  $engine.musicName = ['Noise.mp3', 'Ambience.mp3'][random(2)];
  $engine.musicVolume = 1.0;
}
}


If you want to go the extra mile, change the lines above those:
Code:
$engine.musicName = 'Noise.mp3';
$engine.musicVolume = 0.6;


To something like this

Code:
$engine.musicName = 'Noise.mp3', 'Ambience.mp3'][random(2)];
$engine.musicVolume = 1.0;



To see the music name, put this into Hud.tsl under the "$CarName" Lines:

Code:
$musicName = create ('TTextWindow', $hud);
$musicName.top = 0.001;
$musicName.left = 0.700;
$musicName.right = 0.990;
$musicName.bottom = 0.05;
$musicName.backGround = ARGB(128, 0, 128, 0);
$musicName.borderWidth = 0.002;
$musicName.visible = 1;
$musicName.color = ARGB(255, 255, 255, 255);
$musicName.shadowColor = ARGB(128, 0, 0, 0);
$musicName.fontSize = 0.05;


Now, replace the next couple of lines (That start with "event carEnter($human)") with these lines.
Code:
event carEnter($human) {
if ($human == $engine.player) {
  $speedometer.valueAddress = $engine.player.car.speedAddress;
  $speedometer.fadeTo(1);
  $RPMmeter.valueAddress = $engine.player.car.RPMAddress;
  $RPMmeter.fadeTo(1);
  $musicName.text = $engine.musicName;
  $musicName.fadeTo(1);
  $CarName.text = $engine.player.car.name;
  $CarName.fadeTo(1);
  global $carNameTimer = timeOut(7.0, '$CarName.fadeTo(0)');
  global $musicNameTimer = timeOut(5.0, '$musicName.fadeTo(0)');
Credit goes to TSSkies


Pause menu

Go to MainMenu.tsl and change:
Code:
event esc() {
quit()
}

to:
Code:
load 'PauseMenu';

Its at the bottom :)
Glitches: Settings don't work but are fun to look at.
Hitting esc again leaves a permanent pause screen on the game, no pause buttons will work except exit (which leaves the game, resume brings you back)

Credit goes to Lumpy!

Hope this helps for some people. feel free to suggest something to put in here.


Last edited by Virtue on Sun Dec 02, 2007 6:03 pm, edited 5 times in total.

Top
 Profile  
 
 Post subject:
PostPosted: Sat Dec 01, 2007 8:39 pm 
Site Admin

Joined: Wed Nov 28, 2007 8:22 pm
Posts: 41
Ya i got that working yesterday but i also have added something.
Code:
$musicName = create ('TTextWindow', $hud);
$musicName.top = 0.001;
$musicName.left = 0.700;
$musicName.right = 0.990;
$musicName.bottom = 0.05;
$musicName.backGround = ARGB(128, 0, 128, 0);
$musicName.borderWidth = 0.002;
$musicName.visible = 1;
$musicName.color = ARGB(255, 255, 255, 255);
$musicName.shadowColor = ARGB(128, 0, 0, 0);
$musicName.fontSize = 0.05;

event carEnter($human) {
if ($human == $engine.player) {
  $speedometer.valueAddress = $engine.player.car.speedAddress;
  $speedometer.fadeTo(1);
  $RPMmeter.valueAddress = $engine.player.car.RPMAddress;
  $RPMmeter.fadeTo(1);
  $musicName.text = $engine.musicName;
  $musicName.fadeTo(1);
  $CarName.text = $engine.player.car.name;
  $CarName.fadeTo(1);
  global $carNameTimer = timeOut(7.0, '$CarName.fadeTo(0)');
  global $musicNameTimer = timeOut(5.0, '$musicName.fadeTo(0)');

Musicname.
:D


Top
 Profile  
 
 Post subject:
PostPosted: Sat Dec 01, 2007 9:11 pm 

Joined: Sat Dec 01, 2007 1:54 pm
Posts: 5
TSSkies wrote:
Ya i got that working yesterday but i also have added something.
Code:
$musicName = create ('TTextWindow', $hud);
$musicName.top = 0.001;
$musicName.left = 0.700;
$musicName.right = 0.990;
$musicName.bottom = 0.05;
$musicName.backGround = ARGB(128, 0, 128, 0);
$musicName.borderWidth = 0.002;
$musicName.visible = 1;
$musicName.color = ARGB(255, 255, 255, 255);
$musicName.shadowColor = ARGB(128, 0, 0, 0);
$musicName.fontSize = 0.05;

event carEnter($human) {
if ($human == $engine.player) {
  $speedometer.valueAddress = $engine.player.car.speedAddress;
  $speedometer.fadeTo(1);
  $RPMmeter.valueAddress = $engine.player.car.RPMAddress;
  $RPMmeter.fadeTo(1);
  $musicName.text = $engine.musicName;
  $musicName.fadeTo(1);
  $CarName.text = $engine.player.car.name;
  $CarName.fadeTo(1);
  global $carNameTimer = timeOut(7.0, '$CarName.fadeTo(0)');
  global $musicNameTimer = timeOut(5.0, '$musicName.fadeTo(0)');

Musicname.
:D


Oh, ok, I'll add that to the top.


Top
 Profile  
 
 Post subject:
PostPosted: Sun Dec 02, 2007 1:56 am 
User avatar

Joined: Sun Dec 02, 2007 1:41 am
Posts: 4
Location: place
Those scripts are very nice, I tried creating a radio with different music as well as an off button, but i needed an event to make it work (so it was pretty much impossible for me)

Image
http://img140.imageshack.us/img140/4887 ... estll0.jpg

I'd post the code but i think its longer than that img, plus the buttons don't actually work.


Last edited by Lumpy on Sun Dec 02, 2007 5:54 am, edited 6 times in total.

Top
 Profile  
 
 Post subject:
PostPosted: Sun Dec 02, 2007 2:07 am 
Site Admin

Joined: Wed Nov 28, 2007 8:22 pm
Posts: 41
Holy crap! nice


Top
 Profile  
 
 Post subject:
PostPosted: Sun Dec 02, 2007 2:34 am 
User avatar

Joined: Sun Dec 02, 2007 1:41 am
Posts: 4
Location: place
Thanks :D , but im afraid its just eye candy until someone decompiles the game.exe, i probably won't try to since im afraid of the legality of it, and i don't have any experience in it/never done it [its pretty much/is reverse engineering] (its usually illegal to reverse engineer copyrighted software, and some freeware. If anyone is interested a good link to view is http://www.informit.com/guides/content. ... um=18&rl=1 that explains it.) Either that, or I could give each button a set value, and when you hit esc instead of quitting you would change the music, it'd require a lot of if statements but i might as well give it a try.

Edit: Assigning IF statements didn't really work :|

Oh, and heres a nice pause menu I found, this one was incredibly easy to get:

Image

Settings doesn't work, also to get the pause menu just go to MainMenu.tsl and change:
Code:
event esc() {
quit()
}

to:
Code:
load 'PauseMenu';

Its at the bottom :)
Glitches: Settings don't work but are fun to look at.
Hitting esc again leaves a permanent pause screen on the game, no pause buttons will work except exit (which leaves the game, resume brings you back)[/code]


Top
 Profile  
 
 Post subject:
PostPosted: Sun Dec 02, 2007 6:00 pm 

Joined: Sat Dec 01, 2007 1:54 pm
Posts: 5
Lumpy wrote:
Thanks :D , but im afraid its just eye candy until someone decompiles the game.exe, i probably won't try to since im afraid of the legality of it, and i don't have any experience in it/never done it [its pretty much/is reverse engineering] (its usually illegal to reverse engineer copyrighted software, and some freeware. If anyone is interested a good link to view is http://www.informit.com/guides/content. ... um=18&rl=1 that explains it.) Either that, or I could give each button a set value, and when you hit esc instead of quitting you would change the music, it'd require a lot of if statements but i might as well give it a try.

Edit: Assigning IF statements didn't really work :|

Oh, and heres a nice pause menu I found, this one was incredibly easy to get:

Image

Settings doesn't work, also to get the pause menu just go to MainMenu.tsl and change:
Code:
event esc() {
quit()
}

to:
Code:
load 'PauseMenu';

Its at the bottom :)
Glitches: Settings don't work but are fun to look at.
Hitting esc again leaves a permanent pause screen on the game, no pause buttons will work except exit (which leaves the game, resume brings you back)[/code]


I'll add that too! BTW, I don't think it's illegal to decompile the .exe because the company seems to be dead...

EDIT: the resume on the pause menu works for me...

EDIT EDIT: I got the source!
this is the program to use:
DE Decompiler
get it at: http://www.de-decompiler.com/index.php?p=Download


Top
 Profile  
 
 Post subject:
PostPosted: Sun Dec 02, 2007 6:38 pm 
User avatar

Joined: Sun Dec 02, 2007 1:41 am
Posts: 4
Location: place
OMG Awesome find! Now we could do crazy new things like guns and online play!! :D
Also, what i mean by the resume button glitching up on me is that it will work, but if i hit ESC twice to pause it then try to resume over and over again it wont work for me. I fixed it though, it was a result of a bad code i made. Having the source is awesome, but looks difficult to modify.
Also, looks like the source was written in pascal/delphi http://en.wikipedia.org/wiki/Borland_Delphi i have no idea how to modify it right now, some of the code looks like random values to me.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Aug 25, 2008 2:10 am 

Joined: Sun Aug 24, 2008 8:34 am
Posts: 3
The Pause Menu doesn't work for me. Every time I click resume, the game freezes up without a menu, and my only option is to bring back the Pause Menu and quit.

Oh, and I can't get random music to play OUTSIDE the car, even though I followed the script.

Did you know that there's a way to move the camera BEFORE you start the game?

Just go to the MainMenu.tsl and change this:

Code:
function startMenu() {
$engine.map.filename = 'Tokyo.map';
$engine.player = createTssObj('TTssEditPlayer', 'chr_businesswoman.obj', 318.0, 25.0, 376.0, false);
$engine.player.rotate(-0.25*3.14, 0.09);
$engine.player.noMove = true;
$engine.player.onEnter = 'free $engine.player; $mainMenu.fadeTo(0); load "FreeRide";';


...into this.

Code:
function startMenu() {
$engine.map.filename = 'Tokyo.map';
$engine.player = createTssObj('TTssEditPlayer', 'chr_businesswoman.obj', 318.0, 25.0, 376.0, false);
$engine.player.rotate(-0.25*3.14, 0.09);
$engine.player.noMove = false;
$engine.player.onEnter = 'free $engine.player; $mainMenu.fadeTo(0); load "FreeRide";';
[/code]


Top
 Profile  
 
Display posts from previous:  Sort by  
Post a new topicPost a reply Page 1 of 1   [ 9 posts ]


Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron