Raised This Month: $7 Target: $400
 1% 

Model/Sprite Spawner w/ Auto-Respawner


Post New Thread Reply   
 
Thread Tools Display Modes
Plugin Info:     Modification:   ALL        Category:   General Purpose        Approver:   Geesu (62)
GHW_Chronic
SourceMod Donor
Join Date: Sep 2004
Location: Texas
Old 10-09-2005 , 05:25   Model/Sprite Spawner w/ Auto-Respawner
Reply With Quote #1

  • This plugin allows you to Precache, Spawn, and Remove Models / Sprites for each map. Example: You want to spawn a model on de_dust2 at your current location of a c4, a gign, a custom model, or even a sprite bilboard for your clan server. But what about on mapchange? Won't the models / sprites just dissapear? Nope, this plugin saves their location + view angle and spawns them back on map change. And if you only want to spawn a model on 1 map you don't have to have all of your clients download the model for any map but that 1 map.

Commands:
  • amx_spawn
    • Spawns a Model / Sprite <part of ent name> [Non-Default Sequence #]
  • amx_spawn_remove
    • Removes Model / Sprite you are standing next to.
  • amx_spawn_list
    • Lists Models / Sprites precached for this map.

How to work it:

The Command:
  • Just go to the location you want the model / sprite to appear at and type amx_spawn <part of name> [Non-Default sequence #]. The model / sprite will spawn at your location looking the way you are looking. If you happen to know a specific sequence you wish to play you can specify it here.

The .ini file:
  • The .ini file is made up of 4 parts all on the same line:
    Code:
    location model_short_name map(or all) defaultsequence#
    example below:
    Code:
    models/player/gign/gign.mdl gign all 0
    models/chicken.mdl chicken de_dust2 1
    models/bigtree.mdl "Big Tree" all 0
    sprites/wowzers.spr omfg aim_map 0
    You can only have up to 200 precaches per map. Remember, the client has to download each model/sprite that you precache for that map.

Mapchange:
  • On mapchange the script will look up the map in it's database and find out if there were models / sprites spawned on that map, and if so then it will spawn them in their proper places w/ the proper view angles + sequence.

Removing Models / Sprites:
  • Just go up to / into the middle of the sprite / model and type the amx_spawn_remove command.

Note: The .ini file must be placed into your amxmodx/configs directory.
Note #2: A "GHW_entspawner_refferences.ini" file will be created by the script, do not delete or modify this file as it keeps track of where to spawn the ents.
Note #3: You can use a program like Half-Life model viewer to view model sequences. (Sequences start at 0 (usually idle) and go up by 1)
Note #4: Try not to go overboard on spawning. That will indeed crash your server.
Attached Files
File Type: sma Get Plugin or Get Source (GHW_Entspawner.sma - 4336 views - 10.3 KB)
File Type: txt GHW_Entspawner.txt (1.4 KB, 2136 views)
File Type: ini GHW_entspawner.ini (38 Bytes, 2048 views)

Last edited by GHW_Chronic; 01-23-2008 at 08:57.
GHW_Chronic is offline
Send a message via AIM to GHW_Chronic
Ywa*NL
Senior Member
Join Date: Apr 2005
Location: The Netherlands
Old 10-09-2005 , 07:06  
Reply With Quote #2

Nice man!
Very nice!
__________________
Ywa*NL is offline
Send a message via MSN to Ywa*NL
Lordang
Junior Member
Join Date: Sep 2005
Old 10-09-2005 , 10:22  
Reply With Quote #3

Nice..
Lordang is offline
atomic
Veteran Member
Join Date: Jan 2005
Location: What The Foot?
Old 10-09-2005 , 10:26  
Reply With Quote #4

does these models have weapons?
__________________
atomic is offline
Zenith77
Veteran Member
Join Date: Aug 2005
Old 10-09-2005 , 10:31  
Reply With Quote #5

Probably not.



@Chronic


Nice man, perfect for trying out models ;)


But just a coding question


why was this
Code:
new precacheerror=false

not this ?

Code:
new bool:precacheerror = false
__________________
Quote:
Originally Posted by phorelyph View Post
your retatred
Zenith77 is offline
GHW_Chronic
SourceMod Donor
Join Date: Sep 2004
Location: Texas
Old 10-09-2005 , 11:43  
Reply With Quote #6

@atomic: you can spawn weapon models, you cant pick them up however.

@Zenith: because at 2:00 AM everything starts to get a little blurry. Fixed.
GHW_Chronic is offline
Send a message via AIM to GHW_Chronic
Zenith77
Veteran Member
Join Date: Aug 2005
Old 10-09-2005 , 12:02  
Reply With Quote #7

Quote:
Originally Posted by GHW_Chronic

@Zenith: because at 2:00 AM everything starts to get a little blurry. Fixed.
lol ;)
__________________
Quote:
Originally Posted by phorelyph View Post
your retatred
Zenith77 is offline
BACARRA
Senior Member
Join Date: Mar 2005
Old 10-10-2005 , 01:02  
Reply With Quote #8

can you go in freelook mode so u can delete sprite/models in high places?
BACARRA is offline
GHW_Chronic
SourceMod Donor
Join Date: Sep 2004
Location: Texas
Old 10-10-2005 , 01:54  
Reply With Quote #9

yes.
GHW_Chronic is offline
Send a message via AIM to GHW_Chronic
uTg | bigpapajiggs
Senior Member
Join Date: Sep 2005
Location: Bellingham, WA
Old 10-16-2005 , 00:13  
Reply With Quote #10

Here ya go. This was funny.

__________________
What's my confidence level? I do crossword puzzles with a pen.
uTg | bigpapajiggs is offline
Send a message via AIM to uTg | bigpapajiggs Send a message via MSN to uTg | bigpapajiggs Send a message via Yahoo to uTg | bigpapajiggs
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 23:06.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode