nuclearsilo583 / zephyrus-store-preview-new-syntax

My rewritten zephyrus store
62 stars 40 forks source link

Bug with player models #6

Closed Roosteridk closed 3 years ago

Roosteridk commented 3 years ago

Blackjack is in the menu, but there is no plugin for it??

Roosteridk commented 3 years ago

Also, how do you activate playerskins?

nuclearsilo583 commented 3 years ago
  1. Blackjack: install this plugins (I also updated the file on my master). link item type mean command on store. Set player option to use configured command on store menu
  2. For player skin you need to install this plugin for materials and models precached on map start or you may cause server crash. I disabled the precached on my .sp since this will cause server to crash.
    • You need to install the skin (all materials, models) to your server and make sure upload them to your fastdl server. If the skin isnt installed. The skin wont appear in store menu
    • If you are running azombie reloaded server. Please use the store_item_playerskins . If you are not running a zombie reloaded server. Please use store_item_playerskins_no_zr_version
    • For the configs file, open your items.txt in configs/store/ and add an item to it

This item has no plan "Tofu" { "model" "models/player/custom_player/thas/my_model/tofu_v3/tofu.mdl" "arms" "models/player/custom_player/thas/my_model/tofu_v3/tofu_arms.mdl" "team" "4" // Ts = 2 , CT = 3, both = 4 "type" "playerskin" "preview" "1" // Enable the preview for this item, only item that support preview can use this feature "unique_id" "uid_model_tofu" // You must have "unique_id" "price" "100" }

Check here

Roosteridk commented 3 years ago

Thank you so much, great plugin btw!

Roosteridk commented 3 years ago

Looks like I celebrated too early.

When I try to compile the store I get this error

// store/playerskins.sp(11) : error 147: new-style declarations are required
// store/playerskins.sp(24) : error 147: new-style declarations are required
// store/playerskins.sp(26) : error 147: new-style declarations are required
// store/playerskins.sp(27) : error 147: new-style declarations are required
// store/playerskins.sp(29) : error 147: new-style declarations are required
// store/playerskins.sp(30) : error 147: new-style declarations are required
// store/playerskins.sp(31) : error 147: new-style declarations are required
// store/playerskins.sp(32) : error 147: new-style declarations are required
// store/playerskins.sp(33) : error 147: new-style declarations are required
// store/playerskins.sp(35) : error 147: new-style declarations are required
// store/playerskins.sp(36) : error 147: new-style declarations are required
// store/playerskins.sp(41) : error 147: new-style declarations are required
// store/playerskins.sp(77) : error 147: new-style declarations are required
// store/playerskins.sp(79) : error 147: new-style declarations are required
// store/playerskins.sp(91) : error 017: undefined symbol "sCache"
// store/playerskins.sp(91) : error 029: invalid expression, assumed zero
// store/playerskins.sp(91) : warning 215: expression has no effect
// store/playerskins.sp(91) : error 001: expected token: ";", but found "]"
// store/playerskins.sp(91) : fatal error 190: too many error messages on one line
nuclearsilo583 commented 3 years ago

use my scripting folder at master. Replace all file that duplicated. Your is the old from dvanai original store. I have edited many of them so you may have some problem on compile if you use dvanai. Use my scripting folder and replace all the file it ask. You should be able to compile all the file needed.

Roosteridk commented 3 years ago

Just to confirm, in order to enable the module, we need to remove the comments from store.sp right?

I tried compiling with your scripting folder but still got the same error

nuclearsilo583 commented 3 years ago

yes but some of the modules are written with old syntax. You may find some error when compile. If you want to enabled old modules from zephyrus store, comment this line #pragma newdecls required at line 2 on store.sp. Enable modules by uncomment any modules you want

Roosteridk commented 3 years ago

I'm kinda lost. newdecls is already there. I keep getting the same error. Do I include the one on store/playerskins.sp or compile store_item_playerskins_no_zr_version alone?

nuclearsilo583 commented 3 years ago

current my store.sp on scripting folder has disabled many modules and rewritten some of them in a standalone plugin seperated to the zephyrus original store. Lets me guide you to install.

  1. Download files at master
  2. Copy and replace all file from my scripting folder to your compile place (such as addons/sourcemod/scripting)
  3. Current build of store.sp is written in new syntax and has been disabled some of none use module such as weapon paint and weapon skin... etc
  4. If you want to re-enable any module that I removed. You will need to comment on line 2 in store.sp to disable neww style syntax.
  5. store/playerskin.sp dont have preview function to support preview. Use my playerskin modules in scripting (store_item_playerskin.sp is for ZombieReloaded server and no_zr to run with server have no zombie reloaded). Choose any you need. P/s: you can look for information and example at #1
Roosteridk commented 3 years ago

Ok, I got playerskins_no_zr working. There are two issues though:

  1. Instant skin change only works on remove (also line 51 and 57 are duplicates)
  2. Store tag is ♛ J1BroS Store ♛ which is independent from what's defined in the config
nuclearsilo583 commented 3 years ago

Fixed and update store tag for others plugins.

  1. I see no duplicated as you said, skin will change instant when you hit equip, but if you are in different team from config, the skin will applied on next time you spawn in that team (not current team). On next spawn it has delay for the skin to be applied. Check for this cvar
  2. Now all store tag will depend on this cvar (line 25)
Roosteridk commented 3 years ago
"Viper"
        {
            "model" "models/player/custom_player/legacy/gxp/valorant/viper/viper_v1.mdl"
            "arms" "models/player/custom_player/legacy/gxp/valorant/viper/viper_arm_v1.mdl"
            "team" "4" // Ts = 2 , CT = 3, both = 4
            "type" "playerskin"
            "preview" "1" // Enable the preview for this item, only item that support preview can use this feature
            "unique_id" "uid_model_viper" // You must have "unique_id" 
            "price" "5000"
        }

It's set to both teams but when you equip the skin, it waits until next respawn

nuclearsilo583 commented 3 years ago

both team required next spawn to be able to apply to prevent duplicate skin. So i cant help you about this. Sorry

Roosteridk commented 3 years ago

Is this normal? https://www.youtube.com/watch?v=EALZLgOUWEc

nuclearsilo583 commented 3 years ago

All fixed on new commit. Now this cvar will take effect. Please reinstall store.sp and playerskin_no_zr.sp For the plugin chat tag. I install everything on my totally new server and have no issue with the chat tag. Maybe reinstall or check any plugins that may cause conflict.