Replaced c style cast with static_cast and fixed generate script
This commit is contained in:
@@ -21,7 +21,7 @@ namespace generated {
|
||||
}));
|
||||
|
||||
component.set_function("_convert", [] (ecs::Component* component) {
|
||||
return (Position*)component;
|
||||
return static_cast<Position*>(component);
|
||||
});
|
||||
|
||||
return component;
|
||||
@@ -41,7 +41,7 @@ namespace generated {
|
||||
}));
|
||||
|
||||
component.set_function("_convert", [] (ecs::Component* component) {
|
||||
return (Velocity*)component;
|
||||
return static_cast<Velocity*>(component);
|
||||
});
|
||||
|
||||
return component;
|
||||
@@ -61,7 +61,7 @@ namespace generated {
|
||||
}));
|
||||
|
||||
component.set_function("_convert", [] (ecs::Component* component) {
|
||||
return (Meta*)component;
|
||||
return static_cast<Meta*>(component);
|
||||
});
|
||||
|
||||
return component;
|
||||
|
||||
Reference in New Issue
Block a user