Quantcast

Jump to content

» «
Photo

GTA:LC Launcher

115 replies to this topic
Y_Less
  • Y_Less

    629

  • Members
  • Joined: 14 Mar 2004

#31

Posted 19 December 2005 - 06:06 PM Edited by Y_Less, 20 December 2005 - 07:00 PM.

I just thought of an addition that could be useful, debug/standard choice. Add an option into the launcher (in either advanced or in the normal launcher options) - launch in debug, easy enough to do, just change the text at 0x2862AC and 0x2D4F6D (in the EXE) or 0x6886AC and 0x6D736D (in memory) - don't know which address should be changed, probably the memory ones - to either MAIN for debug or FULL for not debug.

I would edit the code myself but don't have a delphi compiler.

Also the names are both handilly 4 letters long so there's no problems with that.

Edit: The SCMs should probably be swapped round as non-debug and MAIN are the default options and are opposite currently.

Edit 2: Or even better a '-debug' command line switch so you could run it from a shortcut.

Edit 3: Missed a number out of an address!

Ben
  • Ben

    Retired

  • Members
  • Joined: 12 May 2005

#32

Posted 19 December 2005 - 10:58 PM

That's a really good idea - I wish I thought of that tounge.gif ! No more playing around with MB. Hopefully Hammer will be able to do that at the same time as fixing the launcher so it works with the German version too.

I personally like the idea of running it from a shortcut - then you could have two launchers:
1. gta-lc.exe (normal - as it is now), and
2. gta-lc-debug.exe (or something similar; obviously with debug mode on).

Then you just need to add a quick description in the readme that explains the difference between the two, what the debug does, etc. Pretty simple for someone as advanced as Hammer.

Y_Less
  • Y_Less

    629

  • Members
  • Joined: 14 Mar 2004

#33

Posted 20 December 2005 - 04:18 PM

It's not even that hard, just run the launcher from a shortcut with the path:

'"meh/gta-lc.exe" -debug'

and it will work. I don't even know delphi and I figured out the code to add a checkbox into the launcher config to start in that mode, but I only have the offsets for the EU EXE and don't have a delphi compiler so thats not much use.

GTAThomas
  • GTAThomas

    Soldier

  • Members
  • Joined: 27 Oct 2005

#34

Posted 21 December 2005 - 04:08 AM

thats brillient! Really good find and i like the ideas alot...
it would make it very simple for anybody to go to debug, no more 3rd island questions! yay! i like the 2 exe ideas also, but if Y-Less' solvation works good ill give it a try.

Y_Less
  • Y_Less

    629

  • Members
  • Joined: 14 Mar 2004

#35

Posted 21 December 2005 - 04:16 AM Edited by Y_Less, 21 December 2005 - 04:25 AM.

Right, I looked at the code and managed to add in a debug option, but my compiled launcher is about 400k bigger than Hammers, so I'll leave it to him.

I added the following code to "procedure TfrmLauncher.btnLaunchClick(Sender: TObject);" in uLCLaunch.pas.

Under the 'vars' section:

CODE
 EnableDebug: boolean;


And just above the " (* Disable moving objects *)":

CODE
       if EnableDebug then
       begin
   SubVal := 0;
   if GTAMemory.GTAVersion = verGTAVC_11_AUS then
           SubVal := $8;
         BufStr := 'DBUG';
         GTAMemory.WriteAddr($6886AC - SubVal, @(BufStr[1]), 4);
         GTAMemory.WriteAddr($6D736D - SubVal, @(BufStr[1]), 4);
       end;




Note: this code assumes the MAIN.SCM is the standard code and DBUG.SCM is the debug code (if you can't figure out how to change that there's something wrong).

It may infact be easier to set the variable to 1 in the SCM but that would require setting it BEFORE the other code is executed and therefore BEFORE the debug var is set, therefore you would need to alter that EXACT point in memory, which would be hard as it would change with every SCM update.

I also added a checkbox in the launcher config but for some reason that doesn't show up.

Note also that Im not sure of the Australian offset difference, this will work on EU/US EXEs.

Edit: missed a bit, you need:

CODE
// Read -debug from command line
   EnableDebug := SameText(ParamStr(1), '-debug') or
                 Ini.ReadBool('Misc', 'Debug', False);


Just under;

IsRussian := Ini.ReadBool('Exe', 'LangRus', False);

that line, sorry (also note the presence of an ini thing there - thats for the GUI and so you can add Debug=1 to the ini and it will run in debug.

Y_Less
  • Y_Less

    629

  • Members
  • Joined: 14 Mar 2004

#36

Posted 21 December 2005 - 06:08 PM

Double post, sorry.

I managed to completely redo the launcher, although it is bigger than the original. It has the -debug command switch, Debug=1 in the ini or a checkbox in the launcher.

Not bad considering I couldn't program in Delphi yesterday.

Linky (right-click save as).

Ben
  • Ben

    Retired

  • Members
  • Joined: 12 May 2005

#37

Posted 21 December 2005 - 10:35 PM

Does that still only work with the EU/US exe?

OT - Also, congrats on earning your 5 karma stars. rah.gif icon14.gif

Y_Less
  • Y_Less

    629

  • Members
  • Joined: 14 Mar 2004

#38

Posted 21 December 2005 - 10:39 PM

QUOTE (benisablink182fan @ Dec 21 2005, 22:35)
Does that still only work with the EU/US exe?

OT - Also, congrats on earning your 5 karma stars. rah.gif icon14.gif

Unfortunately, I don't have an Ausse EXE, little help?

And cheers.

GTAThomas
  • GTAThomas

    Soldier

  • Members
  • Joined: 27 Oct 2005

#39

Posted 22 December 2005 - 05:47 PM

i think hammer would have that exe. PM, maybe? looks pretty neat, a lot easier i must say.

Y_Less
  • Y_Less

    629

  • Members
  • Joined: 14 Mar 2004

#40

Posted 22 December 2005 - 05:49 PM

He does, but he's not on till the weekend so I can't ask him yet, I have PMed him though.

random_download
  • random_download

    :o

  • Members
  • Joined: 07 Mar 2004

#41

Posted 08 January 2006 - 10:47 AM

QUOTE (Y_Less @ Dec 21 2005, 18:08)
Double post, sorry.

I managed to completely redo the launcher, although it is bigger than the original. It has the -debug command switch, Debug=1 in the ini or a checkbox in the launcher.

Not bad considering I couldn't program in Delphi yesterday.

Linky (right-click save as).

Try removing units from the uses section that you don't use.

poedgirl
  • poedgirl

    Snitch

  • Members
  • Joined: 26 Jun 2005

#42

Posted 09 March 2006 - 11:41 AM

While I don't have this patch installed, GTA LC starts up (shows the menu), but it says there's no audio hardware. After applying this patch I get the error: "Error while initializing GTA: LC" just after the intro movie.

Y_Less
  • Y_Less

    629

  • Members
  • Joined: 14 Mar 2004

#43

Posted 09 March 2006 - 06:54 PM

Which patch? The launcher? You need to run the game by the launcher, don't just run GTA-VC.EXE

Ben
  • Ben

    Retired

  • Members
  • Joined: 12 May 2005

#44

Posted 10 March 2006 - 06:02 AM

The launcher update that makes LC compatible with the Aussie VC I'm assuming.

@poedgirl - you're best off waiting until Hammer updates the launcher again, which should be within the next few weeks I'd imagine, if all goes well icon14.gif . Although installing this "patch" should fix your problems.

Hammer83
  • Hammer83

    Hustler

  • Members
  • Joined: 11 Jan 2003

#45

Posted 12 March 2006 - 07:53 PM

Sorry guys, it's taking me forever to find corresponding offsets in the two german executables that I received. I'm done with the launcher and the asi, but vcopcode is still long way before completion. I was hoping to get it done today, but it appears that I can't. Lets hope I'll be done next weekend.

Craig Kostelecky
  • Craig Kostelecky

    GTA:LC Team Leader

  • The Connection
  • Joined: 28 Jan 2004

#46

Posted 26 March 2006 - 09:49 PM Edited by benisablink182fan, 27 March 2006 - 05:01 AM.

LAUNCHER UPDATE!

With this version, we now fully support every known exe of Vice City. Also since Hammer recoded (almost?) the entire thing, replays now work! And Y_Less's debug switch has been added to the official version. There may be more, but Hammer will have to let you know what the details are.

Download the launcher update here.

This could use extensive testing. So please use this right away and report anything out of the ordinary.

EDIT by Ben:

There is a potential problem with the audio paths in this download. Go to Show Config, click Advanced, and go to the Audio tab. In the bottom right-hand corner, click Verify Paths. There will most likely be 2 errors:
QUOTE
AUDIOLC\POLICE.MP3 is not found

and
QUOTE
AUDIOLC\MISCOM.MP3 is not found

To fix these, simply replace the MP3 with WAV in the path box (if you have GTA3 audio), or click Restore (if you don't have GTA3 audio).

I think this is a simple ini file fix though, so Hammer should be able to release an update to it soon icon14.gif .
Fixed in the download link .

Also, note that the replay feature might not work in debug mode (but it definitely works in normal game mode). Before doing any testing, might I recommend getting the latest version of the code - DBUG.SCM (7th or 8th March, 2006) and MAIN.SCM (13th or 14th March 2006), depending on where you live wink.gif .

To use the debug scm, go to Show Config -> Advanced ->Debug, and tick the "Use Debug Scm".

Ben
  • Ben

    Retired

  • Members
  • Joined: 12 May 2005

#47

Posted 27 March 2006 - 01:41 AM

Excellent work Hammer. Just downloaded it - I took the day off school to study, but I might get some time this arvo to try it out. I'll update the checklist with this as well. Great work - I bet those stunters will be happy now that the replay works smile.gif . And you remembered to change the heli height tounge2.gif ! You're the best icon14.gif !

Ben
  • Ben

    Retired

  • Members
  • Joined: 12 May 2005

#48

Posted 27 March 2006 - 02:38 AM

PROBLEM!

Breathe easy, it's only a minor one tounge.gif ! Just installed the new launcher (extracted the rar file onto my LC directory) and for some reason, I opened up the show config (just to see what was different). And, I clicked Verify Paths for the audio, and got 2 errors.

The first was AUDIOLC\POLICE.MP3, which doesn't exist - it should be AUDIOLC\POLICE.WAV

And the second was AUDIOLC\MISCOM.MP3, which should also be AUDIOLC\MISCOM.WAV

I've edited the first post and Craig's (the one with the update) to indicate this, so hopefully people shouldn't have any problems. I'm just going to go and do some minor testing in-game. Anything else and I'll post about it smile.gif .

Also, I have a question - could we please get some sort of detailed instructions on how to get the debug option working? Doesn't really worry me as I'll just use the old way of manually replacing the scm, but some people might be curious. Be sure to update the first post and Craig's post with any instructions though wink.gif .

Hammer83
  • Hammer83

    Hustler

  • Members
  • Joined: 11 Jan 2003

#49

Posted 27 March 2006 - 03:05 AM

Either use -debug command line switch (one-time solution) or check "Use Debug Scm" on Debug page in launcher config (permanent)

Ben
  • Ben

    Retired

  • Members
  • Joined: 12 May 2005

#50

Posted 27 March 2006 - 03:17 AM

Thanks Hammer.

Another problem of sorts - replay doesn't work in debug mode (doing it the manual way). Not a biggie, and I don't really see the need to fix it. I'll update the first post and Craig's just so people know. It does work on a normal scm though, and I don't know about the debug tick option (haven't tested that yet). I'd suggest getting the latest version of the code before doing any testing though - DBUG.scm (8/3/06 or 3/8/06) and MAIN.scm (14/3/06 or 3/14/06).

Apart from that, everything looks good icon14.gif .

What's with the vcversion.dll file - what does it do? Is it for debug outputs so that it provides information on what version of VC people are using (just a wild guess tounge.gif !)?

Craig Kostelecky
  • Craig Kostelecky

    GTA:LC Team Leader

  • The Connection
  • Joined: 28 Jan 2004

#51

Posted 27 March 2006 - 04:20 AM

Ini file updated in the download. icon14.gif Thanks Ben.

Ben
  • Ben

    Retired

  • Members
  • Joined: 12 May 2005

#52

Posted 27 March 2006 - 05:02 AM

No worries wink.gif . I've just updated those 2 posts though to reflect this (in case people are too lazy to look).

Konstantinos
  • Konstantinos

    Just passing by

  • Members
  • Joined: 29 Jul 2005

#53

Posted 27 March 2006 - 02:30 PM

Heh. There goes my resolution to take a break from LC smile.gif
Anyway... two things to report about the new launcher. Firstly, if you launch the game from the config, it won't react on a change of the debug status. You'll have to exit config and then run the game. Secondly, replay only works sporadically. Still an improvement. icon14.gif

SteaVor
  • SteaVor

    Professional investor

  • Members
  • Joined: 17 Dec 2005
  • None

#54

Posted 29 March 2006 - 06:44 AM

QUOTE (benisablink182fan @ Mar 27 2006, 04:17)
What's with the vcversion.dll file - what does it do?  Is it for debug outputs so that it provides information on what version of VC people are using (just a wild guess tounge.gif !)?

It stores the offsets that differ in different versions of gta-vc.exe(1.00/1.1/Australian/German) I suppose.

Ben
  • Ben

    Retired

  • Members
  • Joined: 12 May 2005

#55

Posted 29 March 2006 - 07:36 AM

Ahh, ok. Makes sense I spose smile.gif .

@Hammer - I sent Craig an update of the american.gxt file earlier, where I removed some of the stats values that only apply to VC (like property budget, fashion budget, stores robbed, distance travelled in golf cart, etc.), but I have a problem in that only the names have been removed from the stats page (eg - so instead of saying "Distance travelled in golf cart 0.00", it now says "<blank space> 0.00". I'm thinking that some sort of EXE hack should be able to get around this - any thoughts?

If you want a copy of the file to test out in-game, just PM me smile.gif .

Hammer83
  • Hammer83

    Hustler

  • Members
  • Joined: 11 Jan 2003

#56

Posted 31 March 2006 - 02:15 AM

QUOTE (SteaVor @ Mar 29 2006, 01:44)
QUOTE (benisablink182fan @ Mar 27 2006, 04:17)
What's with the vcversion.dll file - what does it do?  Is it for debug outputs so that it provides information on what version of VC people are using (just a wild guess tounge.gif !)?

It stores the offsets that differ in different versions of gta-vc.exe(1.00/1.1/Australian/German) I suppose.

Yes, that's right. In fact i think it might be useful to other people as well who want to make it simple to write memory 'hacks' for Vice City. Just supply the offset to 1.0 US and it will convert it to the target version. I'll upload the updated source to the launcher once I sort out the hosting issues. If anyone wants to try it out before that, PM me.

benisablink182fan, I would assume it is possible to remove those lines. I even have suspicion where to find it and how much effort it will involve. If I get to work on LC this weekend, I'll see if it is easy or not.

Ben
  • Ben

    Retired

  • Members
  • Joined: 12 May 2005

#57

Posted 13 April 2006 - 09:31 AM

Hammer, after refining the gxt, I've added the stats values back in seeing as you can disable them completely through the exe - if you want the most up-to-date gxt, you can grab it here .

However, as I had to re-write several strings, I should be able to just tell you which to disable (if it's that easy). The one's that aren't used in LC are:
  1. DISTGOL
  2. DISTGOM
  3. PROPOWN
  4. STFT_04, 05, 06, 07, 08, 09, 10, 11, 12, 13, 14, 15, 16
  5. STFT_21, 22, 23
  6. STPR_1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15
  7. ST_BRK
  8. ST_FASH
  9. ST_ICEC
  10. ST_LOAN
  11. ST_MOVI
  12. ST_PHOT
  13. ST_PROP
  14. ST_STOR
  15. ST_WEAP
  16. TOP_SHO
Not all of these appear by default - 1, 2, 3, 8, 13, 14, and 15 definitely do. As for the STFT's, I'm not sure - I don't think so (I think they're all the best times for car races, rc races, etc.). And the STPR's are the property names for the stats, which don't appear by default.

1 and 2 are golf cart distances
3 are all race times
4 - more race times
5 - property names in stats
6 - bloodring kills
7 - "ice cream" sold
8 - visits from loan sharks
9 - movie stunts
10 - photos taken
11 - property budget
12 - stores knocked off
13 - weapons budget
14 - top shooting range score

Anything else you need to know, just PM me smile.gif .

Ben
  • Ben

    Retired

  • Members
  • Joined: 12 May 2005

#58

Posted 21 April 2006 - 06:39 AM

The gxt in that post (^) is now the final. All other gxts so far can be found there too icon14.gif .

Hammer, this is something to look into later when you've got the time - I'm just posting it now so I don't forget smile.gif .

You mentioned a while back that you had looked in the EXE and not found a way to change the weapons slots. There's been a few developments since then, so perhaps you might like to take another look. Here (DexX's post) is a link I found in the Weapons topic (thanks space wink.gif ) which might be of some use.

There may also be that issue with the shotgun and the police car that needs to be fixed at some stage as well - I'm waiting for feedback on that though.

Cheers smile.gif .

Konstantinos
  • Konstantinos

    Just passing by

  • Members
  • Joined: 29 Jul 2005

#59

Posted 21 April 2006 - 06:59 PM

@ben: I remember that both the squad cars and the criminals on 'Vigilante' now have the proper, GTA3 shotgun (firing 5 pellets). I didn't mention it in my bug report as it wasn't on the list.

Ben
  • Ben

    Retired

  • Members
  • Joined: 12 May 2005

#60

Posted 22 April 2006 - 02:17 AM

Cheers wink.gif .




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users