weapons icon indicating copy to clipboard operation
weapons copied to clipboard

Added "Pressets" feature!

Open kratos1812 opened this issue 2 years ago • 15 comments

New players can now load pressets so they dont waste time finding new skins. This can be usefull when you are running this plugin on FFA/SURF/RETAKE servers where the players flow is big(a lot of new players). I personally hate to connect to a new server and have to configure all my weapons al over again. With this feature it would make players' life a lot easier.

Everything is done from the plugin's main menu. No nood to acces the config at all. You can preview the skin from the each presset before applying it.

kratos1812 avatar Sep 17 '21 16:09 kratos1812

You most probably wanted to type "presets" and not "pressets" I suggest fixing that atleast :D

yesBad avatar Sep 21 '21 15:09 yesBad

Thanks, seems good to me. Atleast I'll be using this 👍

yesBad avatar Sep 22 '21 10:09 yesBad

Hey! I'm currently running into an issue where Windows hosts do not load the weapons_presets.cfg config correctly. I have manually edited the file as it's easier than creating them in game. However when I transfer the file I get a 'File is used by another process'. When I stop the server and upload it, it works fine but then when I connect the plugin says there's no presets. Plugin works as expected on Linux. Presets made in-game also disappear after a map change.

Note: I recompiled the plugin changing the write permission from r+ to r and it seems to load the configs fine now. Sounds like a Windows write permissions issue.

Shaneajm avatar Oct 03 '21 18:10 Shaneajm

Note: I recompiled the plugin changing the write permission from r+ to r and it seems to load the configs fine now. Sounds like a Windows write permissions issue.

Hi, thanks for your help, really usefull. Didn't chaning the permission string from r+ to r broke the "Save Preset" feature as it needs to write to that file?

kratos1812 avatar Oct 03 '21 19:10 kratos1812

Hi, thanks for your help, really usefull. Didn't chaning the permission string from r+ to r broke the "Save Preset" feature as it needs to write to that file?

It does break it, however for my use case I found it easier to just set the presets using the config file instead of the menu. It works for me but I know for other users/plugin functionality it isn't the best fix if you want to use the menus.

Shaneajm avatar Oct 03 '21 20:10 Shaneajm

@Shaneajm I will look into it the following days. For Linux it works good enough. By the way, mind if you share your presets?

kratos1812 avatar Oct 04 '21 05:10 kratos1812

Doubt, in this case it would save the skin options chosen by the players, would that be it?

If so, wouldn't it just be using MySQL to sync with all servers?

crashzk avatar Oct 05 '21 16:10 crashzk

Doubt, in this case it would save the skin options chosen by the players, would that be it?

If so, wouldn't it just be using MySQL to sync with all servers?

no

kratos1812 avatar Oct 05 '21 16:10 kratos1812

Would there be any print, video showing how it works? Even your server's IP? I was curious about the functionality.

crashzk avatar Oct 05 '21 16:10 crashzk

Would there be any print, video showing how it works? Even your server's IP? I was curious about the functionality.

I will post today on youtube a video showing it how it works.

kratos1812 avatar Oct 05 '21 16:10 kratos1812

@crashzk https://youtu.be/jhnpYrm0pFQ - here is a preview ~~And about @Shaneajm's issue: I didn't have the time these days to even turn on my computer, since most of the server oprerators use Linux and not Windows, and as you said it was easier for you to manage your presets, I won't prioritise this in the next 1-2 weeks, I apologize for this.~~

kratos1812 avatar Oct 05 '21 18:10 kratos1812

Now yes, it would be skin collection, right?

Player creates your collection after just going and selecting it, would that be it?

If you're going to enjoy it, something really well appreciated, I've even thought about using it as a web interface, the user enters the site and creates their own collection, or the server owner creates skin collections and leaves it as an option to choose. Or even the player himself chooses his skins manually, all through the site.

crashzk avatar Oct 05 '21 18:10 crashzk

Player creates your collection after just going and selecting it, would that be it?

You can restrict the ability to create a preset to admin only https://github.com/kgns/weapons/pull/228/files#diff-e2120f99c80c8f2365fc445adae1095a2b856b64a4242924991a155912faad82R96. When you save/create a preset, your inventory/selections are saved in a new preset, thats basically it.

I've even thought about using it as a web interface

nobody would use that web interface, this is meant for quick skin selection that allows you to get some nice skins without wasting time in menus

kratos1812 avatar Oct 05 '21 19:10 kratos1812

@Shaneajm fixed your issue.

kratos1812 avatar Oct 06 '21 11:10 kratos1812

@kratos1812 could you fix the conflicts you have with the master branch?

@kgns would it be possible to merge this change into the plugin?

Some players came asking for it, kind of having a skin kit already made and they just chose it and that's it, professional players' skin kit and such.

crashzk avatar Nov 24 '21 23:11 crashzk