mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2024-11-21 21:17:25 +00:00
Merge pull request #1487 from DarkflameUniverse/voidptr
fix: remove void*
This commit is contained in:
commit
7d626dc31b
@ -841,11 +841,9 @@ bool Entity::HasComponent(const eReplicaComponentType componentId) const {
|
||||
|
||||
std::vector<ScriptComponent*> Entity::GetScriptComponents() {
|
||||
std::vector<ScriptComponent*> comps;
|
||||
for (std::pair<eReplicaComponentType, void*> p : m_Components) {
|
||||
if (p.first == eReplicaComponentType::SCRIPT) {
|
||||
comps.push_back(static_cast<ScriptComponent*>(p.second));
|
||||
}
|
||||
}
|
||||
|
||||
auto* scriptComponent = GetComponent<ScriptComponent>();
|
||||
if (scriptComponent) comps.push_back(scriptComponent);
|
||||
|
||||
return comps;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user