C0nw0nk / Garrys-Mod-Fake-Players

Spoof / Spoofing / fake / faked / faking players counts on servers in Garrys Mod using bots lots of useful features to customize slots to be kept free / open and make the bots look like real players GMod / GarrysMod / Garry's Mod / Garry'sMod has allot of fake servers
http://www.networkflare.com/
18 stars 8 forks source link

bots spawn but are in unassigned how do i make them spawn as a job? #13

Open vizful opened 4 years ago

vizful commented 4 years ago

paste code of what i need to add?

C0nw0nk commented 4 years ago

Depends on your Game Mode.

https://github.com/C0nw0nk/Garrys-Mod-Fake-Players/blob/master/addons/fakeplayers/lua/autorun/server/sv_fakeplayers.lua#L46

You have not said what game mode you are using.

vizful commented 4 years ago

starwarsrp

vizful commented 4 years ago

and start job as TEAM_CADET

vizful commented 4 years ago

also i changed some things on this and did to all the others is that the correct thing to be changing?

--Assign all bots to a single team rather than let your game mode balance them.
        if Team_to_Assign_Bots != false then
            --Get all bots.
            for k,v in pairs(player.GetBots()) do
                --If the bot is not on the team specified.
                if v:Team() != TEAM_CADET then
                    --Some game modes are stupid so we need to kill the bot before switching team.
                    --v:Kill()
                    v:KillSilent()
                    --Team to put the bots on.
                    v:SetTeam(TEAM_CADET)
                end
            end
        end
    end)
end

end)

and it seems to put them on the team but only one spawns with no name and the rest seem to be still dead and not force re spawning either with the code u put to help the other guy and i put in the disable movement code to.