mirror of
https://github.com/hypervortex/VH-Bombsquad-Modded-Server-Files
synced 2025-11-07 17:36:08 +00:00
Update custom_hooks.py
This commit is contained in:
parent
0257199e0b
commit
aa6a5d8bd9
1 changed files with 23 additions and 3 deletions
24
dist/ba_root/mods/custom_hooks.py
vendored
24
dist/ba_root/mods/custom_hooks.py
vendored
|
|
@ -24,7 +24,7 @@ from bastd.activity.coopscore import CoopScoreScreen
|
||||||
import setting
|
import setting
|
||||||
from tools import account
|
from tools import account
|
||||||
from chatHandle import handlechat
|
from chatHandle import handlechat
|
||||||
from features import team_balancer, afk_check, fire_flies, hearts, dual_team_score as newdts
|
from features import team_balancer, afk_check, fire_flies, snow_fall, hearts, dual_team_score as newdts
|
||||||
from stats import mystats
|
from stats import mystats
|
||||||
from spazmod import modifyspaz
|
from spazmod import modifyspaz
|
||||||
from tools import servercheck, ServerUpdate, logger, playlist, servercontroller
|
from tools import servercheck, ServerUpdate, logger, playlist, servercontroller
|
||||||
|
|
@ -267,11 +267,28 @@ ba._activity.Activity.on_player_join = on_player_join
|
||||||
|
|
||||||
def night_mode() -> None:
|
def night_mode() -> None:
|
||||||
"""Checks the time and enables night mode."""
|
"""Checks the time and enables night mode."""
|
||||||
|
#Night Mode for permanently
|
||||||
|
if not settings["ShiningPlayers"]:
|
||||||
|
activity = _ba.get_foreground_host_activity()
|
||||||
|
activity.globalsnode.ambient_color = (1.15, 1.25, 1.6)
|
||||||
|
##
|
||||||
#Night Mode for permanently
|
#Night Mode for permanently
|
||||||
if settings['NightMode']:
|
if settings['NightMode']:
|
||||||
activity = _ba.get_foreground_host_activity()
|
activity = _ba.get_foreground_host_activity()
|
||||||
activity.globalsnode.tint = (0.5, 0.7, 1.0)
|
activity.globalsnode.tint = (0.5, 0.7, 1.0)
|
||||||
|
##
|
||||||
|
#set your own deflaut colour
|
||||||
|
if settings["OwnDefaultBackground"]["enable"]:
|
||||||
|
activity = _ba.get_foreground_host_activity()
|
||||||
|
color = settings["OwnDefaultBackground"]["color"]
|
||||||
|
activity.globalsnode.tint = tuple(color)
|
||||||
|
##
|
||||||
|
#Snowfall in map permanently
|
||||||
|
if settings["Snowfall"]["enable"]:
|
||||||
|
activity = _ba.get_foreground_host_activity()
|
||||||
|
activity.snowfall_generator(settings["Snowfall"]["SnowCount"],
|
||||||
|
settings["Snowfall"]["SnowFallingSpeed"], settings["Snowfall"]["SnowScale"])
|
||||||
|
###
|
||||||
#Auto Night Mode with start and end time
|
#Auto Night Mode with start and end time
|
||||||
if settings['autoNightMode']['enable']:
|
if settings['autoNightMode']['enable']:
|
||||||
|
|
||||||
|
|
@ -288,6 +305,9 @@ def night_mode() -> None:
|
||||||
if settings['autoNightMode']['fireflies']:
|
if settings['autoNightMode']['fireflies']:
|
||||||
activity.fireflies_generator(
|
activity.fireflies_generator(
|
||||||
20, settings['autoNightMode']["fireflies_random_color"])
|
20, settings['autoNightMode']["fireflies_random_color"])
|
||||||
|
if settings["autoNightMode"]["Snowfall"]:
|
||||||
|
activity.snowfall_generator(settings["Snowfall"]["SnowCount"],
|
||||||
|
settings["Snowfall"]["SnowFallingSpeed"], settings["Snowfall"]["SnowScale"])
|
||||||
|
|
||||||
|
|
||||||
def kick_vote_started(started_by: str, started_to: str) -> None:
|
def kick_vote_started(started_by: str, started_to: str) -> None:
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue