Vice City: Multiplayer

Server Development => Scripting and Server Management => Topic started by: J. Rockford on December 1st, 2019, 10:33 PM

Title: Compatibility of LU Scripts [roottable]
Post by: J. Rockford on December 1st, 2019, 10:33 PM
I've noticed that Liberty Unleashed Scripting and VCMP is about the same. So I'm trying to write one universal script that can run both. Wouldn't be hard. Also change some root table names to make each more compatible to run the same line of code versus getting the
Code: [Select]
MultiPlayer
variable.

In Liberty Unleashed I can find what are keyworded as "HashTable", Really unique, shouldn't find that anywhere else but Liberty Unleashed. The VCMP wiki is down and I need to access it to see what is unique that I could find in the root table to determine what script needs to be handled [VCMP : LU].

Code: [Select]
local MultiPlayer = "GTA"

try {
   
    // HashTables can be found
    if ("HashTable" in getroottable()) {
      print("Liberty Unleashed");
      MultiPlayer = "Liberty Unleashed";
    }
   
// VCMP here
 }
 catch (e) {
   print("Fucked");
 }
   
//----------------------------------------------
I need a vcmp detect so I can use the same scrip in GTA Connected as well.
 :)
Title: Re: Compatibility of LU Scripts [roottable]
Post by: rww on December 2nd, 2019, 12:20 AM
It's for VC-MP 0.4 hash functions, but idk it works on lasted build 04rel006

https://forum.vc-mp.org/?topic=206.0

Small offtopic:
I remember that @Stoku do a basemode script in one folder for vcmp and lu - the same folder with script can run on vcmp and lu. (But it isn't relased I think).
Title: Re: Compatibility of LU Scripts [roottable]
Post by: J. Rockford on December 2nd, 2019, 12:39 AM
Interesting! I will be eventually running the same method from my website. But all three will be launched.

Liberty Unleashed
VCMP
GTA Connected
SAMP at some point

in the same sequence, It'll have to be "Scripts/" as LU hardcoded that method". Server file, client file. That's it. Just three folders "Server/Scripts/Main/". everything else just gets packaged together and configured.
Title: Re: Compatibility of LU Scripts [roottable]
Post by: J. Rockford on December 3rd, 2019, 01:18 AM
@rwwpl. I'm not able to use that method as the plugin is required. I have to yield the script from getting that far. I wish the wiki was available.
Title: Re: Compatibility of LU Scripts [roottable]
Post by: Sebastian on December 3rd, 2019, 12:26 PM
Quote from J. Rockford on December 3rd, 2019, 01:18 AM
@rwwpl. I'm not able to use that method as the plugin is required. I have to yield the script from getting that far. I wish the wiki was available.
It was running last week I checked ... I don't know what's going on.
Until then, maybe you can use this:
https://web.archive.org/web/20191028155636/http://wiki.vc-mp.org/