
Originally Posted by
balihr
Yes, and this is exactly the interesting part where you get some fun.
As lat9 mentioned, it has nothing to do with OPC. Qty check and subtraction happens during checkout_process (includes/modules/checkout_process.php), or includes/classes/order.php to be exact. I'd use the notifier mentioned earlier, but you might prefer the ones found in create_add_products() function. Or just modify that function if you're happy with modifying core file, although the observer approach helps during upgrades and maintenance.
Your observer (or hack) could then update qty1 and qt2 based on your custom logic (you'll need to come up with that, sorry), and Zen Cart will process the main quantity anyway. If you're not updating qty1 and qty2 from anywhere else, products_quantity will always match qty1+qty2.