Vice City: Multiplayer

Server Development => Scripting and Server Management => Topic started by: MRSK143 on May 20, 2021, 10:23 AM

Title: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on May 20, 2021, 10:23 AM
I Need Help From You @Yyg Plz help me to add weapons in your pubg dm server :'( plz help me
Title: Re: Help Me
Post by: Yyg on May 20, 2021, 11:11 AM
Glad someone remembered the Pubg server, in fact you only need to add Custom Weapon according to the VCMP rules

You can /exec FindPlayer(playerID).SetWeapon(weaponID, 999); to see if the MOD has been added successfully (at which point you should get the MOD weapon)

If you want add new custom weapon, Maybe you need add to the "pickup weapon", you might need to create some new pickups, as well as write the frequency of new weapon IDs, slots, and random ammo (many of which should be found here at "Statics. nut").

About how to fill the modified armory, I can't remember it too long, please, by checking the script, you probably need to do the following:
Weapon ID change: store\script\main.nut(g_WEAPONPOOLS)
Remember to add a similar "Item Image" for store\sprites\GameMenu\CMenu_Backpack\WeaponItems (this may require you to modify the Image yourself)

Since this server has always been an experimental project, it is best to keep the number of items consistent, i.e. try not to exceed the current total number of weapons, but to replace undesirable weapons

My English is not good, you can try it according to the general idea.
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on May 20, 2021, 11:55 AM
Quote from: Yyg on May 20, 2021, 11:11 AMGlad someone remembered the Pubg server, in fact you only need to add Custom Weapon according to the VCMP rules

You can /exec FindPlayer(playerID).SetWeapon(weaponID, 999); to see if the MOD has been added successfully (at which point you should get the MOD weapon)

If you want add new custom weapon, Maybe you need add to the "pickup weapon", you might need to create some new pickups, as well as write the frequency of new weapon IDs, slots, and random ammo (many of which should be found here at "Statics. nut").

About how to fill the modified armory, I can't remember it too long, please, by checking the script, you probably need to do the following:
Weapon ID change: store\script\main.nut(g_WEAPONPOOLS)
Remember to add a similar "Item Image" for store\sprites\GameMenu\CMenu_Backpack\WeaponItems (this may require you to modify the Image yourself)

Since this server has always been an experimental project, it is best to keep the number of items consistent, i.e. try not to exceed the current total number of weapons, but to replace undesirable weapons

My English is not good, you can try it according to the general idea.

dude i changed that but it stuck on there

https://ibb.co/6DJ8K7n

now how can i fix that?
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: Yyg on May 21, 2021, 02:23 AM
Quote from: MRSK143 on May 20, 2021, 11:55 AMdude i changed that but it stuck on there

https://ibb.co/6DJ8K7n

now how can i fix that?
If you do not find any errors in the server console, it means that there is no problem with your server script. It is likely that there are some errors in the client script.

You can see the error log in %appdata%\VCMP\04beta\debuglog.txt, it will tell which scripts found what kind of errors.
Maybe this file contains content by default, I suggest you clear this file first, and then enter the game again, it will write the latest error report

If you can't read well, you can send debug_log to me and I will try my best to help you view it :D
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on May 21, 2021, 04:56 AM
Quote from: Yyg on May 21, 2021, 02:23 AM
Quote from: MRSK143 on May 20, 2021, 11:55 AMdude i changed that but it stuck on there

https://ibb.co/6DJ8K7n

now how can i fix that?
If you do not find any errors in the server console, it means that there is no problem with your server script. It is likely that there are some errors in the client script.

You can see the error log in %appdata%\VCMP\04beta\debuglog.txt, it will tell which scripts found what kind of errors.
Maybe this file contains content by default, I suggest you clear this file first, and then enter the game again, it will write the latest error report

If you can't read well, you can send debug_log to me and I will try my best to help you view it :D

Dude If YOu Had Anything Like Discord, Facebook, Instagram etc if you had any of this then plz tell me
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: Sebastian on May 21, 2021, 07:32 AM
Quote from: MRSK143 on May 21, 2021, 04:56 AMDude If YOu Had Anything Like Discord, Facebook, Instagram etc if you had any of this then plz tell me

Did you do what he asked you to do ?
If yes, then post here the error message, or the whole content if you don't know what's an error.
@Yyg is already trying to help you. Be cool and answer properly, don't try to spam him with dumb questions and requests.
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on May 22, 2021, 03:12 AM
Quote from: Yyg on May 21, 2021, 02:23 AM
Quote from: MRSK143 on May 20, 2021, 11:55 AMdude i changed that but it stuck on there

https://ibb.co/6DJ8K7n

now how can i fix that?
If you do not find any errors in the server console, it means that there is no problem with your server script. It is likely that there are some errors in the client script.

You can see the error log in %appdata%\VCMP\04beta\debuglog.txt, it will tell which scripts found what kind of errors.
Maybe this file contains content by default, I suggest you clear this file first, and then enter the game again, it will write the latest error report

If you can't read well, you can send debug_log to me and I will try my best to help you view it :D

Bro I Cant Fix The Errors Of and here the debulog file

https://drive.google.com/file/d/1FCX-hjgRBohQlgm8eX6XSvx5dC9ceICj/view?usp=sharing

now plz fix this
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: Yyg on May 22, 2021, 01:40 PM
Quote from: MRSK143 on May 22, 2021, 03:12 AM
Quote from: Yyg on May 21, 2021, 02:23 AM
Quote from: MRSK143 on May 20, 2021, 11:55 AMdude i changed that but it stuck on there

https://ibb.co/6DJ8K7n

now how can i fix that?
If you do not find any errors in the server console, it means that there is no problem with your server script. It is likely that there are some errors in the client script.

You can see the error log in %appdata%\VCMP\04beta\debuglog.txt, it will tell which scripts found what kind of errors.
Maybe this file contains content by default, I suggest you clear this file first, and then enter the game again, it will write the latest error report

If you can't read well, you can send debug_log to me and I will try my best to help you view it :D

Bro I Cant Fix The Errors Of and here the debulog file

https://drive.google.com/file/d/1FCX-hjgRBohQlgm8eX6XSvx5dC9ceICj/view?usp=sharing

now plz fix this
If you read it carefully, it will tell you that the first character of the first line of the store/script/main.nut script is wrong, but based on experience this may be due to formatting issues, you can try checking the main.nut script
I don't use the computer very often, if there are more problems you can try to analyze the debug_log.txt and try how to handle it, good luck!
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on May 23, 2021, 02:53 AM
Quote from: Yyg on May 22, 2021, 01:40 PM
Quote from: MRSK143 on May 22, 2021, 03:12 AM
Quote from: Yyg on May 21, 2021, 02:23 AM
Quote from: MRSK143 on May 20, 2021, 11:55 AMdude i changed that but it stuck on there

https://ibb.co/6DJ8K7n

now how can i fix that?
If you do not find any errors in the server console, it means that there is no problem with your server script. It is likely that there are some errors in the client script.

You can see the error log in %appdata%\VCMP\04beta\debuglog.txt, it will tell which scripts found what kind of errors.
Maybe this file contains content by default, I suggest you clear this file first, and then enter the game again, it will write the latest error report

If you can't read well, you can send debug_log to me and I will try my best to help you view it :D

Bro I Cant Fix The Errors Of and here the debulog file

https://drive.google.com/file/d/1FCX-hjgRBohQlgm8eX6XSvx5dC9ceICj/view?usp=sharing

now plz fix this
If you read it carefully, it will tell you that the first character of the first line of the store/script/main.nut script is wrong, but based on experience this may be due to formatting issues, you can try checking the main.nut script
I don't use the computer very often, if there are more problems you can try to analyze the debug_log.txt and try how to handle it, good luck!

Bro I See Everything I cant see any thing that is not normal and plz try to help me i cant fix that
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on May 24, 2021, 01:20 AM
Quote from: Yyg on May 22, 2021, 01:40 PM
Quote from: MRSK143 on May 22, 2021, 03:12 AM
Quote from: Yyg on May 21, 2021, 02:23 AM
Quote from: MRSK143 on May 20, 2021, 11:55 AMdude i changed that but it stuck on there

https://ibb.co/6DJ8K7n

now how can i fix that?
If you do not find any errors in the server console, it means that there is no problem with your server script. It is likely that there are some errors in the client script.

You can see the error log in %appdata%\VCMP\04beta\debuglog.txt, it will tell which scripts found what kind of errors.
Maybe this file contains content by default, I suggest you clear this file first, and then enter the game again, it will write the latest error report

If you can't read well, you can send debug_log to me and I will try my best to help you view it :D

Bro I Cant Fix The Errors Of and here the debulog file

https://drive.google.com/file/d/1FCX-hjgRBohQlgm8eX6XSvx5dC9ceICj/view?usp=sharing

now plz fix this
If you read it carefully, it will tell you that the first character of the first line of the store/script/main.nut script is wrong, but based on experience this may be due to formatting issues, you can try checking the main.nut script
I don't use the computer very often, if there are more problems you can try to analyze the debug_log.txt and try how to handle it, good luck!

I Cant Find Any Wrong Thing Bro And You Can GIve me a tutorial for adding the weapon plz help me!
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: Yyg on May 24, 2021, 06:08 AM
About how to fill the modified armory, I can't remember it too long, please, by checking the script, you probably need to do the following:
Weapon ID change: store\script\main.nut(g_WEAPONPOOLS)
Remember to add a similar "Item Image" for store\sprites\GameMenu\CMenu_Backpack\WeaponItems (this may require you to modify the Image yourself)

You can analyze and refer to the content of this topic. I suggest you try to start the test with the default weapon (0~33) first. I think the main code is in store\script\main.nut(g_WEAPONPOOLS array)
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on May 24, 2021, 10:13 AM
Quote from: Yyg on May 24, 2021, 06:08 AMAbout how to fill the modified armory, I can't remember it too long, please, by checking the script, you probably need to do the following:
Weapon ID change: store\script\main.nut(g_WEAPONPOOLS)
Remember to add a similar "Item Image" for store\sprites\GameMenu\CMenu_Backpack\WeaponItems (this may require you to modify the Image yourself)

You can analyze and refer to the content of this topic. I suggest you try to start the test with the default weapon (0~33) first. I think the main code is in store\script\main.nut(g_WEAPONPOOLS array)

i can make that image but i also tried tooo many things and also what you said to try but still giving error that i send you picture what should i do now?
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on May 25, 2021, 03:22 AM
Quote from: MRSK143 on May 24, 2021, 10:13 AM
Quote from: Yyg on May 24, 2021, 06:08 AMAbout how to fill the modified armory, I can't remember it too long, please, by checking the script, you probably need to do the following:
Weapon ID change: store\script\main.nut(g_WEAPONPOOLS)
Remember to add a similar "Item Image" for store\sprites\GameMenu\CMenu_Backpack\WeaponItems (this may require you to modify the Image yourself)

You can analyze and refer to the content of this topic. I suggest you try to start the test with the default weapon (0~33) first. I think the main code is in store\script\main.nut(g_WEAPONPOOLS array)

i can make that image but i also tried tooo many things and also what you said to try but still giving error that i send you picture what should i do now?

Bro You Can Add The Weapon Just Believe Me And Believe YourSelf Also You Can Add The WEapon Bro only you are the last one that can help me here the weapon link i want to add
 https://drive.google.com/file/d/1WdmVDJrqu5YkV-GOzGybBe_ZzfyMIJJn/view?usp=sharing
bro and make a video on it how can i add it plz
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: Yyg on May 26, 2021, 01:58 AM
I tested the weapon modification on the local server, and I'll show you how I did it:

For example, I want to add a sniper rifle with ID=29 (which is not available by default in the current server version).
1. Open store\script\main.nut
2. Modify the g_WEAPONPOOLS array (keep the array count, replacing only the ID), e.g. 28 to 29
3. Open the store\sprites\Gamemenu\CMenu_Backpack\WeaponItems folder, add an image with the name 29.png

If there is no problem, then the Weapon should be added. Custom Weapon also operates the same way, but the ID may be more than 100+ (VCMP feature).
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on May 26, 2021, 02:42 AM
Quote from: Yyg on May 26, 2021, 01:58 AMI tested the weapon modification on the local server, and I'll show you how I did it:

For example, I want to add a sniper rifle with ID=29 (which is not available by default in the current server version).
1. Open store\script\main.nut
2. Modify the g_WEAPONPOOLS array (keep the array count, replacing only the ID), e.g. 28 to 29
3. Open the store\sprites\Gamemenu\CMenu_Backpack\WeaponItems folder, add an image with the name 29.png

If there is no problem, then the Weapon should be added. Custom Weapon also operates the same way, but the ID may be more than 100+ (VCMP feature).

If it is working right then why it is not working in my server bro its giving the same error bro plz help me
https://ibb.co/R6dhWnh
image link this the error that i am having when i modify gWEAPONSPOOL array
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on May 27, 2021, 03:24 AM
Quote from: Yyg on May 26, 2021, 01:58 AMI tested the weapon modification on the local server, and I'll show you how I did it:

For example, I want to add a sniper rifle with ID=29 (which is not available by default in the current server version).
1. Open store\script\main.nut
2. Modify the g_WEAPONPOOLS array (keep the array count, replacing only the ID), e.g. 28 to 29
3. Open the store\sprites\Gamemenu\CMenu_Backpack\WeaponItems folder, add an image with the name 29.png

If there is no problem, then the Weapon should be added. Custom Weapon also operates the same way, but the ID may be more than 100+ (VCMP feature).

at least you can try to add the weapon plz bro
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: Yyg on May 27, 2021, 03:45 AM
Please try to modify it according to what I said. I have tested it locally and found no problems.
It is recommended that you modify your weapon ID using the built-in weapon ID in VCMP and make sure the WeaponItems directory contains the weaponID.PNG
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on May 27, 2021, 10:57 AM
Quote from: Yyg on May 27, 2021, 03:45 AMPlease try to modify it according to what I said. I have tested it locally and found no problems.
It is recommended that you modify your weapon ID using the built-in weapon ID in VCMP and make sure the WeaponItems directory contains the weaponID.PNG

bro i already confirmed that bruh you should try in your server not in local server and bro when i added the weapon then i get same error but when i open debug.log and i see something weird they said "Main.nut File Is Wrong When I add The Weapon" wtf was that?
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on May 28, 2021, 07:29 AM
Quote from: Yyg on May 27, 2021, 03:45 AMPlease try to modify it according to what I said. I have tested it locally and found no problems.
It is recommended that you modify your weapon ID using the built-in weapon ID in VCMP and make sure the WeaponItems directory contains the weaponID.PNG

bruh plz to understand plz add the weapon and give me tutorial and add the weapon in your pubg dm server plz
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: Yyg on May 28, 2021, 07:49 AM
Quote from: MRSK143 on May 28, 2021, 07:29 AM
Quote from: Yyg on May 27, 2021, 03:45 AMPlease try to modify it according to what I said. I have tested it locally and found no problems.
It is recommended that you modify your weapon ID using the built-in weapon ID in VCMP and make sure the WeaponItems directory contains the weaponID.PNG

bruh plz to understand plz add the weapon and give me tutorial and add the weapon in your pubg dm server plz

After my testing, I think this topic has solved this problem, and maybe you still need to try some

For example, you can try changing the file store\script\main.nut, for example, changing g_WEAPONPOOLS to:

g_WEAPONPOOLS <- [7, 8, 10, 11, 12, 13 ,26 ,26, 26, 26, 26, 26, 26, 26]; //26 is M4A1

You will see a lot of M4A1 in the game menu. This is just an example. To change other weapons, just change the ID to the Weapon ID.
and make sure the store\sprites\GameMenu\CMenu_Backpack\WeaponItems directory contains the weaponID.PNG

It is worth noting that, perhaps, you should not add or remove any members of g_WEAPONPOOLS; please maintain their total number
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on May 28, 2021, 09:41 AM
Quote from: Yyg on May 28, 2021, 07:49 AM
Quote from: MRSK143 on May 28, 2021, 07:29 AM
Quote from: Yyg on May 27, 2021, 03:45 AMPlease try to modify it according to what I said. I have tested it locally and found no problems.
It is recommended that you modify your weapon ID using the built-in weapon ID in VCMP and make sure the WeaponItems directory contains the weaponID.PNG

bruh plz to understand plz add the weapon and give me tutorial and add the weapon in your pubg dm server plz

After my testing, I think this topic has solved this problem, and maybe you still need to try some

For example, you can try changing the file store\script\main.nut, for example, changing g_WEAPONPOOLS to:

g_WEAPONPOOLS <- [7, 8, 10, 11, 12, 13 ,26 ,26, 26, 26, 26, 26, 26, 26]; //26 is M4A1

You will see a lot of M4A1 in the game menu. This is just an example. To change other weapons, just change the ID to the Weapon ID.
and make sure the store\sprites\GameMenu\CMenu_Backpack\WeaponItems directory contains the weaponID.PNG

It is worth noting that, perhaps, you should not add or remove any members of g_WEAPONPOOLS; please maintain their total number

MSG: Main Script line = (1) column = (1) : error expression expected

Warning in CScripting::Initialise: Loading main script file failed with error message: expression expected.
Warning in CScripting::Initialise: Attempting manual closure load.
Error in CScripting::Initialise: Loading bytecode stream failed with error message: invalid stream.

bruh when i add your Weapon pool array then i got this error in debuglog.txt plz help me
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: Yyg on May 28, 2021, 10:55 AM
Quote from: MRSK143 on May 28, 2021, 09:41 AM
Quote from: Yyg on May 28, 2021, 07:49 AM
Quote from: MRSK143 on May 28, 2021, 07:29 AM
Quote from: Yyg on May 27, 2021, 03:45 AMPlease try to modify it according to what I said. I have tested it locally and found no problems.
It is recommended that you modify your weapon ID using the built-in weapon ID in VCMP and make sure the WeaponItems directory contains the weaponID.PNG

bruh plz to understand plz add the weapon and give me tutorial and add the weapon in your pubg dm server plz

After my testing, I think this topic has solved this problem, and maybe you still need to try some

For example, you can try changing the file store\script\main.nut, for example, changing g_WEAPONPOOLS to:

g_WEAPONPOOLS <- [7, 8, 10, 11, 12, 13 ,26 ,26, 26, 26, 26, 26, 26, 26]; //26 is M4A1

You will see a lot of M4A1 in the game menu. This is just an example. To change other weapons, just change the ID to the Weapon ID.
and make sure the store\sprites\GameMenu\CMenu_Backpack\WeaponItems directory contains the weaponID.PNG

It is worth noting that, perhaps, you should not add or remove any members of g_WEAPONPOOLS; please maintain their total number

MSG: Main Script line = (1) column = (1) : error expression expected

Warning in CScripting::Initialise: Loading main script file failed with error message: expression expected.
Warning in CScripting::Initialise: Attempting manual closure load.
Error in CScripting::Initialise: Loading bytecode stream failed with error message: invalid stream.

bruh when i add your Weapon pool array then i got this error in debuglog.txt plz help me
I copied the WeaponPool code directly from my script. This should not be a problem. I may not know how to help you, I suggest you download a new server and try the method changes in the topic
This is really weird, but if you just changed an ID to happen this problem, maybe you can also check the encoding format (and text encoding) and programming specification
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: Yyg on May 28, 2021, 11:01 AM
This is my main.nut file and it runs without any problems with me

(https://z3.ax1x.com/2021/05/28/2kPIN6.png)

[spoiler][noae]g_MAXPLAYER <- 64;

g_MAPPOINTCOUNT <- 5
g_ANIMMENUCOUNT <- 13;
//g_WEAPONPOOLS <- [7, 8, 10, 11, 12, 13 ,15 ,18, 19, 21, 22, 25, 26, 28]; //31
g_WEAPONPOOLS <- [26, 26, 26, 11, 12, 26,26 ,26, 19, 26, 22, 25, 26, 28]; //31
g_EQUIPPOOLS <- [0, 1, 2, 3, 4];

g_ZeroVector <- VectorScreen(0, 0);
g_FullColour <- Colour(255, 255, 255, 255);
g_ZeroColour <- Colour(0, 0, 0, 0);

g_MainColour_0 <- Colour(255, 164, 26, 235);
g_MainColour_1 <- Colour(0, 0, 0, 240);
g_MainColour_2 <- Colour(15, 15, 15, 220);

g_BackgroundSprite <- "Inside/Background.png";
g_AlphaSprite <- "Inside/ZeroAlpha.png";

Global <-
{
LocalPlayer = null
LocalPlayerUIDGroup = ""
LocalVehicle = null

IsPlayerSpawnJumping = false

IsLogined = false
GameAnnounceAwakeTime = 0
}

GlobalUI <-
{
BackgroundMask_0 = GUISprite("Inside/BackgroundMask_0.png", g_ZeroVector, g_ZeroColour)
ServerCopyright = GUISprite("Inside/Copyright.png", g_ZeroVector, g_FullColour)
GameAnnounce = GUISprite("Inside/ZeroAlpha.png", g_ZeroVector, Colour(255, 255, 255, 0))
HealthBackground = GUISprite(g_BackgroundSprite, g_ZeroVector, Colour(255, 0, 0, 0))
}

keyEnter <- KeyBind( 0x0D );
keyEsc <- KeyBind( 0x1B );
keySpace <- KeyBind( 0x20 );
keyOEM <- KeyBind( 0xC0 );
keyRMouse <- KeyBind( 0x02 );
m_KeyAltEnter <- KeyBind( 0x12, 0x0D );

include( "3dchat.nut" );
include( "windows_mem.nut" );
include( "scenemanager_mem.nut" );
include( "account_mem.nut" );
include( "client_mem.nut" );
include( "gamemenu_mem.nut" );
include( "smallmap_mem.nut" );
include( "dashboard_mem.nut" );

function Script::ScriptLoad(){
Global.LocalPlayer = World.FindLocalPlayer();

AwakeAndCheckGameWindows();
AwakeClientScript();

GlobalUI.ServerCopyright.SendToTop();
GUI.GameResize(GUI.GetScreenSize().X, GUI.GetScreenSize().Y);
}

function Script::ScriptProcess(){
WindowsClassProc();
SceneManagerProc();
AccountClassProc();
ChatBubbleProc();
ClientScriptProc();
VehicleDashboardProc();
}

function Server::ServerData(stream)
{
local StreamReadInt = stream.ReadInt(),
StreamReadString = stream.ReadString();

ClientServerData(StreamReadInt, StreamReadString);
}

function KeyBind::OnDown(key)
{
SceneManagerKeyDown(key);
}

function KeyBind::OnUp(key)
{

}

function GUI::GameResize(width, height){
UpdateGlobalUIResize();

UpdateWindowsClassResize();
UpdateDashboardClassResize();
UpdateSceneManagerResize();
UpdateAccountPanelResize();
UpdateClientClassResize();
UpdateRankingMenuUIsResize();
}

function GUI::ElementHoverOver(element)
{
AccountPanelElementHoverOver(element);
ClientClassElementHoverOver(element);
}

function GUI::ElementHoverOut(element)
{
AccountPanelElementHoverOut(element);
ClientClassElementHoverOut(element);
}

function GUI::ElementClick(element, mouseX, mouseY)
{
AccountPanelElementClick(element, mouseX, mouseY);
}

function GUI::ElementRelease(element, mouseX, mouseY)
{
ClientClassElementRelease(element, mouseX, mouseY);
}

function GUI::InputReturn(editbox)
{
AccountPanelInputReturn(editbox);
}

function GUI::WindowClose(window)
{
ClientClassWindowClose(window);
}

function GUI::CheckboxToggle(checkbox, checked)
{

}

function GUI::ScrollbarScroll(scrollbar, position, change)
{

}

function GUI::ElementDrag(element, mouseX, mouseY)
{

}

function UpdateGlobalUIResize(){
local width = GUI.GetScreenSize().X, height = GUI.GetScreenSize().Y;

GlobalUI.HealthBackground.Size = GUI.GetScreenSize();

GlobalUI.GameAnnounce.Size = VectorScreen(width * 0.3, height * 0.1);
GlobalUI.GameAnnounce.Pos = VectorScreen(width / 2 - (GlobalUI.GameAnnounce.Size.X / 2), height * 0.3);

if(GlobalUI.BackgroundMask_0) GlobalUI.BackgroundMask_0.Size = VectorScreen(width, height);
if(GlobalUI.ServerCopyright)
{
GlobalUI.ServerCopyright.Size = VectorScreen(width * 0.45, height * 0.06);
GlobalUI.ServerCopyright.Pos = VectorScreen(width * 0.545, height * 0.925);
}
}

function SendData(str, int)
{
local message = Stream();
message.WriteInt(int.tointeger());
message.WriteString(str);
Server.SendData(message);
}

function ShowScreenMask(){
GlobalUI.BackgroundMask_0.Alpha = 150;
}

function HideScreenMask(){
GlobalUI.BackgroundMask_0.Alpha = 0;
}

function ShowElement(element)
{
if(element == null) return;

element.RemoveFlags(GUI_FLAG_DISABLED);
element.AddFlags(GUI_FLAG_VISIBLE);
}

function HideElement(element)
{
if(element == null) return;

element.AddFlags(GUI_FLAG_DISABLED);
element.RemoveFlags(GUI_FLAG_VISIBLE);
}

function Distance( x1, y1, z1, x2, y2, z2 )
{
    return sqrt( (x1 - x2) * (x1 - x2) + (y1 - y2) * (y1 - y2) + (z1 - z2) * (z1 - z2) );
}

function Abs(a)
{
if(a < 0)
{
a = a * -1;
}

return a;
}

function Minus(a)
{
if(a > 0)
{
a = a * -1;
}

return a;
}

function Lerp( a, b, t )
{
return a+(b-a)*t;
}

function Clamp( value, min, max )
{
if(value < min) return min;
else if(value > max) return max;
else return value;
}

function Random(min=0, max=RAND_MAX)
{
local r = rand();
srand(System.GetTimestamp() * r);
return (r % ((max + 1) - min)) + min;
}

function NumberReturnZero(num, length){
return ( "0000000000" + num ).slice( -length ); 
}
[/noae][/spoiler]
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on May 28, 2021, 02:58 PM
Quote from: Yyg on May 28, 2021, 11:01 AMThis is my main.nut file and it runs without any problems with me

(https://z3.ax1x.com/2021/05/28/2kPIN6.png)

[spoiler][noae][noae][noae]g_MAXPLAYER <- 64;

g_MAPPOINTCOUNT <- 5
g_ANIMMENUCOUNT <- 13;
//g_WEAPONPOOLS <- [7, 8, 10, 11, 12, 13 ,15 ,18, 19, 21, 22, 25, 26, 28]; //31
g_WEAPONPOOLS <- [26, 26, 26, 11, 12, 26,26 ,26, 19, 26, 22, 25, 26, 28]; //31
g_EQUIPPOOLS <- [0, 1, 2, 3, 4];

g_ZeroVector <- VectorScreen(0, 0);
g_FullColour <- Colour(255, 255, 255, 255);
g_ZeroColour <- Colour(0, 0, 0, 0);

g_MainColour_0 <- Colour(255, 164, 26, 235);
g_MainColour_1 <- Colour(0, 0, 0, 240);
g_MainColour_2 <- Colour(15, 15, 15, 220);

g_BackgroundSprite <- "Inside/Background.png";
g_AlphaSprite <- "Inside/ZeroAlpha.png";

Global <-
{
LocalPlayer = null
LocalPlayerUIDGroup = ""
LocalVehicle = null

IsPlayerSpawnJumping = false

IsLogined = false
GameAnnounceAwakeTime = 0
}

GlobalUI <-
{
BackgroundMask_0 = GUISprite("Inside/BackgroundMask_0.png", g_ZeroVector, g_ZeroColour)
ServerCopyright = GUISprite("Inside/Copyright.png", g_ZeroVector, g_FullColour)
GameAnnounce = GUISprite("Inside/ZeroAlpha.png", g_ZeroVector, Colour(255, 255, 255, 0))
HealthBackground = GUISprite(g_BackgroundSprite, g_ZeroVector, Colour(255, 0, 0, 0))
}

keyEnter <- KeyBind( 0x0D );
keyEsc <- KeyBind( 0x1B );
keySpace <- KeyBind( 0x20 );
keyOEM <- KeyBind( 0xC0 );
keyRMouse <- KeyBind( 0x02 );
m_KeyAltEnter <- KeyBind( 0x12, 0x0D );

include( "3dchat.nut" );
include( "windows_mem.nut" );
include( "scenemanager_mem.nut" );
include( "account_mem.nut" );
include( "client_mem.nut" );
include( "gamemenu_mem.nut" );
include( "smallmap_mem.nut" );
include( "dashboard_mem.nut" );

function Script::ScriptLoad(){
Global.LocalPlayer = World.FindLocalPlayer();

AwakeAndCheckGameWindows();
AwakeClientScript();

GlobalUI.ServerCopyright.SendToTop();
GUI.GameResize(GUI.GetScreenSize().X, GUI.GetScreenSize().Y);
}

function Script::ScriptProcess(){
WindowsClassProc();
SceneManagerProc();
AccountClassProc();
ChatBubbleProc();
ClientScriptProc();
VehicleDashboardProc();
}

function Server::ServerData(stream)
{
local StreamReadInt = stream.ReadInt(),
StreamReadString = stream.ReadString();

ClientServerData(StreamReadInt, StreamReadString);
}

function KeyBind::OnDown(key)
{
SceneManagerKeyDown(key);
}

function KeyBind::OnUp(key)
{

}

function GUI::GameResize(width, height){
UpdateGlobalUIResize();

UpdateWindowsClassResize();
UpdateDashboardClassResize();
UpdateSceneManagerResize();
UpdateAccountPanelResize();
UpdateClientClassResize();
UpdateRankingMenuUIsResize();
}

function GUI::ElementHoverOver(element)
{
AccountPanelElementHoverOver(element);
ClientClassElementHoverOver(element);
}

function GUI::ElementHoverOut(element)
{
AccountPanelElementHoverOut(element);
ClientClassElementHoverOut(element);
}

function GUI::ElementClick(element, mouseX, mouseY)
{
AccountPanelElementClick(element, mouseX, mouseY);
}

function GUI::ElementRelease(element, mouseX, mouseY)
{
ClientClassElementRelease(element, mouseX, mouseY);
}

function GUI::InputReturn(editbox)
{
AccountPanelInputReturn(editbox);
}

function GUI::WindowClose(window)
{
ClientClassWindowClose(window);
}

function GUI::CheckboxToggle(checkbox, checked)
{

}

function GUI::ScrollbarScroll(scrollbar, position, change)
{

}

function GUI::ElementDrag(element, mouseX, mouseY)
{

}

function UpdateGlobalUIResize(){
local width = GUI.GetScreenSize().X, height = GUI.GetScreenSize().Y;

GlobalUI.HealthBackground.Size = GUI.GetScreenSize();

GlobalUI.GameAnnounce.Size = VectorScreen(width * 0.3, height * 0.1);
GlobalUI.GameAnnounce.Pos = VectorScreen(width / 2 - (GlobalUI.GameAnnounce.Size.X / 2), height * 0.3);

if(GlobalUI.BackgroundMask_0) GlobalUI.BackgroundMask_0.Size = VectorScreen(width, height);
if(GlobalUI.ServerCopyright)
{
GlobalUI.ServerCopyright.Size = VectorScreen(width * 0.45, height * 0.06);
GlobalUI.ServerCopyright.Pos = VectorScreen(width * 0.545, height * 0.925);
}
}

function SendData(str, int)
{
local message = Stream();
message.WriteInt(int.tointeger());
message.WriteString(str);
Server.SendData(message);
}

function ShowScreenMask(){
GlobalUI.BackgroundMask_0.Alpha = 150;
}

function HideScreenMask(){
GlobalUI.BackgroundMask_0.Alpha = 0;
}

function ShowElement(element)
{
if(element == null) return;

element.RemoveFlags(GUI_FLAG_DISABLED);
element.AddFlags(GUI_FLAG_VISIBLE);
}

function HideElement(element)
{
if(element == null) return;

element.AddFlags(GUI_FLAG_DISABLED);
element.RemoveFlags(GUI_FLAG_VISIBLE);
}

function Distance( x1, y1, z1, x2, y2, z2 )
{
    return sqrt( (x1 - x2) * (x1 - x2) + (y1 - y2) * (y1 - y2) + (z1 - z2) * (z1 - z2) );
}

function Abs(a)
{
if(a < 0)
{
a = a * -1;
}

return a;
}

function Minus(a)
{
if(a > 0)
{
a = a * -1;
}

return a;
}

function Lerp( a, b, t )
{
return a+(b-a)*t;
}

function Clamp( value, min, max )
{
if(value < min) return min;
else if(value > max) return max;
else return value;
}

function Random(min=0, max=RAND_MAX)
{
local r = rand();
srand(System.GetTimestamp() * r);
return (r % ((max + 1) - min)) + min;
}

function NumberReturnZero(num, length){
return ( "0000000000" + num ).slice( -length ); 
}
[/noae][/noae][/noae][/spoiler]

Bruh I Added The Weapon Successfully I Forget That I am using notepad for editing the file and i should use notepad c++ or Visual Studio Code.
but i had some problem when i aqquire that weapon then the server kicked me and I see error on console wtf was that you can see the error
https://ibb.co/JHVKWbD
now plz help me with this
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on May 29, 2021, 08:11 AM
Quote from: Yyg on May 28, 2021, 11:01 AMThis is my main.nut file and it runs without any problems with me

(https://z3.ax1x.com/2021/05/28/2kPIN6.png)

[spoiler][noae][noae][noae]g_MAXPLAYER <- 64;

g_MAPPOINTCOUNT <- 5
g_ANIMMENUCOUNT <- 13;
//g_WEAPONPOOLS <- [7, 8, 10, 11, 12, 13 ,15 ,18, 19, 21, 22, 25, 26, 28]; //31
g_WEAPONPOOLS <- [26, 26, 26, 11, 12, 26,26 ,26, 19, 26, 22, 25, 26, 28]; //31
g_EQUIPPOOLS <- [0, 1, 2, 3, 4];

g_ZeroVector <- VectorScreen(0, 0);
g_FullColour <- Colour(255, 255, 255, 255);
g_ZeroColour <- Colour(0, 0, 0, 0);

g_MainColour_0 <- Colour(255, 164, 26, 235);
g_MainColour_1 <- Colour(0, 0, 0, 240);
g_MainColour_2 <- Colour(15, 15, 15, 220);

g_BackgroundSprite <- "Inside/Background.png";
g_AlphaSprite <- "Inside/ZeroAlpha.png";

Global <-
{
LocalPlayer = null
LocalPlayerUIDGroup = ""
LocalVehicle = null

IsPlayerSpawnJumping = false

IsLogined = false
GameAnnounceAwakeTime = 0
}

GlobalUI <-
{
BackgroundMask_0 = GUISprite("Inside/BackgroundMask_0.png", g_ZeroVector, g_ZeroColour)
ServerCopyright = GUISprite("Inside/Copyright.png", g_ZeroVector, g_FullColour)
GameAnnounce = GUISprite("Inside/ZeroAlpha.png", g_ZeroVector, Colour(255, 255, 255, 0))
HealthBackground = GUISprite(g_BackgroundSprite, g_ZeroVector, Colour(255, 0, 0, 0))
}

keyEnter <- KeyBind( 0x0D );
keyEsc <- KeyBind( 0x1B );
keySpace <- KeyBind( 0x20 );
keyOEM <- KeyBind( 0xC0 );
keyRMouse <- KeyBind( 0x02 );
m_KeyAltEnter <- KeyBind( 0x12, 0x0D );

include( "3dchat.nut" );
include( "windows_mem.nut" );
include( "scenemanager_mem.nut" );
include( "account_mem.nut" );
include( "client_mem.nut" );
include( "gamemenu_mem.nut" );
include( "smallmap_mem.nut" );
include( "dashboard_mem.nut" );

function Script::ScriptLoad(){
Global.LocalPlayer = World.FindLocalPlayer();

AwakeAndCheckGameWindows();
AwakeClientScript();

GlobalUI.ServerCopyright.SendToTop();
GUI.GameResize(GUI.GetScreenSize().X, GUI.GetScreenSize().Y);
}

function Script::ScriptProcess(){
WindowsClassProc();
SceneManagerProc();
AccountClassProc();
ChatBubbleProc();
ClientScriptProc();
VehicleDashboardProc();
}

function Server::ServerData(stream)
{
local StreamReadInt = stream.ReadInt(),
StreamReadString = stream.ReadString();

ClientServerData(StreamReadInt, StreamReadString);
}

function KeyBind::OnDown(key)
{
SceneManagerKeyDown(key);
}

function KeyBind::OnUp(key)
{

}

function GUI::GameResize(width, height){
UpdateGlobalUIResize();

UpdateWindowsClassResize();
UpdateDashboardClassResize();
UpdateSceneManagerResize();
UpdateAccountPanelResize();
UpdateClientClassResize();
UpdateRankingMenuUIsResize();
}

function GUI::ElementHoverOver(element)
{
AccountPanelElementHoverOver(element);
ClientClassElementHoverOver(element);
}

function GUI::ElementHoverOut(element)
{
AccountPanelElementHoverOut(element);
ClientClassElementHoverOut(element);
}

function GUI::ElementClick(element, mouseX, mouseY)
{
AccountPanelElementClick(element, mouseX, mouseY);
}

function GUI::ElementRelease(element, mouseX, mouseY)
{
ClientClassElementRelease(element, mouseX, mouseY);
}

function GUI::InputReturn(editbox)
{
AccountPanelInputReturn(editbox);
}

function GUI::WindowClose(window)
{
ClientClassWindowClose(window);
}

function GUI::CheckboxToggle(checkbox, checked)
{

}

function GUI::ScrollbarScroll(scrollbar, position, change)
{

}

function GUI::ElementDrag(element, mouseX, mouseY)
{

}

function UpdateGlobalUIResize(){
local width = GUI.GetScreenSize().X, height = GUI.GetScreenSize().Y;

GlobalUI.HealthBackground.Size = GUI.GetScreenSize();

GlobalUI.GameAnnounce.Size = VectorScreen(width * 0.3, height * 0.1);
GlobalUI.GameAnnounce.Pos = VectorScreen(width / 2 - (GlobalUI.GameAnnounce.Size.X / 2), height * 0.3);

if(GlobalUI.BackgroundMask_0) GlobalUI.BackgroundMask_0.Size = VectorScreen(width, height);
if(GlobalUI.ServerCopyright)
{
GlobalUI.ServerCopyright.Size = VectorScreen(width * 0.45, height * 0.06);
GlobalUI.ServerCopyright.Pos = VectorScreen(width * 0.545, height * 0.925);
}
}

function SendData(str, int)
{
local message = Stream();
message.WriteInt(int.tointeger());
message.WriteString(str);
Server.SendData(message);
}

function ShowScreenMask(){
GlobalUI.BackgroundMask_0.Alpha = 150;
}

function HideScreenMask(){
GlobalUI.BackgroundMask_0.Alpha = 0;
}

function ShowElement(element)
{
if(element == null) return;

element.RemoveFlags(GUI_FLAG_DISABLED);
element.AddFlags(GUI_FLAG_VISIBLE);
}

function HideElement(element)
{
if(element == null) return;

element.AddFlags(GUI_FLAG_DISABLED);
element.RemoveFlags(GUI_FLAG_VISIBLE);
}

function Distance( x1, y1, z1, x2, y2, z2 )
{
    return sqrt( (x1 - x2) * (x1 - x2) + (y1 - y2) * (y1 - y2) + (z1 - z2) * (z1 - z2) );
}

function Abs(a)
{
if(a < 0)
{
a = a * -1;
}

return a;
}

function Minus(a)
{
if(a > 0)
{
a = a * -1;
}

return a;
}

function Lerp( a, b, t )
{
return a+(b-a)*t;
}

function Clamp( value, min, max )
{
if(value < min) return min;
else if(value > max) return max;
else return value;
}

function Random(min=0, max=RAND_MAX)
{
local r = rand();
srand(System.GetTimestamp() * r);
return (r % ((max + 1) - min)) + min;
}

function NumberReturnZero(num, length){
return ( "0000000000" + num ).slice( -length ); 
}
[/noae][/noae][/noae][/spoiler]

bruh plz tell me how i got kicked when i aqquire the custom weapon plz tell me bruh
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on May 30, 2021, 01:44 AM
Quote from: MRSK143 on May 28, 2021, 02:58 PM
Quote from: Yyg on May 28, 2021, 11:01 AMThis is my main.nut file and it runs without any problems with me

(https://z3.ax1x.com/2021/05/28/2kPIN6.png)

[spoiler][noae][noae][noae][noae]g_MAXPLAYER <- 64;

g_MAPPOINTCOUNT <- 5
g_ANIMMENUCOUNT <- 13;
//g_WEAPONPOOLS <- [7, 8, 10, 11, 12, 13 ,15 ,18, 19, 21, 22, 25, 26, 28]; //31
g_WEAPONPOOLS <- [26, 26, 26, 11, 12, 26,26 ,26, 19, 26, 22, 25, 26, 28]; //31
g_EQUIPPOOLS <- [0, 1, 2, 3, 4];

g_ZeroVector <- VectorScreen(0, 0);
g_FullColour <- Colour(255, 255, 255, 255);
g_ZeroColour <- Colour(0, 0, 0, 0);

g_MainColour_0 <- Colour(255, 164, 26, 235);
g_MainColour_1 <- Colour(0, 0, 0, 240);
g_MainColour_2 <- Colour(15, 15, 15, 220);

g_BackgroundSprite <- "Inside/Background.png";
g_AlphaSprite <- "Inside/ZeroAlpha.png";

Global <-
{
LocalPlayer = null
LocalPlayerUIDGroup = ""
LocalVehicle = null

IsPlayerSpawnJumping = false

IsLogined = false
GameAnnounceAwakeTime = 0
}

GlobalUI <-
{
BackgroundMask_0 = GUISprite("Inside/BackgroundMask_0.png", g_ZeroVector, g_ZeroColour)
ServerCopyright = GUISprite("Inside/Copyright.png", g_ZeroVector, g_FullColour)
GameAnnounce = GUISprite("Inside/ZeroAlpha.png", g_ZeroVector, Colour(255, 255, 255, 0))
HealthBackground = GUISprite(g_BackgroundSprite, g_ZeroVector, Colour(255, 0, 0, 0))
}

keyEnter <- KeyBind( 0x0D );
keyEsc <- KeyBind( 0x1B );
keySpace <- KeyBind( 0x20 );
keyOEM <- KeyBind( 0xC0 );
keyRMouse <- KeyBind( 0x02 );
m_KeyAltEnter <- KeyBind( 0x12, 0x0D );

include( "3dchat.nut" );
include( "windows_mem.nut" );
include( "scenemanager_mem.nut" );
include( "account_mem.nut" );
include( "client_mem.nut" );
include( "gamemenu_mem.nut" );
include( "smallmap_mem.nut" );
include( "dashboard_mem.nut" );

function Script::ScriptLoad(){
Global.LocalPlayer = World.FindLocalPlayer();

AwakeAndCheckGameWindows();
AwakeClientScript();

GlobalUI.ServerCopyright.SendToTop();
GUI.GameResize(GUI.GetScreenSize().X, GUI.GetScreenSize().Y);
}

function Script::ScriptProcess(){
WindowsClassProc();
SceneManagerProc();
AccountClassProc();
ChatBubbleProc();
ClientScriptProc();
VehicleDashboardProc();
}

function Server::ServerData(stream)
{
local StreamReadInt = stream.ReadInt(),
StreamReadString = stream.ReadString();

ClientServerData(StreamReadInt, StreamReadString);
}

function KeyBind::OnDown(key)
{
SceneManagerKeyDown(key);
}

function KeyBind::OnUp(key)
{

}

function GUI::GameResize(width, height){
UpdateGlobalUIResize();

UpdateWindowsClassResize();
UpdateDashboardClassResize();
UpdateSceneManagerResize();
UpdateAccountPanelResize();
UpdateClientClassResize();
UpdateRankingMenuUIsResize();
}

function GUI::ElementHoverOver(element)
{
AccountPanelElementHoverOver(element);
ClientClassElementHoverOver(element);
}

function GUI::ElementHoverOut(element)
{
AccountPanelElementHoverOut(element);
ClientClassElementHoverOut(element);
}

function GUI::ElementClick(element, mouseX, mouseY)
{
AccountPanelElementClick(element, mouseX, mouseY);
}

function GUI::ElementRelease(element, mouseX, mouseY)
{
ClientClassElementRelease(element, mouseX, mouseY);
}

function GUI::InputReturn(editbox)
{
AccountPanelInputReturn(editbox);
}

function GUI::WindowClose(window)
{
ClientClassWindowClose(window);
}

function GUI::CheckboxToggle(checkbox, checked)
{

}

function GUI::ScrollbarScroll(scrollbar, position, change)
{

}

function GUI::ElementDrag(element, mouseX, mouseY)
{

}

function UpdateGlobalUIResize(){
local width = GUI.GetScreenSize().X, height = GUI.GetScreenSize().Y;

GlobalUI.HealthBackground.Size = GUI.GetScreenSize();

GlobalUI.GameAnnounce.Size = VectorScreen(width * 0.3, height * 0.1);
GlobalUI.GameAnnounce.Pos = VectorScreen(width / 2 - (GlobalUI.GameAnnounce.Size.X / 2), height * 0.3);

if(GlobalUI.BackgroundMask_0) GlobalUI.BackgroundMask_0.Size = VectorScreen(width, height);
if(GlobalUI.ServerCopyright)
{
GlobalUI.ServerCopyright.Size = VectorScreen(width * 0.45, height * 0.06);
GlobalUI.ServerCopyright.Pos = VectorScreen(width * 0.545, height * 0.925);
}
}

function SendData(str, int)
{
local message = Stream();
message.WriteInt(int.tointeger());
message.WriteString(str);
Server.SendData(message);
}

function ShowScreenMask(){
GlobalUI.BackgroundMask_0.Alpha = 150;
}

function HideScreenMask(){
GlobalUI.BackgroundMask_0.Alpha = 0;
}

function ShowElement(element)
{
if(element == null) return;

element.RemoveFlags(GUI_FLAG_DISABLED);
element.AddFlags(GUI_FLAG_VISIBLE);
}

function HideElement(element)
{
if(element == null) return;

element.AddFlags(GUI_FLAG_DISABLED);
element.RemoveFlags(GUI_FLAG_VISIBLE);
}

function Distance( x1, y1, z1, x2, y2, z2 )
{
    return sqrt( (x1 - x2) * (x1 - x2) + (y1 - y2) * (y1 - y2) + (z1 - z2) * (z1 - z2) );
}

function Abs(a)
{
if(a < 0)
{
a = a * -1;
}

return a;
}

function Minus(a)
{
if(a > 0)
{
a = a * -1;
}

return a;
}

function Lerp( a, b, t )
{
return a+(b-a)*t;
}

function Clamp( value, min, max )
{
if(value < min) return min;
else if(value > max) return max;
else return value;
}

function Random(min=0, max=RAND_MAX)
{
local r = rand();
srand(System.GetTimestamp() * r);
return (r % ((max + 1) - min)) + min;
}

function NumberReturnZero(num, length){
return ( "0000000000" + num ).slice( -length ); 
}
[/noae][/noae][/noae][/noae][/spoiler]

Bruh I Added The Weapon Successfully I Forget That I am using notepad for editing the file and i should use notepad c++ or Visual Studio Code.
but i had some problem when i aqquire that weapon then the server kicked me and I see error on console wtf was that you can see the error
https://ibb.co/JHVKWbD
now plz help me with this

bruh plz help me plz tell me that how can i fix when i got kicked due to weapon plz help me
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: Yyg on May 30, 2021, 08:52 AM
Please check if this problem occurs before you add weapons

If this problem does not occur, it may be a problem with the weapon mod
If this problem still occurs, please reply to me again, it may be due to some reasons for synchronization

If you don't think too much, you can consider adding anticheat 0 to server.cfg, but this will break the VCMP built-in anti-cheat
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: Yyg on May 30, 2021, 08:53 AM
Some weapon mod data will trigger anti-cheating (such as recovery of HP weapons), I don't know how to solve this problem, you may need to carefully modify the weapon xml file
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on May 30, 2021, 09:58 AM
Hey Bro Can You Make The XML File For Weapons I Will Give YOu Models Of Weapons And Then Make XML file of it plz
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on May 30, 2021, 12:46 PM
Quote from: Yyg on May 30, 2021, 08:53 AMSome weapon mod data will trigger anti-cheating (such as recovery of HP weapons), I don't know how to solve this problem, you may need to carefully modify the weapon xml file

plz fix this problem i dont want to Remove Anti Cheat
https://youtu.be/98MBRJBLZSw
plz help me bruh
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: Yyg on May 31, 2021, 01:35 AM
;)I can't help you with this problem, I have tried this function, but it seems to trigger anti-cheating, I suggest you to check more information in the forum, good luck
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on May 31, 2021, 03:08 AM
Quote from: Yyg on May 31, 2021, 01:35 AM;)I can't help you with this problem, I have tried this function, but it seems to trigger anti-cheating, I suggest you to check more information in the forum, good luck

wait i want some more help from you bruh can you tell me how to remove register window and i want to take register boxes
https://ibb.co/WzSyrRm
in middle of the picture bruh can you help me?
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on Jun 02, 2021, 01:30 AM
Quote from: Yyg on May 31, 2021, 01:35 AM;)I can't help you with this problem, I have tried this function, but it seems to trigger anti-cheating, I suggest you to check more information in the forum, good luck

bruh i want some help bruh cuz you made your server in gui plz help me
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: Yyg on Jun 02, 2021, 03:22 AM
Quote from: MRSK143 on Jun 02, 2021, 01:30 AM
Quote from: Yyg on May 31, 2021, 01:35 AM;)I can't help you with this problem, I have tried this function, but it seems to trigger anti-cheating, I suggest you to check more information in the forum, good luck

bruh i want some help bruh cuz you made your server in gui plz help me
If you want to move out of the account system, you need to change both the server and client scripts. If you just want to move out of the window, you can look at the code reference, just comment out the code before the createAccount (just an example). I suggest you try reading the store/scripts file code
As long as you understand the server code, you will be able to make more extensions. Good luck
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: Sebastian on Jun 02, 2021, 07:34 PM
Quote from: Yyg on Jun 02, 2021, 03:22 AMAs long as you understand the server code, you will be able to make more extensions. Good luck

Agree.
@MRSK143 you should be very thankful for Yyg's help,  as he tried to help you a lot with examples and everything,  while you know nothing about scripting.
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: MRSK143 on Jun 02, 2021, 11:58 PM
Quote from: Yyg on Jun 02, 2021, 03:22 AM
Quote from: MRSK143 on Jun 02, 2021, 01:30 AM
Quote from: Yyg on May 31, 2021, 01:35 AM;)I can't help you with this problem, I have tried this function, but it seems to trigger anti-cheating, I suggest you to check more information in the forum, good luck

bruh i want some help bruh cuz you made your server in gui plz help me
If you want to move out of the account system, you need to change both the server and client scripts. If you just want to move out of the window, you can look at the code reference, just comment out the code before the createAccount (just an example). I suggest you try reading the store/scripts file code
As long as you understand the server code, you will be able to make more extensions. Good luck

hey bro  you helped me a lot i am very thankful to you bro
Title: Re: Help Me - how to add custom weapons in Yyg's PUB-G server?
Post by: Yyg on Jun 03, 2021, 01:11 AM
:) You're welcome. Good luck for all