# Investigation

Investigations is an advanced staff feature in SporeCore designed for handling complex cases that require tracking multiple players, reports, notes, and punishments in one place.

An investigation acts as a central workspace where staff can collect evidence, link related actions, and keep a clear audit trail of everything that happened.

***

## 🚀 Starting an Investigation

Staff can create a new investigation using:

```
/investigation start <name> <priority>
```

#### 🔹 Priorities

Each investigation has a priority level to help staff organize their workload:

* **HIGH** – Urgent or serious cases
* **NORMAL** – Standard investigations
* **LOW** – Minor or informational cases

Once created, the investigation is marked as **In Progress** and opens the management menu automatically.

***

## 📂 Investigation Contents

Each investigation can contain multiple types of linked information.

#### 📝 Notes

Notes are used to document findings, staff thoughts, or important details.

* Notes store:
  * Title
  * Full text
  * Author
  * Timestamp
* Notes can be added and removed at any time.
* Every note action is logged in the investigation logs.

***

## 📣 Linked Reports

Reports can be attached to an investigation to give context or show player history.

* Only existing reports can be linked.
* Reports can also be removed if they’re no longer relevant.
* Report actions are tracked in the logs.
* Requires the Reports feature to be enabled.

This is especially useful when multiple reports are related to the same situation.

***

## ⚖️ Linked Punishments

Punishments can be linked to an investigation to show what action was taken as a result.

* Supports all punishment types.
* Prevents the same punishment from being linked twice.
* Punishment lookup is done by punishment ID.
* Requires the Punishments feature to be enabled.

This helps keep a clear record of **why** a punishment happened.

***

## 👤 Suspects

Suspects represent players involved in the investigation.

* Suspects must be known players who have joined the server before.
* Each suspect includes:
  * Player
  * Description
  * Who added them
  * Timestamp
* Suspects can be added or removed freely.
* All changes are logged.

This allows staff to track multiple involved players in one case.

***

## 🧑‍⚖️ Staff & Admin

Investigations support staff roles internally:

* **Admin** – Investigation creators and administrators
* **Staff** – Assigned staff members

These roles control who can manage and interact with the investigation.

***

## 📜 Investigation Logs

Every important action inside an investigation is automatically logged.

#### 🔹 Logged Actions Include:

* Investigation creation
* Notes added or removed
* Reports linked or removed
* Punishments linked or removed
* Suspects added or removed
* Staff-related actions

Each log entry contains:

* Staff member
* Action description
* Timestamp
* Action type

### 🔹 Log Types

Logs are grouped by type for easier filtering:

* Started
* Staff
* Note
* Report
* Punishment
* Suspect
* All

This ensures full transparency and makes reviewing past decisions easy.

***

## 🔍 Why Use Investigations?

Investigations are ideal for:

* Complex rule-breaking cases
* Tracking repeat offenders
* Staff collaboration
* Appeal reviews
* Internal documentation

Instead of relying on memory or scattered messages, everything stays organized in one place.
