forked from MarseyWorld/MarseyWorld
add king award
parent
e3014502d7
commit
fc05cf4c80
|
@ -195,6 +195,28 @@
|
|||
animation: 60s linear 0s infinite move-colors;
|
||||
}
|
||||
|
||||
.gold-text:not(a), h1.gold-text.post-title a {
|
||||
--color3: #FBED21;
|
||||
--color2: #edcd1a;
|
||||
--color1: #e3c414;
|
||||
font-family: open sans,sans-serif !important;
|
||||
background: repeating-linear-gradient(
|
||||
45deg,
|
||||
var(--color1),
|
||||
var(--color1) 10px,
|
||||
var(--color2) 20px,
|
||||
var(--color2) 20px,
|
||||
var(--color3) 60px,
|
||||
var(--color3) 60px
|
||||
);
|
||||
color: transparent !important;
|
||||
font-weight: 700 !important;
|
||||
background-clip: text !important;
|
||||
-webkit-background-clip: text !important;
|
||||
animation: 60s linear 0s infinite move-colors;
|
||||
}
|
||||
|
||||
|
||||
.queen:not(a):not(.ectoplasm), h1.queen.post-title a {
|
||||
color: hotpink !important;
|
||||
font-weight: 700 !important;
|
||||
|
@ -238,11 +260,11 @@
|
|||
background: url("/i/sharpen/9.webp?x=6");
|
||||
}
|
||||
|
||||
.rainbow-text:not(a) > p {
|
||||
.rainbow-text:not(a) > p, .gold-text:not(a) > p {
|
||||
color: transparent !important;
|
||||
}
|
||||
|
||||
.rainbow-text del {
|
||||
.rainbow-text del, .gold-text del {
|
||||
color: var(--black);
|
||||
font-weight: 400;
|
||||
}
|
||||
|
|
|
@ -5679,7 +5679,7 @@ lite-youtube.lyt-activated > .lty-playbtn {
|
|||
from {filter: sepia(1) saturate(2)}
|
||||
to {filter: sepia(1) saturate(3) drop-shadow(-1px 1px 3px gold)}
|
||||
}
|
||||
img.golden, img[g]:not([data-src]) {
|
||||
img.golden, img[g]:not([data-src]), .gold-text img {
|
||||
animation: golden 1s infinite alternate linear;
|
||||
}
|
||||
|
||||
|
|
|
@ -69,6 +69,7 @@ class Badge(Base):
|
|||
if self.badge_id == 281: return self.user.namechanged
|
||||
if self.badge_id == 285: return self.user.queen
|
||||
if self.badge_id == 289: return self.user.sharpen
|
||||
if self.badge_id == 302: return self.user.king
|
||||
|
||||
return None
|
||||
|
||||
|
|
|
@ -26,6 +26,8 @@ def get_award_classes(obj, v, title=False):
|
|||
classes.append("glow")
|
||||
if obj.rainbowed:
|
||||
classes.append("rainbow-text")
|
||||
if obj.golden:
|
||||
classes.append("gold-text")
|
||||
if obj.queened:
|
||||
classes.append("queen")
|
||||
if obj.chudded:
|
||||
|
@ -192,6 +194,7 @@ class Comment(Base):
|
|||
casino_game_id = Column(Integer, ForeignKey("casino_games.id"))
|
||||
chudded = Column(Boolean, default=False)
|
||||
rainbowed = Column(Boolean, default=False)
|
||||
golden = Column(Boolean, default=False)
|
||||
queened = Column(Boolean, default=False)
|
||||
sharpened = Column(Boolean, default=False)
|
||||
|
||||
|
|
|
@ -63,6 +63,7 @@ class Post(Base):
|
|||
notify = Column(Boolean)
|
||||
chudded = Column(Boolean, default=False)
|
||||
rainbowed = Column(Boolean, default=False)
|
||||
golden = Column(Boolean, default=False)
|
||||
queened = Column(Boolean, default=False)
|
||||
sharpened = Column(Boolean, default=False)
|
||||
ping_cost = Column(Integer, default=0)
|
||||
|
|
|
@ -89,6 +89,7 @@ class User(Base):
|
|||
lootboxes_bought = Column(Integer, default=0)
|
||||
chud = Column(Integer, default=0)
|
||||
queen = Column(Integer, default=0)
|
||||
king = Column(Integer, default=0)
|
||||
chud_phrase = Column(String)
|
||||
email_verified = Column(Boolean, default=False)
|
||||
shadowbanned = Column(Integer, ForeignKey("users.id"))
|
||||
|
|
|
@ -605,6 +605,19 @@ AWARDS = {
|
|||
"ghost": False,
|
||||
"enabled": True,
|
||||
"positive": False,
|
||||
},
|
||||
"king": {
|
||||
"kind": "king",
|
||||
"title": "King",
|
||||
"description": "Gives the recipient golden text for 24 hours.",
|
||||
"icon": "fas fa-crown",
|
||||
"color": "text-gold",
|
||||
"price": 1000,
|
||||
"deflectable": True,
|
||||
"cosmetic": False,
|
||||
"ghost": False,
|
||||
"enabled": True,
|
||||
"positive": True,
|
||||
},
|
||||
"queen": {
|
||||
"kind": "queen",
|
||||
|
|
|
@ -941,6 +941,7 @@ forced_hats = {
|
|||
"earlylife": ("The Merchant", "SHUT IT DOWN, the goys know!"),
|
||||
"marsify": ("Marsified", "I can't pick my own Marseys, help!"),
|
||||
"is_suspended": ("Behind Bars", "This user is banned and needs to do better!"),
|
||||
"king": ("King Crown II", "Is there any greater satisfaction than being called king by a mentally ill loner on the internet?"),
|
||||
"chud": (
|
||||
("Egg_irl", "This user is getting in touch with xir identity!"),
|
||||
("Trans Flag", "Just in case you forgot, trans lives matter."),
|
||||
|
|
|
@ -174,6 +174,7 @@ def _create_post(title, body, pin_hours):
|
|||
ghost=False,
|
||||
chudded=False,
|
||||
rainbowed=False,
|
||||
golden=False,
|
||||
queened=False,
|
||||
sharpened=False,
|
||||
stickied_utc=stickied_utc,
|
||||
|
@ -404,6 +405,7 @@ def _award_timers_task():
|
|||
_process_timer(User.marsify, [170], "The marsify award you received has expired!")
|
||||
_process_timer(User.rainbow, [171], "The rainbow award you received has expired!")
|
||||
_process_timer(User.queen, [285], "The queen award you received has expired!")
|
||||
_process_timer(User.king, [302], "The king award you received has expired!")
|
||||
_process_timer(User.spider, [179], "The spider award you received has expired!")
|
||||
_process_timer(User.namechanged, [281], "The namelock award you received has expired. You're now back to your old username!", {
|
||||
User.username: User.prelock_username,
|
||||
|
|
|
@ -555,6 +555,13 @@ def award_thing(v, thing_type, id):
|
|||
if thing_type == 'comment' and (not thing.author.deflector or v == thing.author):
|
||||
thing.rainbowed = True
|
||||
g.db.add(thing)
|
||||
elif kind == 'king':
|
||||
if author.king: author.king += 86400
|
||||
else: author.king = int(time.time()) + 86400
|
||||
badge_grant(user=author, badge_id=302)
|
||||
if thing_type == 'comment' and (not thing.author.deflector or v == thing.author):
|
||||
thing.golden = True
|
||||
g.db.add(thing)
|
||||
elif kind == "emoji":
|
||||
award.note = award.note.strip(":").lower()
|
||||
emoji = g.db.query(Emoji).filter_by(name=award.note).one_or_none()
|
||||
|
|
|
@ -276,6 +276,7 @@ def comment(v):
|
|||
ghost=ghost,
|
||||
chudded=chudded,
|
||||
rainbowed=bool(v.rainbow),
|
||||
golden=bool(v.king),
|
||||
queened=bool(v.queen),
|
||||
sharpened=bool(v.sharpen),
|
||||
)
|
||||
|
|
|
@ -570,6 +570,7 @@ def submit_post(v, sub=None):
|
|||
ghost=flag_ghost,
|
||||
chudded=flag_chudded,
|
||||
rainbowed=bool(v.rainbow),
|
||||
golden=bool(v.king),
|
||||
queened=bool(v.queen),
|
||||
sharpened=bool(v.sharpen),
|
||||
)
|
||||
|
|
|
@ -0,0 +1,6 @@
|
|||
alter table users add column king integer;
|
||||
|
||||
alter table posts add column golden bool not null default false;
|
||||
alter table posts alter column golden drop default;
|
||||
alter table comments add column golden bool not null default false;
|
||||
alter table comments alter column golden drop default;
|
Loading…
Reference in New Issue