Skip to content

Commit 335d949

Browse files
Fix more things that shouldn't be antags from rolling antags (#5878)
## Short description Cheese you're going to be the death of me. ## Why we need to add this pAIs cannot do objectives. ## Checks - [X] I do not require assistance to complete the PR. - [X] Before posting/requesting review of a PR, I have verified that the changes work. - [X] I have added screenshots/videos of the changes, or this PR does not change in-game mechanics. - [X] I affirm that my changes are licensed under the [MIT License](https://github.com/ss14Starlight/space-station-14/blob/Starlight/LICENSE.TXT) and grant permission for use in this repository under its conditions. **Changelog** :cl: wonderfulnewworld - fix: pAIs/clothes/trunks can no longer roll antags. - fix: Terror Spiders, Xenoborgs, and some other things are no longer crew aligned.
1 parent 59dbca5 commit 335d949

15 files changed

Lines changed: 38 additions & 20 deletions

File tree

Content.Server/Antag/AntagSelectionSystem.API.Assignment.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -210,7 +210,7 @@ public bool IsEntityValid(ICommonSession session, AntagSpecifierPrototype def)
210210
}
211211

212212
/// <inhereitdoc cref="IsEntityValid(EntityUid?,AntagSpecifierPrototype)"/>
213-
public bool IsEntityValid([NotNullWhen(true)] EntityUid? uid, ProtoId<AntagSpecifierPrototype> def)
213+
public bool IsEntityValid(EntityUid? uid, ProtoId<AntagSpecifierPrototype> def) // Starlight
214214
{
215215
if (!Proto.Resolve(def, out var antag))
216216
return false;
@@ -225,7 +225,7 @@ public bool IsEntityValid([NotNullWhen(true)] EntityUid? uid, ProtoId<AntagSpeci
225225
/// <param name="uid">Entity whose validity we're checking.</param>
226226
/// <param name="def">Antag definition we want to give them.</param>
227227
/// <returns>True if there is nothing stopping this entity from being this antag. Or if there is no entity.</returns>
228-
public bool IsEntityValid([NotNullWhen(true)] EntityUid? uid, AntagSpecifierPrototype def)
228+
public bool IsEntityValid(EntityUid? uid, AntagSpecifierPrototype def) // Starlight
229229
{
230230
// If the player has not spawned in as any entity (e.g., in the lobby), they can be given an antag role/entity.
231231
if (!_whitelist.CheckBoth(uid, def.Blacklist, def.Whitelist))
@@ -239,7 +239,7 @@ public bool IsEntityValid([NotNullWhen(true)] EntityUid? uid, AntagSpecifierProt
239239
if (HasComp<GhostComponent>(uid))
240240
return false;
241241

242-
if (!def.AllowNonHumans && !HasComp<HumanoidAppearanceComponent>(uid) && !HasComp<HandsComponent>(uid)) // Starlight, no visual nubody
242+
if (!HasComp<HumanoidAppearanceComponent>(uid) && (!def.AllowNonHumans || !HasComp<HandsComponent>(uid))) // Starlight, Cheese, you have sent me down the path of the hell trying to get this working reliably
243243
return false;
244244

245245
return true;

Resources/Prototypes/Entities/Mobs/Player/guardian.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -113,6 +113,7 @@
113113
- CannotSuicide
114114
- StunImmune
115115
- SlowImmune
116+
- type: AntagImmune # Starlight
116117

117118
# From the uplink injector
118119
- type: entity

Resources/Prototypes/Entities/Mobs/Player/silicon.yml

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -647,6 +647,7 @@
647647
name: ghost-role-information-syndicate-cyborg-assault-name
648648
description: ghost-role-information-syndicate-cyborg-description
649649
rules: ghost-role-information-silicon-rules
650+
mindRoles: [MindRoleGhostRoleSiliconAntagonist] # Starlight
650651
important: true # SL
651652
raffle:
652653
settings: default
@@ -700,6 +701,7 @@
700701
name: ghost-role-information-syndicate-cyborg-saboteur-name
701702
description: ghost-role-information-syndicate-cyborg-description
702703
rules: ghost-role-information-silicon-rules
704+
mindRoles: [MindRoleGhostRoleSiliconAntagonist] # Starlight
703705
important: true # SL
704706
raffle:
705707
settings: default
@@ -761,6 +763,7 @@
761763
name: ghost-role-information-derelict-engineering-cyborg-name
762764
description: ghost-role-information-derelict-engineering-cyborg-description
763765
rules: ghost-role-information-silicon-rules
766+
mindRoles: [MindRoleSubvertedSilicon] # Starlight
764767
raffle:
765768
settings: default
766769
reregister: false
@@ -802,6 +805,7 @@
802805
name: ghost-role-information-derelict-cyborg-name
803806
description: ghost-role-information-derelict-cyborg-description
804807
rules: ghost-role-information-silicon-rules
808+
mindRoles: [MindRoleSubvertedSilicon] # Starlight
805809
raffle:
806810
settings: default
807811
reregister: false
@@ -845,6 +849,7 @@
845849
name: ghost-role-information-derelict-janitor-cyborg-name
846850
description: ghost-role-information-derelict-janitor-cyborg-description
847851
rules: ghost-role-information-silicon-rules
852+
mindRoles: [MindRoleSubvertedSilicon] # Starlight
848853
raffle:
849854
settings: default
850855
reregister: false
@@ -889,6 +894,7 @@
889894
name: ghost-role-information-derelict-medical-cyborg-name
890895
description: ghost-role-information-derelict-medical-cyborg-description
891896
rules: ghost-role-information-silicon-rules
897+
mindRoles: [MindRoleSubvertedSilicon] # Starlight
892898
raffle:
893899
settings: default
894900
reregister: false
@@ -932,6 +938,7 @@
932938
name: ghost-role-information-derelict-mining-cyborg-name
933939
description: ghost-role-information-derelict-mining-cyborg-description
934940
rules: ghost-role-information-silicon-rules
941+
mindRoles: [MindRoleSubvertedSilicon] # Starlight
935942
raffle:
936943
settings: default
937944
reregister: false
@@ -974,6 +981,7 @@
974981
name: ghost-role-information-derelict-syndicate-assault-cyborg-name
975982
description: ghost-role-information-derelict-syndicate-assault-cyborg-description
976983
rules: ghost-role-information-silicon-rules
984+
mindRoles: [MindRoleSubvertedSilicon] # Starlight
977985
raffle:
978986
settings: default
979987
reregister: false

Resources/Prototypes/Entities/Objects/Devices/Syndicate_Gadgets/reinforcement_teleporter.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@
117117
rules: ghost-role-information-silicon-rules
118118
important: true # SL
119119
mindRoles:
120-
- MindRoleGhostRoleSilicon
120+
- MindRoleGhostRoleSiliconAntagonist # Starlight
121121
raffle:
122122
settings: default
123123
job: Borg

Resources/Prototypes/Entities/Objects/Fun/pai.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,7 @@
121121
- type: Blindable
122122
- type: ParentCanBlockVision
123123
- type: ContentEye
124+
- type: AntagImmune
124125
# Starlight End
125126

126127
- type: entity

Resources/Prototypes/_Starlight/Entities/Clothing/Back/trunks.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -90,4 +90,5 @@
9090
baseSprintSpeed: 0
9191
- type: TextToSpeech
9292
voice: karma
93+
- type: AntagImmune
9394
# Fashion-O-Mat END

Resources/Prototypes/_Starlight/Entities/Clothing/Neck/cloaks.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -300,6 +300,7 @@
300300
sprite: _Starlight/Clothing/Neck/Ties/disco.rsi
301301
- type: Clothing
302302
sprite: _Starlight/Clothing/Neck/Ties/disco.rsi
303+
- type: AntagImmune
303304

304305
- type: entity
305306
parent: ClothingNeckBase

Resources/Prototypes/_Starlight/Entities/Markers/Spawners/ghost_roles.yml

Lines changed: 6 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,7 @@
77
name: ghost-role-information-derelict-borgi-name
88
description: ghost-role-information-derelict-borgi-desc
99
rules: ghost-role-information-silicon-rules
10-
mindRoles:
11-
- MindRoleSubvertedSilicon
10+
mindRoles: [MindRoleSubvertedSilicon]
1211
raffle:
1312
settings: default
1413
- type: Sprite
@@ -29,8 +28,7 @@
2928
important: true
3029
name: roles-antag-brighteye-name
3130
description: roles-antag-brighteye-description
32-
mindRoles:
33-
- MindRoleBrighteye
31+
mindRoles: [MindRoleBrighteye]
3432
raffle:
3533
settings: default
3634
- type: Sprite
@@ -51,8 +49,7 @@
5149
name: ghost-role-information-terminator-name
5250
description: ghost-role-information-terminator-description
5351
rules: ghost-role-information-terminator-rules
54-
mindRoles:
55-
- MindRoleTerminator
52+
mindRoles: [MindRoleTerminator]
5653
raffle:
5754
settings: default
5855
- type: Sprite
@@ -143,8 +140,7 @@
143140
description: ghost-role-information-terror-princess-description
144141
rules: ghost-role-information-rules-team-antagonist
145142
important: true
146-
mindRoles:
147-
- MindRoleTerrorPrincess
143+
mindRoles: [MindRoleTerrorPrincess]
148144
- type: Sprite
149145
layers:
150146
- state: green
@@ -161,8 +157,7 @@
161157
name: ghost-role-information-xenoroach-name
162158
description: ghost-role-information-xenoroach-description
163159
rules: ghost-role-information-silicon-rules
164-
mindRoles:
165-
- MindRoleXenoborg
160+
mindRoles: [MindRoleXenoborg]
166161
raffle:
167162
settings: default
168163
- type: GhostRoleMobSpawner
@@ -184,6 +179,7 @@
184179
name: Cluwne Beast
185180
description: Spread laughter and chaos by hitting and turning the crew into cluwnes.
186181
rules: You are an antagonist, transform as many of the crew as you can into cluwnes.
182+
mindRoles: [MindRoleGhostRoleSoloAntagonist]
187183
- type: GhostRoleMobSpawner
188184
prototype: MobCluwneBeast
189185
- type: Sprite

Resources/Prototypes/_Starlight/Entities/Mobs/Cyborgs/base_borgi_chassis.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -250,6 +250,7 @@
250250
name: A Syndicate Borgi.
251251
description: The Syndicate needs reinforcements. You, a cold, BUT LOVINGLY ADORABLE, silicon killing machine, will help them... And bork. An unusual choice, but it was made nonetheless.
252252
rules: ghost-role-information-silicon-rules
253+
mindRoles: [MindRoleGhostRoleSiliconAntagonist]
253254
important: true # SL
254255
raffle:
255256
settings: default

Resources/Prototypes/_Starlight/Entities/Mobs/Cyborgs/borgi_chassis.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -278,6 +278,7 @@
278278
name: XenoBorgi
279279
description: Your job is to assist the mothership with their duties with your pair of hands. You of inferior flesh have a job to do.
280280
rules: Check your laws upon being fitted to your chassis. You are a team antagonist, and your goal is to kill everyone you can on the station, bring them back to your ship, gib them, and borg them. Exercise prudence about your targetting as you are made of flesh, and therefore feeble.
281+
mindRoles: [MindRoleXenoborg]
281282
important: true # SL
282283
raffle:
283284
settings: default

0 commit comments

Comments
 (0)