Snowfall for Black Mesa

A place for requesting new Source.Python plugins to be made for your server.

Please request only one plugin per thread.
User avatar
satoon101
Project Leader
Posts: 2697
Joined: Sat Jul 07, 2012 1:59 am

Re: Snowfall for Black Mesa

Postby satoon101 » Tue Oct 10, 2017 10:55 pm

The error occurs now because there have been updates to Source.Python where the code in my post will no longer load. However, as Ayuto stated, even if I were to update that code to work with the newest Source.Python, it would still crash the client. I haven't found anything further that is working on any game except for CS:GO.
Image
cssbestrpg
Senior Member
Posts: 287
Joined: Sun May 17, 2020 7:56 am
Location: Finland
Contact:

Re: Snowfall for Black Mesa

Postby cssbestrpg » Sat Dec 18, 2021 11:52 am

Hello i just tested the code it seems to work fine now in Cs:s and HL2:DM after i did update the code a bit.

Here is the code the works fine for me in cs:s & hl2:dm

Syntax: Select all

from colors import Color
from entities.constants import WORLD_ENTITY_INDEX, RenderMode
from entities.entity import Entity
from engines.precache import Model
from engines.server import global_vars
from events import Event
from listeners import OnLevelInit
from listeners.tick import Delay


@OnLevelInit
@Event('round_start')
def create_snow(*args):
try:
worldspawn = Entity(WORLD_ENTITY_INDEX)
except ValueError:
Delay(0, create_snow)
return
func_precipitation = Entity.find_or_create("func_precipitation")
func_precipitation.model = Model("maps/{0}.bsp".format(global_vars.map_name))
func_precipitation.precip_type = 3
func_precipitation.color = Color(218, 243, 255)
func_precipitation.render_mode = RenderMode(3)
func_precipitation.spawn()
func_precipitation.mins = worldspawn.world_mins
func_precipitation.maxs = worldspawn.world_maxs
origin = (func_precipitation.mins + func_precipitation.maxs) / 2
func_precipitation.origin = origin

create_snow()
User avatar
daren adler
Senior Member
Posts: 328
Joined: Sat May 18, 2019 7:42 pm

Re: Snowfall for Black Mesa

Postby daren adler » Sun Dec 19, 2021 5:48 am

cssbestrpg wrote:Hello i just tested the code it seems to work fine now in Cs:s and HL2:DM after i did update the code a bit.

Here is the code the works fine for me in cs:s & hl2:dm

Syntax: Select all

from colors import Color
from entities.constants import WORLD_ENTITY_INDEX, RenderMode
from entities.entity import Entity
from engines.precache import Model
from engines.server import global_vars
from events import Event
from listeners import OnLevelInit
from listeners.tick import Delay


@OnLevelInit
@Event('round_start')
def create_snow(*args):
try:
worldspawn = Entity(WORLD_ENTITY_INDEX)
except ValueError:
Delay(0, create_snow)
return
func_precipitation = Entity.find_or_create("func_precipitation")
func_precipitation.model = Model("maps/{0}.bsp".format(global_vars.map_name))
func_precipitation.precip_type = 3
func_precipitation.color = Color(218, 243, 255)
func_precipitation.render_mode = RenderMode(3)
func_precipitation.spawn()
func_precipitation.mins = worldspawn.world_mins
func_precipitation.maxs = worldspawn.world_maxs
origin = (func_precipitation.mins + func_precipitation.maxs) / 2
func_precipitation.origin = origin

create_snow()


I did try this plugin and it does not crash the server, but just will not let no one get on (or me) and throws this up at players desktop--> Engine Error

Code: Select all

CUtlList! (exhausted index rande)
cssbestrpg
Senior Member
Posts: 287
Joined: Sun May 17, 2020 7:56 am
Location: Finland
Contact:

Re: Snowfall for Black Mesa

Postby cssbestrpg » Sun Dec 19, 2021 10:36 am

Is your server linux? I tested at windows server with newest sp.
For me it worked fine, it did let me go in the server.

Edit:

Tested in css linux server i got that error when i loaded immeadily the plugin, but i got it work when it loads directly from autoexec.cfg
User avatar
daren adler
Senior Member
Posts: 328
Joined: Sat May 18, 2019 7:42 pm

Re: Snowfall for Black Mesa

Postby daren adler » Sun Dec 19, 2021 10:25 pm

cssbestrpg wrote:Is your server linux? I tested at windows server with newest sp.
For me it worked fine, it did let me go in the server.

Edit:

Tested in css linux server i got that error when i loaded immeadily the plugin, but i got it work when it loads directly from autoexec.cfg

I tryed it on windows, i have a linux also but did not try on there. i will do the sp update and see. ty.
cssbestrpg
Senior Member
Posts: 287
Joined: Sun May 17, 2020 7:56 am
Location: Finland
Contact:

Re: Snowfall for Black Mesa

Postby cssbestrpg » Sun Dec 19, 2021 10:37 pm

daren adler wrote:
cssbestrpg wrote:Is your server linux? I tested at windows server with newest sp.
For me it worked fine, it did let me go in the server.

Edit:

Tested in css linux server i got that error when i loaded immeadily the plugin, but i got it work when it loads directly from autoexec.cfg

I tryed it on windows, i have a linux also but did not try on there. i will do the sp update and see. ty.


Make sure you load the plugin either via server.cfg or autoxec.cfg, those will be executed when you start the server.
When it loads the plugin when the server starts, then it works fine(atleast in css it did)
User avatar
daren adler
Senior Member
Posts: 328
Joined: Sat May 18, 2019 7:42 pm

Re: Snowfall for Black Mesa

Postby daren adler » Sun Dec 19, 2021 10:46 pm

Did what you said and still kicks players out and brings that tag on their desktop (CUtlList! (exhausted index rande) and this time it had this on server console and log

Code: Select all

[SP] Successfully loaded plugin 'scoreboard'.
[SP] Loading plugin 'silent_hill'...
[SP] Successfully loaded plugin 'silent_hill'.
[SP] Loading plugin 'snowfall'...
Exception ignored in: <bound method __del__ of <entities._base.Entity object at 0x1D4B4220>>
TypeError: No registered converter was able to extract a C++ pointer to type class CPointer from this Python object of type Entity


Does same thing on linux.
cssbestrpg
Senior Member
Posts: 287
Joined: Sun May 17, 2020 7:56 am
Location: Finland
Contact:

Re: Snowfall for Black Mesa

Postby cssbestrpg » Sun Dec 19, 2021 11:12 pm

Try this Build
You need to unzip that build inside of hl2mp folder.
It will suppress that console error you see
User avatar
daren adler
Senior Member
Posts: 328
Joined: Sat May 18, 2019 7:42 pm

Re: Snowfall for Black Mesa

Postby daren adler » Mon Dec 20, 2021 1:17 am

cssbestrpg wrote:Try this Build
You need to unzip that build inside of hl2mp folder.
It will suppress that console error you see

Ok i will give it a try. ty. Just gave it a try and still sends players to desktop and shows same as first one, did take away error on server console/log. but still kicks player to desktop and says engine error. ( i was thinking maybe i had to many plugins, so i turned them off and same deal).
Thank you for all the work you are doing, my pc/server can be a real pain sometimes so i think i am done for now on this plugin, like i said my server can be a pain and you got yours to work so i know its my side why it wont work and ill try and see why., thank you.
User avatar
L'In20Cible
Project Leader
Posts: 1533
Joined: Sat Jul 14, 2012 9:29 pm
Location: Québec

Re: Snowfall for Black Mesa

Postby L'In20Cible » Mon Dec 20, 2021 5:05 am

It will only work on small maps that don't already have a lot of particles. For example, on CS:S it will work on maps such as cs_assault but won't on maps such as de_dust2 (larger, with lot of dust particles builtins, etc.).

Return to “Plugin Requests”

Who is online

Users browsing this forum: No registered users and 1 guest