Anonymous Login
2021-10-24 20:17 UTC

View Issue Details Jump to Notes ]
IDProjectCategoryView StatusLast Update
0001995OpenClonkEnginepublic2018-02-17 19:55
Assigned To 
PlatformPCOSWindowsOS Version10
Product Version 
Target Version9.0Fixed in Version 
Summary0001995: CreateObject() does not distinguish between objects and ids
DescriptionIt is possible to pass an object for an id in CreateObject(). There is no warning or error message.

The created object has the passed object as prototype and will horrible break the game as soon as the mother object gets destroyed.
Steps To ReproduceSelect any object and call CreateObject(this);
TagsNo tags attached.
Attached Files




Luchs (administrator)

Should we disallow using objects in CreateObject()? Print a warning? Or remove child objects after the parent object is removed? Or change the child's prototype to the parent object's prototype?

I wonder whether there is any useful application for this.


Clonkonaut (developer)

I would suggest disallowing it and print a warning (the standard warning when providing a value of a wrong data type). I don't see any feasible application.

-Issue History
Date Modified Username Field Change
2018-02-11 17:48 Clonkonaut New Issue
2018-02-17 17:10 Luchs Note Added: 0006145
2018-02-17 19:55 Clonkonaut Note Added: 0006146
+Issue History