View Single Post
LordKowen
Member
Join Date: Sep 2009
Location: Spain
Old 06-07-2012 , 23:44   Re: [CS] Player Models API 1.2
Reply With Quote #15

Quote:
Originally Posted by Arkshine View Post
No, what I meant is : model change and team change are two different matters, and both, if using the conventional way (the cs_ natives) to do a massive change, will result in such error. That's why PlayerModel plugin or CS Team Changer module, exist. For me, that's not a model problem if you were using the conventional way to change team massively.
Oh, now I get it !!!

Connor's 'Players Models' plugin uses fakemeta instead cs_ native, so you say the problem of SVC_BAD errors is due to other things (e.g. massive team change), and a delay between every model change on massive change isn't needed for prevent that problem. I'm a bit skeptical of that claim, but I'll research about that (if I have any other oportunity in the future, because need enough people ingame for test).

Just now I remembered that Connor's Furien Mod didn't incoporate a change-team when Furiens lose... so, the Furiens aren't always stay on Terrorist team. I had to do a plugin for change-team. Just now I open it to see if I used cs_ natives... and... yes.

(This code go into a function called when CT or TT wins, by a 'SendAudio' event)

Code:
new iPlayers[MAX_PLAYERS], iNum, id

get_players(iPlayers, iNum)

for(new i; i<iNum; i++) {

        id = iPlayers[i]

        switch( cs_get_user_team(id) )
        {
            case CS_TEAM_T:
            {
                cs_set_user_team(id, CS_TEAM_CT, CS_CT_GIGN)
            }
            case CS_TEAM_CT:
            {
                cs_set_user_team(id, CS_TEAM_T, CS_T_LEET)
            }
        }
    }
Are you saying that if I used fakemeta (or other), maybe I would have solved much errors? or is strictly necessary the 'CS Team Changer' module?

Anyway, to stop that SVC_BAD errors, my temporal solution was use custom models only for Furiens (terrorist team) on 'Player Models' plugin, and since I made my own 'Player Model' plugin with Mercylezz guide, I never saw more systematic SVC_BAD kicks when the server fills up. I had problems with other plugins using cs_ natives, and I used fm_ to solve it (or hamsanwich), but I never think a simply team-change can be the cause of that errors (so I not let the plugin in debug mode after I have seen it works well). Anyway, thanks for the info Arkshine, I'll use that module on future servers, optimizing and prevent is always good thing.

But the fact is that with Mercylezz method, you can prevent SVC_BAD kicks when you have a server with much players, and ALL changes his team at the same time (with conventional method or not), and therefore all players changes to another custom model. And there is the ONLY solution I was found, because 'CS Team Changer module' didn't exists until August 2011... precisely the date when my community was dissolved and all servers closed... too late solution for me.

By the way, I didn't say that problem was due to Connor's 'Model Player' plugin. I know it's perfectly working (otherwise the plugin would not be approved). I never thought the problem was the plugin itself... I'm sorry if I implied that in my words. I simply thought would be something like HL or CS core doesn't support certain "massive" changes like this (change all teams+models on <X amount> players at same time). I deduced that because the 'Model Players' change the models when the game announces who's the winner team (not due to SendAudio event, but my custom plugin change teams one by one in that moment, so models change too). I think it's good idea to separate both functions, and ABOVE ALL, put a delay between each change (I had supposed that's the point what finally fixes the problem).

Do the change-model on round start is rather a aesthetics matter (at least on Zombie Plague I think it's much better at begin of the round, and in Furien mod you can still killing when the time is over or when the C4 explodes/deactivates in de_maps... can be confusing and much players attacks his teammates)... and you know... It's impossible to do the team change on event roundstart without killing them (well, it's possible but much difficult if you want to asign the team respawn zones, or team abilities, etc.)... so in both mods I preffer the Mercylezz method, but If it's possible without delay, much better!!!

P.S: Sorry for my mega-post, and for my poor english. I hope I explained well. It's only my opinion based on my experience. ;)
__________________

Last edited by LordKowen; 06-08-2012 at 00:41.
LordKowen is offline