LaunchLightning: fixed GetType check

The comparison with C4D_Object was taken from the original PR (github #61). C4D_Object is the category, though.
install-platforms
David Dormagen 2017-12-27 16:10:56 +01:00
parent d108cdd6aa
commit ca16ffdd20
1 changed files with 1 additions and 1 deletions

View File

@ -24,7 +24,7 @@ global func LaunchLightning(int x, int y, int strength, int xdir, int ydir, int
var lightning = CreateObject(Lightning, x - GetX(), y - GetY());
// Ignore the launching object if not called from effect, scenario, etc..
var launching_object = nil;
if (this && GetType(this) == C4D_Object)
if (this && GetType(this) == C4V_C4Object)
launching_object = this;
return lightning && lightning->Launch(x, y, strength, xdir, ydir, xdev, ydev, no_sound, launching_object);
}