Jump to content

Coffee Shock

Members
  • Posts

    35
  • Joined

  • Last visited

Everything posted by Coffee Shock

  1. The message type for some nuke related messages in my war log are wrong or missing. Missing: Wrong: War log: http://www.cybernations.net/war_information.asp?ID=772852
  2. I know that. In my case all my nukes were thwarted and the target have the FSS.
  3. I have 99% battle odds, have not successfully nuked today and I am the only one fighting but still no defeat alert.
  4. [quote name='Provost Zakharov' timestamp='1296388773' post='2611028'] If you're interested in reducing the complexity of the search from 360*180 evaluations down to a much smaller number, you can compute a continuous approximation to the discrete problem as your initial guess, then just examine a small number of points around that. Of course it's not really necessary with fast computers, but perhaps you find it mathematically interesting. [/quote] There is a much easier way to reduce the number of possible hotspot locations as they aren’t as random as you may think. Hint: Plot all hotspots found so far. My hotspot finding code, maybe it’s of some use to someone. [code] struct pos_t { double lat; double lng; int efficacy; } static const pos_data[] = { //Moon 2010-11 {70.00000002, 7, 50}, {19.31114335506464, -81.5625, 50}, {-37.16031654673676, -101.25, 55}, {17.978733095556155, 113.5546875, 50}, {30.14512718337613, 146.953125, 58}, {-9, -161, 93}, {-34, 145, 67}, {-12, -19, 50}, {-17, -173, 96}, {37.71859032558813, -129.375, 56}, }; static int calc_efficacy(double h_lat, double h_lng, double base_lat, double base_lng){ const double pi = 3.14159265358979323846264338327950288; const double deg2rad = pi / 180; const double magic_constant = 39.5856603902019127; //pi*12.6 ??? double h_lat_rad = h_lat * deg2rad; double h_long_rad = h_lng * deg2rad; double base_lat_rad = base_lat * deg2rad; double base_long_rad = base_lng * deg2rad; double distance = acos(sin(base_lat_rad) * sin(h_lat_rad) + cos(base_lat_rad) * cos(h_lat_rad) * cos(h_long_rad - base_long_rad)); return std::max(int(100 - distance * magic_constant), 50); } void moon_mars_find_hotspot(){ const int num_data_points = sizeof(pos_data) / sizeof(pos_data[0]); std::vector<pos_t> scores; for(int lat = -85; lat <= 85; lat++){ for(int lng = -180; lng <= 180; lng++){ int diff_sum = 0; for(int i = 0; i < num_data_points; i++){ int efficacy = calc_efficacy(lat, lng, pos_data[i].lat, pos_data[i].lng); diff_sum += std::abs(efficacy - pos_data[i].efficacy); } pos_t tmp_pos = {lat, lng, diff_sum}; scores.push_back(tmp_pos); } } int num_to_print = 30; int num_possible_hotspots = 0; std::vector<pos_t>::iterator it = scores.begin(); for(; it != scores.end(); ++it){ if(it->efficacy == 0){ num_possible_hotspots++; if(num_to_print >= num_possible_hotspots){ bool tilt = calc_efficacy(it->lat, it->lng, it->lat, it->lng) != 100; std::cout<<"lat="<<std::setw(5)<<it->lat<<(tilt ? "*" : " ")<<" lng="<<std::setw(5)<<it->lng<<std::endl; } } } std::cout<<"Possible hotspots: "<<num_possible_hotspots<<std::endl; } [/code]
  5. [img]http://img836.imageshack.us/img836/5909/aircraftupkeep.png[/img] Should be "lowers aircraft upkeep cost -25%" according to the information index.
  6. Why do we need a fancy name? I have not heard anyone call this war anything other than the NpO-\m/ War. It fit perfectly considering how it started and ended so I vote to keep calling it the NpO-\m/ War.
  7. Aluminum - Coal - Gold - Iron - http://www.cybernations.net/nation_drill_d...ation_ID=166016 Lead - Lumber - Marble - Oil - Pigs - Uranium - Water - http://www.cybernations.net/nation_drill_d...ation_ID=166016 Wheat - Bonus Resources: Beer Construction Microchips Radiation Cleanup Scholars Steel
  8. There was nothing wrong in your calculations but it was not a pure math problem. The hotspot is {-71, 67} but instead of making it a special case the game calculates the distance and any distance greater than zero is rounded down to 99%. In this case floating-point accuracy makes the distance non-zero even when the moon facility is exactly on the hotspot. I calculated the error from the correct position so that the distance calculation gives exactly zero.
  9. I tried and the spot I calculated do give 100% effectiveness. Zakharov is not completely wrong but he missed an important detail.
  10. Test this spot: Lon= 67 Lat= -70.99999991
  11. I will send you 3 million now, and then you send me 50 tech once it expires and another 50 once that expires. My nation: http://www.cybernations.net/nation_drill_d...ation_ID=166016
  12. moon radius in yards = 1899606 distance to hotspot in yards = ARCCOS(SIN(base_lat*PI/180)*SIN(hotspot_lat*PI/180)+COS(base_lat*PI/180)*COS(hotspot_lat*PI/180)*COS((hotspot_lon*PI/180)-(base_lon*PI/180))) * moon radius in yards efficiency = ROUNDDOWN((1 - (distance to hotspot in yards / 4000000)) * 100) B)
  13. This seems to work for me. moon diameter = 3474 efficiency = max((1 - (distance to hot spot / moon diameter)) * 100, 50) That gives: for efficiency > 50 distance to hot spot = (1 - (efficiency / 100)) * moon diameter Now it's easy to find the hot spot from three coordinates with trilateration. B) Edit: Incorrectly placed parentheses.
  14. I will send you 3 million now, and then you send me 50 tech once it expires and another 50 once that expires. http://www.cybernations.net/nation_drill_d...ation_ID=166016
  15. 1 infra level gives 7.5 citizens before population modifiers.
  16. Please don't add a spy op to discover who is sending secret aid. The whole idea of secret aid is to enable you to send aid in situations that would otherwise get you in trouble when sending aid, covertly breaking surrender terms supporting guerilla movements like Vox and similar. With the risk of discovery nobody will actually use secret aid just like nobody uses the regular spy ops in peacetime.
  17. Please don't add a spy op to discover who is sending secret aid. The whole idea of secret aid is to enable you to send aid in situations that would otherwise get you in trouble when sending aid, covertly breaking surrender terms supporting guerilla movements like Vox and similar. With the risk of discovery nobody will actually use secret aid just like nobody uses the regular spy ops in peacetime.
  18. Witness the fulfillment of a prophecy: The Great War. No matter how you may struggle, our plan will be completed in order to open the next door.
  19. Witness the fulfillment of a prophecy: The Great War. No matter how you may struggle, our plan will be completed in order to open the next door.
  20. The Hegemony vs Karma Easily the best name proposed so far.
  21. Read Improvements Missile Defense, Technology point 6 (damage bonus) and wonders Weapons Research Complex.
  22. Wow, you challenged twisted to a duel without knowing the basics of the combat system. The line between bravery and stupidity is indeed thin.
  23. I will send you 3 million now, and then you send me 50 tech once it expires and another 50 once that expires. http://www.cybernations.net/nation_drill_d...ation_ID=166016
  24. I don’t see any good reasons to keep the land purchase cost secret. Land Purchase Cost: 0 - 19.99 = 0.0 * Purchased Land area + 400 20 - 29.99 = 1.50 * Purchased Land area + 400 30 - 59.99 = 2.00 * Purchased Land area + 400 60 - 99.99 = 2.50 * Purchased Land area + 400 100 - 149.99 = 3.00 * Purchased Land area + 400 150 - 199.99 = 3.50 * Purchased Land area + 400 200 - 249.99 = 5.00 * Purchased Land area + 400 250 - 299.99 = 10.00 * Purchased Land area + 400 300 - 399.99 = 15.00 * Purchased Land area + 400 400 - 499.99 = 20.00 * Purchased Land area + 400 500 - 799.99 = 25.00 * Purchased Land area + 400 800 - 1199.99 = 30.00 * Purchased Land area + 400 1200 - 1999.99 = 35.00 * Purchased Land area + 400 2000 - 2999.99 = 40.00 * Purchased Land area + 400 3000 - 3999.99 = 45.00 * Purchased Land area + 400 4000 - 7999.99 = 55.00 * Purchased Land area + 400 8000 - ????? = 75.00 * Purchased Land area + 400
×
×
  • Create New...