Jump to content
Game-Labs Forum


  • Content Count

  • Joined

  • Last visited

Posts posted by Svartschegg

  1. The only ones that cannot be captured are capitals AFAIK, so you should be safe to do something along these lines:


      console.log('It cannot be captured.');
      console.log('It can be captured '+ translateCaptureWindow(port.timeslot));
    function translateCaptureWindow(baseWindow) {
      var padLeft = function(inpt) {
        var str = "" + inpt;
        var pad = "00";
        return pad.substring(0, pad.length - str.length) + str;
      if(baseWindow == -1)
        return 'anytime';
      else {
        baseWindow = parseInt(baseWindow);
        return 'between '+ padLeft(baseWindow) +' and '+ padLeft(parseInt(baseWindow+2)) +' UTC';

  2. A couple of questions about the ConquestFlagTimeSlot attribute:


    * ConquestFlagTimeSlot == -1 when the port is not susceptible to capture (a capital or free town), though there are some ports that have -1 anyway.  Does -1 also indicate cases where the capturer forget to set the Conquest Time Slot?


    * How is the "can't be bought from N to M" time window (shown in game) determined?  Is there a rule?



    ConquestFlagTimeSlot is -1 when the capture window is "anytime", otherwise it indicates the starting hour of a 2-hour window in the UTC timezone.


    "Cant be bought" <- Referring to conquest flags? They all have the same cant-be-bought window, which is basically the hours surrounding the server maintenance time window.

  3. Ah, right.


    You should be able to calculate that based on the attributes found in the item model. I'd imagine the properties BasePrice, SellPrice and SellPriceCoefficient are the properties that affect this.. In the old trading system I suppose PriceTierQuantity also would've mattered.


    If you don't feel like experimenting with figuring out the formula there's a simpler way, with the new trading system: Look at a port that consumes the product and does not have any on a contract - the price will be the same in any port that consumes that product. Save that value in an item model of your choice and reference it from your port model.

  4. If I am understanding it correctly a resource that has nothing in either the sell or buy. (there is none of that resource in the port). does not show up in the api. That means if the port is a resource sell that information is also lost to the api.


    An example. I know the port of Les Cayes is an iron ore sell, but that fact does not show up on the pvp2 api, because there is no iron ore in the port. If I make a tool which says, I have a resource, where can I sell it?, then I get incorrect information from the api, because some of the sell ports are not visible. Is it possible to do something about this?

    You can still see which resources a port consumes and produces, so as long as you go by that and not from what's on the market you should be fine.

  5. If you get multiple replies on an email it seems like they overwrite eachother.


    I sent an email to my clan an asked for opinions. I received a reply and just looked at the mail quickly but left it unread for later. When I came back an hour later the sender of the mail had changed in the list, so I clicked it, thinking it was probably typical UI bugs. Nope, it was a different reply from a different member. The first reply was thus... gone  :huh:

  6. I'm having money disappear too. I log all my trades and count my money whenever I empty my cargo, and my last route only gained me 80k, but should have been around 600k.


    When I arrived in Basse-Terre I clicked the Sell button and maximized the amount-input. It went to around 2371 or so. Got an error (as seen in the last screenshot). Tried again and it seemed to work.



  7. Or instead of balancing the game around a dead server that has 10 people per nation, they could just merge the servers.

    Then perhaps that should have been done before ruining the game for hundreds of players.

  8. the only difference between those servers is ability to attack players and buy assault flags. no other difference. so changes affect all servers.

    So then my initial comment applies. This patch will only remedy an abundance that exists on PVP1; other servers will suffer under the DEATH METAL difficulty level. With barely 10 players per nation online in PVP3 there's a very low chance of one of them being an adequate shipbuilder.


    I think joining a clan or making friends should be an enhancement to the game experience, not a prerequisite. This isn't a social network. :-/

    Independent players have 5 accounts and craft Santisimas on their own. They will be fine trust me. If those who don't have many accounts, can join my guild on pvp1 usa, pm Wind Element. lol

    Oh wow, this sounds great! How do I create more accounts? I thought this game wasn't pay-to-win?

    Not true, all nation have big clans will help you providing ships and all you need :)

    On PVP1, sure. The big clans on PVP3 can just barely take care of themselves, and that sentiment is based on PRE-nerf.

    NPCs sailing all ships now. Including large fleets of first rates. 

    To avoid problems with imbalances caused by this capture is switched off. Its just a checkbox on the server. if its wrong its going to be changed. 


    Don't let us question the open development :).

    I think it would have made more sense to add this new no-capture feature to 2nd and 1st-rates only. Nerfing an existing and fairly balanced (overall, given difference between servers) economy feels unnecessary.

    Don't get me wrong - I love everything about the patch except for this one thing. I'll happily abide by the new rules but think it will just further the gap in player retention between the servers.

  9. Statistically people don't lose ships much on the pve servers. I am sure it is 10x easier to build ships on PVE1. 

    We are ok with cutting something people like if it brings other things that are a lot better - which is much better variety of enemies on the OW.

    If we want to improve pve content the ability to capture must go - + its somewhat historical. Admiralty always took the captured ships away. 

    So by "PVE content" you do not mean Open World, but PVE Servers? Meaning, this does not affect PVP1 or PVP2 or PVP3?

  10. so if understand this correctly the only way to get ships now is by having them made as it says all captured ships are sent to admiralty, well it says combat ships so i guess traders are ok to capture


    so the only way to get connie and 3rd rates now are to have them built for you, doesnt that kind of hurt the small clans who dont have the crafters the large clans do 


    this might not be a good change

    Agree. This change was not made with other servers than PVP1 in mind.

    • Like 1

  11. klr-256x256.png

    Karibiens Lierade Riggar
    Our philosophy is simple; we play because it's fun. Our members like helping eachother

    as a team and have a variety of specialties, ranging from crafting and trading to PVP.
    We impose very few restrictions on our members; we ask that you respect

    established diplomacy and that you not be a jerk to other players.
    For fleet activities and socializing we have a Discord server. Discord is like Teamspeak,

    but cooler (e.g. there's a web client if you don't want to install stuff).
    If you are interested in joining, contact Svartschegg or SirVonBiginch.

  12. Ports ports attacks and leaderboards (if is set in the future) that arent in real time... :(


    At least the ports and ports attacks

    If you're on EU PVP3 you can query https://klr.nu/api/v2/port/{port_id} for a log of conquests. API docs: https://klr.nu/api/v2/docs#port

    Sample response for Scarborough:

      "updated_at":"2016-04-17 08:32:34",
        "name":"Verenigde Provinci\u00ebn",
        "updated_at":"2016-04-13 08:16:17"
        "created_at":"2016-01-18 00:00:00",
        "updated_at":"2016-04-12 13:41:52"
            "updated_at":"2016-04-24 10:15:47"
            "name":"Live Oak Log",
            "updated_at":"2016-04-24 10:15:47"
          "updated_at":"2016-04-24 10:16:18",
            "updated_at":"2016-04-24 10:15:47"
      "conquests":[ // 10 latest, regardless of contested (captured) or not
          "created_at":"2016-04-06 15:59:32",
          "updated_at":"2016-04-06 16:49:16",
            "updated_at":"2016-04-05 05:53:50"
            "created_at":"2016-01-18 00:00:00",
            "updated_at":"2016-04-12 13:41:52"
    Edit: API v2

  13. Yeah I know how to authenticate with Steam, but Naval Action has a secondary, undocumented, layer of authentication that checks for the Steam token and also allows users to login with a user/pass combination that bypasses Steam. It is that secondary step of authentication that I suppose returns the list of "Captains" in your account.

    To clarify with an example, my Steam username used to be "John", but my main captain in Naval Action is called "Svartschegg". I would like to retrieve "Svartschegg" from NA rather than "John" from Steam.

    • Like 1

  14. Indeed...



    Here is a quick PHP function to transform this javascript declaration into proper JSON


    returns null if something is wrong, or a PHP array containing datas from the "API"

    	function fetchEndpoint($endpointUrl)
    		$content = file_get_contents($endpointUrl);
    		if($content!==null && is_string($content))
    			$equalPos = strpos($content, '=');
    				$content = trim(print_r(substr($content, $equalPos+1), true), ' ;');
    			$JSON = json_decode($content,1);
    			return $JSON;
    		return null;


    Since we're in a sharing-is-caring mood I implemented your function into an implicit Laravel controller :)

    Edit: Made it a Gist instead of pasting it all here. https://gist.github.com/Sleavely/945939aec743ebe1b54ddc89b861493b

  15. This is neither JSON nor JSONP. It is Javascript. Why they name the files .json is beyond me  :huh:


    • JSON is data in a javascript object notation format.
    • JSONP is data passed to a callback function which is named according to a request query parameter (commonly called "callback" for simplicity). In reality, JSONP is essentially Javascript that has been twisted  into a data-loading method to circumvent CORS.
    • This is a variable declaration in Javascript.
  • Create New...