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.


  Show Posts
Pages: [1] 2 3 ... 17
1  Scripting / Script Snippets / Write invalid commands on: October 13, 2017, 11:13:11 pm
So I created this a long time ago for fun. You must make sure you return all of your commands true of course or return 1;, I'm assuming you know the setup of proper commands...

I wasn't going to release it, But when I noticed there are commands that even I wish I had, And they were getting written I knew I should release it lol.


The objective of this script is to help you help the LU community, Maybe you have spawncar cmds, but there typing only 'v', or maybe they want a 'heal' command as well 'armour'. I seriously didn't know how useful this was going to be. And I hope it helps you to ;)

I used hashes as I didn't think much of it when I wrote it... I haven't even touched it since until attempting to modify it for a release

My Hashing file has it's own directory, Make sure to modify it!

The hashing system

Code: [Select]
/*
Hashes are only used for simple stuff.
In this case writing invalid commands to better our system in time.
*/
const HASH_TABLE_LOCATION = "Hashing/Hashes/";

function onScriptLoad()
{
LoadHashes();

print("The hash tables have been loaded!");
}

function onScriptUnload()
{
SaveHashes();
}
function CreateHashes()
{
hsh_Cmds <- HashTable("CMD");
}

function SaveHashes()
{
// This is where we will be saving the hash files
hsh_Cmds.Save("Scripts/" + HASH_TABLE_LOCATION + "INVALID_COMMANDS.hsh" );
}

function LoadHashes()
{
// This is where we are going to be loading the hash files
// First we need to create them
CreateHashes();

// And then load them
hsh_Cmds.Load("Scripts/" + HASH_TABLE_LOCATION + "Hashing/Hashes/INVALID_COMMANDS.hsh" );
}

And Command usage, You should look into VBS on Commands if you need help with this.

Code: [Select]
/* System Commands */
function onPlayerCommand( pPlayer, szCommand, szParams )
{
if (DEATH_MATCH_COMMANDER( pPlayer, szCommand, szParams )) return true;

if (ADMIN_AUTHORITY_COMMANDER( pPlayer, szCommand, szParams )) return true;

MessagePlayer("The command /"+szCommand+" does not exist", pPlayer, 255, 0, 0);

Write_Invalid_Command( szCommand );

return 1;
}

function Write_Invalid_Command( szCommand )
{
local Invalid_Cmd = hsh_Cmds.Get( "[COMMAND] " + szCommand );

if ( !Invalid_Cmd ) hsh_Cmds.Add( "[COMMAND] " + szCommand, 1 );
else
{
hsh_Cmds.Inc( "[COMMAND] " + szCommand, 1 )
}

SaveHashes();
}

I'm assuming you know how to code with releasing this..

If you are stuck with it feel free to ask me for help!
2  Scripting / Script Snippets / Re: Stats Script for Newbie! on: October 13, 2017, 02:03:27 am
:D You should make a cool gui for all of this, Default console client box only shows like 11 or less lines.

This would help with a nice template

http://forum.liberty-unleashed.co.uk/index.php/topic,2108.0.html 
looks like this
3  Liberty Unleashed / Support / Re: Why masterlist dies? on: August 07, 2017, 12:33:57 pm
Sometimes, I deal with it.

I typically just say F it and use the history tab until the masterlist starts working right again
4  Liberty Unleashed / Suggestions / Re: Window mode suggestion on: August 07, 2017, 05:10:57 am
Yeah it was :), I just personally think that LU should include what I was talking about since it is using it's own windower version.

Just saying, Trying to keep windows as clean as possible. I could basically do this myself but I prefer not to...
5  Liberty Unleashed / Suggestions / Re: Window mode suggestion on: August 07, 2017, 04:01:46 am
Window mode works very well with script debugging, Open view to Notifications that wont see during gameplay, Server monitoring player count while in game. Checking on the forum while in game reading the chat.

This seriously goes on and on..

I personally cant stand the game taking up my entire screen, If I wanted that I would just pull the console out..
6  Liberty Unleashed / Suggestions / Window mode suggestion on: August 07, 2017, 01:25:42 am
So, I'm not sure if it would look right.

But if your game window is set for like '1200 x null', Dunno but and the window takes up the entire screen it would be nice to be capable of manually altering this through the LU window mode.

I'm sure pixels might look funny, Maybe..

But there are other windowers out there that override GTA III's default window mode. 

I know it would be possible, I could see the LU client browser having a force window size selection/Saving.
7  Off Topic / General Chat / Re: Hi there guys on: June 29, 2017, 04:17:08 am
You could share that code in #Scripting on the Discord so more of use can help you with it :)
8  Off Topic / General Chat / Re: Hi there guys on: June 28, 2017, 01:29:00 am
Nice to meet you and welcome to the [LU] Forums.

The site is a little inactive compared to the LU Discord.

You can find the discord with this link https://discord.gg/VPAtav2



Feel free to drop in. We will be more than happy to help and assist you with anything needed :).
And who knows, With your knowledge you could help others with stuff  ;)
9  Liberty Unleashed / Support / Re: My lu client doesnt launch gta. on: March 23, 2017, 08:21:09 pm
Last check would be to see if you happened to copy and paste the lu client files to your gta3 folder?

My only easy suggestion would be to uninstall LU and reinstall it.

Also what operating system do you have? Windows XP is not supported, And anything else bellow windows 10 requires a lot of updates to the os
10  Liberty Unleashed / Support / Re: My lu client doesnt launch gta. on: March 21, 2017, 12:44:32 pm
Did you use the official download?

http://liberty-unleashed.co.uk/Downloads/lu-0.1-installer.zip



Is your gta3 modded?



And it does launch story mode just fine?



Do you get any errors like

Quote
Can not locate lu.dll




If it just doesn't do nothing at all I would like to request a screenshot of your gta3 game folder.

I will do what I can to help you :)
11  Scripting / Script Help / Using 'loops' in a Class on: February 21, 2017, 03:30:51 am
I wanted to ask a general programing question that has had me puzzled still to this day, Even while studying C++.

Is it bad to run a while loop, Or any loop for that mater anywhere within a class?

I am sure that 'maybe' it depends on the programing language.


I find using a loop inside a class to be highly useful in general, I do not see it being a bad thing what so ever, But I could see where it could. Just curious honestly  :)
12  Scripting / Script Help / Re: How do i add cmds to a server on: February 19, 2017, 03:01:10 am
I coded this out of randomness. :P
A cmd is noting but a function that you can call at anytime, but typically LU server owners use it for players or admin usage.

Banning players, Spawning cars etc etc..

I do not know your previous knowledge of any programing, So I am sorry if you are clueless to this
Code: [Select]
class Char_Class
{
A = 0;
B = 0;
C = 0;
}; //Just a random class

function onPlayerCommand(player, cmd, text)
{
    if ( cmd == "cmd1")
    {
    Random_Char <- [ "A", "B", "C" ];
    Random_Char_Class_ID <- array(2); //Starts from zero not 1
count <- 0;

while(count !=3)
{
print( "The character of " + Random_Char[count] + " class ID: \n" + count );

if ( count == 3) // Last check
{
        print( Random_Char[count] ); // Shows the listed Char
Random_Char_Class_ID[count] = Char_Class(); //Sets the class according to the ID of the character
return true;
}
count++;
}
return true;
    }
   
    return true;
}
Wasn't trying to be fancy, Haven't touched squirrel in some time...
13  Liberty Unleashed / Suggestions / Re: Passagers can shoot inside the car on: February 02, 2017, 12:35:06 am
I am not really sure how the developers would go about it but people in VCMP have talked about this as well. So if they find out a way the LU developers can hear about it hopefully :)



Now I am only currently learning C++ so I am a noob  :P

But I would assume, This :

My only thought would be to see if there is a pointer/memory address that the developers could code to. This would be the address that allows the driver to aim left or right and then shoot.

But their could be many bugs to doing this. From the driver possibly dyeing and any passenger getting set to the driver "Then if their is more than one passenger then they all die", You never know; I am just saying their could be some nasty bugs.

And to find that address yikes...

Thats like trying to find out if their is a memory address in Cheat Engine when a Character shoots at the windshield.

My only suggestion to any of this would have to be the fact that since their is already files added to the GTA III Directory for LU just add some more to make modifying the game easier :)

But still I am noobish with learning C++ with how it works and it's usage, their might be a better method all in general.

It's just a thought and output for a possible how to for the devs :)
14  Liberty Unleashed / Liberty Unleashed Chat / Re: Wine Now supports 0.1.0.17! on: January 28, 2017, 11:48:44 pm
Sorry :)

I have always preferred to call it by the last decimal digits.

I will change it over to '0.1.0.17'.

It's a big success for LU :)
15  Liberty Unleashed / Liberty Unleashed Chat / Re: scam by Vrocker on: January 14, 2017, 02:11:39 pm
I wish their were a way of a automatic setup.

^That would be very nice and easier for Vrocker.

Sometimes I get refunded automatically if I get no response, Still awaiting my response for my simple starter server.
Pages: [1] 2 3 ... 17
© Liberty Unleashed Team.