alexboy 11 Posted August 15, 2015 Hey guys, I am back at it for sometime in programming the C-ram. I been working hard on this coding, but i need some help with one issue of coding. What I am trying to do is make a config that lets someone Tab- lock on to a target, just like if you had an AA gun - you press TAB and a white box goes around an air craft then it locks on when you are aiming in the direction of the target. also you can do this with machineguns (so that the zeroing is automatic and not manual), I am trying to make a target to be lock on able, so that it does automatic zeroing when aiming at it. right now my C-ram can "auto-zero" into aircraft since it can lock on to it and the zeroing adjusts so that the c-ram bullets hits the target while aiming at it, rather then the bullets ending up missing the target. =============================== EDIT ============================== Right now I can Tab-target aircraft with my c-ram so that it can auto-zero the turret so that the bullets can hit the target at far distances I am trying to be able to do that but with the target i make below Target code: class at_phalanx_target_base: TargetBase { class EventHandlers; }; class at_phalanx_target: at_phalanx_target_base //take out gps { model = "at_phalanx\at_phalanx_target"; displayName = "gun RAM TARGET"; _generalMacro = "at_phalanx_target"; // irTarget = 1; //side = 0; //hasdriver = 1; irLock = true; laserLock = true; nameSound = ""; // threat (VSoft, VArmor, VAir), how threatening vehicle is to unit types threat[] = {0.0, 0.0, 1.0}; //simulation = "artillerymarker"; //simulation = "nvmarker"; laserTarget = true; irTarget = true; nvTarget = 0; //artilleryTarget = true; type = VAir;//added vehicleClass = "Air"; side = TEast; //scope = protected; //laserTarget = 1; armor = 15; scope = 2; cost =10000000; //vehicleClass = "Static"; }; if anyone can help me, i will be very thankful. I been at just this point for a couple of days and i just feel like im missing something simple, and I am looking toward the community for some help Thank you in advance! alexboy Share this post Link to post Share on other sites
alexboy 11 Posted August 17, 2015 Update - I have figured out how to do this laserLock = 1; just forgot the stupid define variable.: #define false 0 #define true 1 I got another issue I ran into - I cannot figure out the way to force an ai to (Tab target) or lock onto said laser . lets say I have a aircraft with a scripted laser on the ground, how do i make the aircraft ai lock onto that laser, i know how to make him aim and fire, just not how to force the ai to lock onto it with tab lock so that the auto zeroing takes place Share this post Link to post Share on other sites