Not too much trouble but...
First we alter the xcart_orders table and add a new field named 'ip'. I did this with phpMyAdmin. Simply copy paste the code snippet into the SQL query box.
Next we open include/func.php, locate the func_place_order(); function, in my 3.2.2pro code its on line 1017.
Code:
#
# Insert into orders
#
db_query("insert into $sql_tbl[orders] (login, total, subtotal, shipping_cost, shippingid, tax, discount, coupon, coupon_discount, date, status, payment_method, flag, details, title, firstname, lastname, company, b_address, b_city, b_state, b_country, b_zipcode, s_address, s_city, s_state, s_country, s_zipcode, phone, fax, email, url, ip) values ('".addslashes($userinfo["login"])."', '$current_order[total_cost]', '$current_order[sub_total]','$current_order[shipping_cost]', '$cart[shippingid]', '$current_order[tax_cost]', '$current_order[discount]', '".addslashes($current_order[coupon])."', '$current_order[coupon_discount]', '".time()."', '$order_status', '".addslashes($payment_method)."', 'N', '".addslashes(text_crypt($order_details))."', '".addslashes($userinfo["title"])."', '".addslashes($userinfo["firstname"])."', '".addslashes($userinfo["lastname"])."', '".addslashes($userinfo["company"])."', '".addslashes($userinfo["b_address"])."', '".addslashes($userinfo["b_city"])."', '".addslashes($userinfo["b_state"])."', '".addslashes($userinfo["b_country"])."', '".addslashes($userinfo["b_zipcode"])."', '".addslashes($userinfo["s_address"])."', '".addslashes($userinfo["s_city"])."', '".addslashes($userinfo["s_state"])."', '".addslashes($userinfo["s_country"])."', '".addslashes($userinfo["s_zipcode"])."', '".addslashes($userinfo["phone"])."', '".addslashes($userinfo["fax"])."', '$userinfo[email]', '".addslashes($userinfo["url"])."','$_SERVER[REMOTE_ADDR]')");
Replace the db_query(); with this one. Note the $_SERVER[REMOTE_ADDR] at the end of the query storing the users remote IP.
Edit [skin1]/main/order_info.tpl add the following where ever you want the IP of the order displayed, I put mine under the email.
Please make a donation if you find this useful.