[L4d2] How to Creating a Special Infected

Please post any questions about developing your plugin here. Please use the search function before posting!
User avatar
heokami
Junior Member
Posts: 1
Joined: Fri Dec 03, 2021 2:23 pm

[L4d2] How to Creating a Special Infected

Postby heokami » Sat Jan 15, 2022 12:08 pm

hi, i want to Creating Have NextBot Ai Special Infected in my game, and i can use sourcePython control the Infected.

But i try to Creating "Jockey", it's don't work.

it's my code:

Code: Select all

@TypedSayCommand('!ts','admin',on_auth_failed)
@TypedSayCommand('/ts','admin',on_auth_failed)
def on_spawn(command_info):
    player = Player(command_info.index)
   
    entity = Entity.find_or_create('commentary_zombie_spawner')
    jockey_model = Model('models/infected/jockey.mdl')
    entity.model = jockey_model
    entity.origin = player.view_coordinates
    entity.call_input('SpawnZombie','Jockey')
    entity.spawn()


My client console say:

Code: Select all

ERROR:  Can't draw studio model models/infected/jockey.mdl because CBaseEntity is not derived from C_BaseAnimating


Can anyone give me some advice or hints? Thank you very much for your help!

Return to “Plugin Development Support”

Who is online

Users browsing this forum: No registered users and 43 guests