Files
wwdpublic/Content.Shared/Traits/Assorted/Systems/AccentlessSystem.cs
DEATHB4DEFEAT d3ed34ff4e Trait Points (#434)
# Description

Some improvements to loadouts too.

---

# TODO

- [x] Points logic
- [x] Server-side validation
- [x] Categorize traits
- [x] Assign points to traits
- [x] Header costs
- [x] Sort entries
- [x] Max traits
	- [x] Communicate max traits
- [x] Point bar
- [x] Group exclusivity
- Black outline on text
- [x] Fix existing component whitelists

---

<details><summary><h1>Media</h1></summary>
<p>

## Accurate except for small details


![image](https://github.com/Simple-Station/Einstein-Engines/assets/77995199/c0ab2fbf-3bce-4e54-81d5-8e546d6b3c0b)

### Something to note:


![image](https://github.com/Simple-Station/Einstein-Engines/assets/77995199/09a3948e-0c9f-4f57-b297-f62063b11845)


![image](https://github.com/Simple-Station/Einstein-Engines/assets/77995199/35d76095-0714-4613-a17b-73df25a9a832)


![image](https://github.com/Simple-Station/Einstein-Engines/assets/77995199/87149e5c-0af2-4ac0-bbde-52f317a008a0)

</p>
</details>

---

# Changelog

🆑
- add: Added trait points
- add: Added categories for traits

---------

Co-authored-by: VMSolidus <evilexecutive@gmail.com>
2024-06-20 19:39:30 -04:00

25 lines
710 B
C#

namespace Content.Shared.Traits.Assorted.Systems;
/// <summary>
/// This handles removing accents when using the accentless trait.
/// </summary>
public sealed class AccentlessSystem : EntitySystem
{
/// <inheritdoc/>
public override void Initialize()
{
base.Initialize();
SubscribeLocalEvent<Components.AccentlessComponent, ComponentStartup>(RemoveAccents);
}
private void RemoveAccents(EntityUid uid, Components.AccentlessComponent component, ComponentStartup args)
{
foreach (var accent in component.RemovedAccents.Values)
{
var accentComponent = accent.Component;
RemComp(uid, accentComponent.GetType());
}
}
}