-
Notifications
You must be signed in to change notification settings - Fork 121
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Missile_SetTarget #287
Comments
yes I support the above said. Missile guidance is not supported |
Any new info on the issue? Thx. Thus far, I think its the only real issue that affects the mod since the ability is needed in a few places. |
beginReaperTargeting() {
self endon("death");
self endon("disconnect");
self endon("reaper_done");
level endon("game_ended");
locator = spawn("script_model", self.origin + (0, 0, 32));
locator setModel("tag_origin");
locator.angles = (-90, 0, 0);
locator hide();
locator showtoplayer(self);
self thread visualLocatorScan(locator);
self thread watchForDeath(locator);
wait 0.1;
self thread reaperTimer(level.scr_reaper_timer);
rounds = level.scr_reaper_maxrounds;
self enableWeapons();
while (rounds > 0) {
self SetWeaponAmmoClip("radar_mp", 1);
self waittill("weapon_fired");
rocketArray = GetEntArray("rocket", "classname");
closestRocket = undefined;
range = (5000 * 5000);
for (i = 0; i < rocketArray.size; i++) {
d = distancesquared(self.origin, rocketArray[i].origin);
if (d < range) {
range = d;
closestRocket = rocketArray[i];
}
}
if (!isDefined(closestRocket))
continue;
closestRocket Missile_SetTarget(locator, (0, 0, 0));
closestRocket waittill("death");
rounds--;
}
self notify("stop_timer");
self notify("reaper_done");
}
watchForDeath(locator) {
self waittill_any("reaper_done", "death", "disconnect", "game_ended");
level.airstrikeInProgress = undefined;
safe_delete(locator);
} |
It seems that the rocket control function itself does not work (locator) |
The locator is fine. Missile_SetTarget itself does not work correctly. The function above is from OW2 and works as expected in regular cod4. But the same mod files with no alterations has the above behavior in cod4x. |
Some strange behavior using Missile_SetTarget() on a player fired projectile/rocket. Instead of going in a straight-ish line to the target, taking curvature into account, it travels up/down/up in a wave.
The text was updated successfully, but these errors were encountered: