Skip to content

Add the Ent value to the table so that it deletes the entity if it does not have#300

Closed
Vitroze wants to merge 1 commit into
StyledStrike:mainfrom
Vitroze:safe_vehiclefactory
Closed

Add the Ent value to the table so that it deletes the entity if it does not have#300
Vitroze wants to merge 1 commit into
StyledStrike:mainfrom
Vitroze:safe_vehiclefactory

Conversation

@Vitroze

@Vitroze Vitroze commented Jun 4, 2026

Copy link
Copy Markdown
Contributor

Normally, this situation should almost never happen. But I’d rather add an extra safety measure just in case it does.

@StyledStrike

Copy link
Copy Markdown
Owner

Is there ever a situation where something calls ENT:SpawnFunction on an already existing entity?

Because if not, self in there is always going to be the ENT table, not a valid entity that exists in the world, which means that entity:IsValid does not exist, so IsValid always returns false.

@Vitroze

Vitroze commented Jun 4, 2026

Copy link
Copy Markdown
Contributor Author

Hmm, I'm thinking about it, and indeed. I don't see any specific case (apart from implementing a module) that would allow self to convert into an entity at that stage. Therefore, this PR is unnecessary.

@Vitroze Vitroze closed this Jun 4, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants