Of GUI and Tooltips

by DanieleBubb

I’m starting a series of articles on the technical side of things, to show what’s the solution taken for common problems in game development, trying to improve them and share it with fellow developers.

Nantucket is made with Unity, it has been awesome so far, after more than a year in development we feel quite comfortable using both the engine and the editor. But there are situations where we preferred to implement the solution ourselves instead of using built-in libraries or getting asset store packages. The whole UI library is an example of this.

Possible UI Solutions

At time of starting the development of it (mid 2014) there was no uGUI, so the only feasible built-in solution was the legacy OnGUI. We scrapped it right away because was not flexible enough to handle overlapping interfaces and different resolutions.

We evaluated the idea to purchase nGUI, but at that time was too expensive for us for what we needed.

We haven’t tested the new uGUI yet, but at this point of development is too much work of refactoring to switch.

So we went for building our solution from the ground up, so we could implement a library that contains only what we needed and is easily extendable.

Collider Manager

Each in-game component that interacts with the player has a Collider2D, in order to be detected by mouse movements.

The Collider Manager provides a series of functions which give information about colliders, their position, and their Z order. It’s used mainly to understand which objects are pointed by the mouse pointer, both GUI components and game objects.

To handle Z order, the Collider Manager has a list of Layers ordered by priority. That’s all we need to handle overlapping user interfaces and detect whether the player is interacting with the map or with the interface.


In this picture, there are three Layers ordered from high to low priority: UIClickable, UIBackground, MapCity. Using the Collider Manager, is possible to detect whether the mouse is pointing to the ship slot and show the tooltip, or decide to accept the click on a city and handle cases like: the city is covered by the interface background, if the user clicks where the city is, the Collider Manager understands that the user is clicking on the interface and not on the city.


The first big choice we had is to implement the whole interface in world space coordinates. This let us design the UIs in the Unity scene together with the other scene objects, and it was great for us, because we had the possibility to see how the UI fit in the screen, and how it’s placed relative to the other objects, even in edit mode, reducing a lot the turnaround times.

But using world space coordinates has its drawbacks:

  1. Aspect ratio is fixed. In case the player uses one different from 16:9, there are black bars on the sides
  2. The interface is designed for FullHD resolutions. For different resolutions there could be a lot of aliasing in text and sprites due to texture filtering

Everything in the GUI is a GUI Component, a simple script that provide functions to change the state (i.e. edit text, change color, change sprite) and it handles mouse events that happen on the component itself.

All the GUI state and behaviours are handled by the GUI Manager, which has 2 main tasks:

  1. Dispatches mouse events like Mouse Over, Click, Drag & Drop to the GUI component
  2. Updates the info to show in each component, but only when needed to avoid performance issues

We use built-in TextMesh components for UI texts, they are good enough for our purposes, but we didn’t find a good solution to avoid aliasing. We might consider using another solution for text in the future.


As you may have seen in some gameplay footage, we use tooltips a lot in Nantucket. We think is the best way to provide the player all the information he needs at the moment, without letting him confused and doing the best to help him to take the right decision.

Every object with a Collider2D component in the scene can be a target for tooltips, all it needs is to have a TooltipComponent attached. The TooltipComponent provides a text to the Tooltip Manager, which in order shows a tooltip with that text when the player moves the mouse over the object.


The text content in the tooltip varies a lot in terms of size, and the target object can be in any position in the screen. So we added a database of different versions of Tooltip Objects, which varies in: text lines number, arrow direction, arrow position.

There is a central Tooltip Manager which handles all the tooltip functionality, its main loop is:

  1. Pick an object pointed by the mouse with a Tooltip Component, using the Collider Manager
  2. Wait a delay while the mouse always points to that object
  3. Select a Tooltip Object from the database depending on: Text lines, Component position, Tooltip preferred direction. The tooltip object will be placed just outside of the collider of the target object, so the object won’t be obscured by the tooltip
  4. Show the tooltip
  5. Hide the tooltip when the mouse doesn’t point to that object anymore


The Tooltip Manager makes sure that the tooltip object is always on screen so, for example, if the object is on the far right, the tooltip will go on the left even if the preferred direction is on the other side.

The tooltip object database handles until 6 lines of text for now, but we already have tooltip texts longer than that, so we added a special tooltip objects which is a big flat rectangle that encloses all the text. Before the game ships we may implement a solution to have modular tooltips, in order to handle all the text sizes.

That’s all, I’d like to hear voice in the comments, any feedback or question is welcome.



Nantucket has been Greenlit!

by picaresque

Thank you! Grazie! Gracias! Merci! Obrigado! Спасибо! Danke!

YOU did it.

7 days, unbelievable! It was definitely faster than expected and this allow us to focus on delivering you the best game we can. Keep following us during the development since “more is coming”.



Nantucket LIVE @ Gamelab 2015

by picaresque

Picaresque Studio will be attending the Gamelab 2015 and we will be showing a pre-alpha version of Nantucket!

We invite everyone attending to visit our desk where we’ll be more than pleased to show you our last creation!


(click on the image to access the Gamelab Indie Hub web page)


Ay, Ay, sir! There she blows!

by Mex

Perseus, St. George, Hercules, Jonah, and Vishnoo! there’s a member-roll for you! What club but the whaleman’s can head off like that?

Herman Melville

Ahoy there!

If you missed our news or you didn’t notice the banner on the right, this week we have launched our Greenlight campaign. So, before starting this post, I would like to thank all the people who have already voted for us and encourage the rest of you to leave a big YES on our Greenlight Page: http://steamcommunity.com/sharedfiles/filedetails/?id=458343309 !


Today we are going to get our hands dirty, because it’s time to speak about our combat system. In this first post we are going to speak about hunting (combats against creatures), while next week we will conclude the combat chapter dealing with pirates and indigenous war canoes.

Hunting is a key part of Nantucket, since whale blubber (and oil) will be your most valuable source of income. The game features 9 different sea creatures, each one with its own characteristics and abilities (according to its age), for a total of 38 unique skills to face during your hunts. I can guarantee you few of them will be an easy catch.


So, you set sail and you finally find a whaling area or migration route. Time to lower your whaleboats. Your ship can have up to 3 whaleboats (according to its size) and each whaleboat has 3 spots to fill with your crew:

  • Rudder: the spot used for defense rolls. Sailors are the best class to use in this spot.
  • Bow: the spot used for attack rolls. Hunters are the best class to use in this spot.
  • Oars: a backup spot that can be used for some passive skill.

Once you have assigned all the crew you think you may need for your next hunt, it’s time to fight. Nantucket’s combat system is turn based. Each turn there is an attack phase and a defense phase and each phase you will be able to assign commands to every whaleboat in the combat area. Some command are always available (Attack and Dodge, for example), while others require to have characters with a specific skill in order to be performed (for example, Fasten and Heal).

Offensive and defensive actions require a roll, using the combat dice of the character placed in the correspondent whaleboat’s spot. So, if you choose to attack a whale, the combat dice of the man in the bow’s spot will be roll: If it beats the whale defensive roll, it’s a hit. In its core, it’s like Risk (tied are win by defense), just with much more variables. There are 3 main elements affecting the results:

  • Skills: skills affect dices behavior and output. For example the “Thinking twice” skill allows you to rolls 2 attack dices, keeping the best result.
  • Conditions cards: represent the combat environmental condition and they can help one side, the other or none of them. For example “Rough waters” gives a -2 to all the whaleboats defensive rolls.
  • Dices evolution: by leveling up, dices’ sides evolve, increasing their values (up to 5 per side) and unlocking special sides like “Evasive maneuver” that, if rolled in defense, represents an automatic success, despite the attacker value and bonuses.

There are also special objects, but they work like Skills, and since they are part of the Quests discussion, I would like to speak about them later.

Finally, if the attacker beats the defender’s value, it deals damage.

The combat system is designed to be quick, and once you’ll get a good grip on the mechanics you are going to experience fast and deadly hunt for loot. You’ll discover soon that the biggest challenge of the combat is a good planning: choosing the right men and developing your captain. Then there is a bit of luck, but as Ralph Waldo Emerson once said: “Shallow men believe in luck or in circumstance. Strong men believe in cause and effect.”

See you next time to repel a pirate boarding!



Nantucket is on Steam Greenlight!

by picaresque

We promised exciting news and here you have it!

Nantucket on Greenlight

(click on the image to access Steam Greenlight and vote)


O Captain! My Captain! [Part 2]

by Mex

He’s a grand, ungodly, god-like man, Captain Ahab; doesn’t speak much; but, when he does speak, then you may well listen.

Herman Melville

Ahoy there!

Here we are again, sailing forward with fair winds. This week has been particularly busy for all of us and in the next few days you are going to discover why. We are pretty excited, I hope you will be too.

Now, back to where we were last week. In my last post, I’ve introduced you to the character creation in Nantucket and the basic captain’s attributes. Today we are going to speak about all the elements related to the Captain evolving during the game.


The first one is quite easy: Prestige. Your prestige represents the respect achieved among sailors, but it’s not a mere trophies showcase. The amount of prestige you have works as a level cap for your crew so, higher is your prestige and stronger will be the crew you can hire. You can gain prestige by hunting whales or completing quests around the world, but you can also lose it by showing yourself weak in front of your men. Be careful, there is a thin edge between bravery and stupidity.

Among the tools at your disposal in this hunt for glory, Skills are probably the most powerful. Regarding the crew, I told you that each class – Sailors, Hunters, Scientists and Craftsmen – can take 3 specializations, each one characterized by 3 specific skills unlocked by leveling up.

The Captain has access to all the skill trees (36 skills), leaving you the freedom to shape him according to your preferences. It’s up to you to decide if you prefer a captain specialized in hunting whales or managing your ship or something in the middle. There are skills for everything: from unlocking new ship technologies to improving your Combat Dices, that are the last element we are going to speak about.

I’m not going to give you too much details about the combat, since it deserves at least a couple of posts itself, but I’ll tell you that you can shape the dices used during the combat by your Captain, according to the strategy you want to take. You will be able to create new sides and unlock special sides, determining if your captain is going to take the whaleboat’s bow or waiting for his men on his ship. Again, customization is the key.

That’s it for today. I’m not sure what my next post will be about, it could be about sailing, combat, ships, grog recipes, the best way to whip a sailor…I’ll think about it.

Keep your eyes on our website or social networks in the next days, I promise you won’t regret it!




O Captain! My Captain! [Part 1]

by Mex

If the highest aim of a captain were to preserve his ship, he would keep it in port forever.

Thomas Aquinas

Ahoy there!

In my previous post I’ve introduced you to character classes, so the hands at your service. This time I would focus on the boots you are going to wear in Nantucket: the Captain.

Since there are quite a lot of things to say about this topic, I’m going to split it in separate posts. In this first part, I’m going to start from the very beginning of the game: the character creation.

Character Creation

Speaking about character classes, we introduced the four main attributes of the game: Hunting, Sailing, Crafting and Science. Each class (excluding the cabin boys) is characterized by the use of one attribute, developed by leveling up.

On the other hand, the captain can increase all four attributes and it’s up to you to decide if you are going to be a bulky captain screaming at your men from the whaleboat’s bow or a pondering one, wondering about the natural world. During the character creation you will have few points to spend in order to start this process.

The second element introduced in the character creation is Traits, and this is the only time you will be able to pick a trait at your choice. During the game, they are going to appear/disappear according to your actions. This screen will allow to pick a trait from a short list of “positive” traits, each one with a specific effect.

For example, the trait Strong will increase the damage of your character by 10%, and so on.

Captain’s traits are really important, not only for the immediate effect given, but also because they affect your relationship with your crew. Your men will respect you more if you share the same ideas and traits, while they will tend to dislike you if you have an opposite trait.

Here we are now, you just have to pick a name and you are ready to set sail. “Call me Ishmael…” is the opening line of Moby Dick, but maybe you prefer something different.

As you can see, character creation is quite simple and it involves just few choices. During the game you are going to develop your Skills and Combat Dices, as well as gaining Prestige, but it’s all part of the next chapter.

Stay tuned!



Looking for strong hands and a drink

by Mex

Is there a priest in this tavern? I want to confess! I’m a fucking sinner! Venal, mortal, carnal, major, minor – however you want to call it, Lord… I’m guilty.

Hunter S. Thompson

Ahoy there!

Last time we had a brief tour around Nantucket, now it’s time to take a closer look to what the town has to offer. The inevitable first stop has to be at the tavern, where you will be able to hire some helpful hands during your adventures.


Nantucket features five different character classes, each one specialized in a different seafaring area.

  • Sailors are valiant explorers who spend their lives at sea. No matter is a majestic vessel, a whaleboat or a simple board, they know how to keep it afloat, come rain or shine.
  • Hunters are men without fear, born to chase their preys. They can stand on a whaleboat’s bow sailing toward danger or face the wickedest pirate without hesitation.
  • Craftsmen are experts artisans, specialized in dealing with all the practical errands of a ship. Their hands are surely the dirtiest and most useful at sea.
  • Scientists are investigators of the natural world. Their curiosity and competence can unlock unknown knowledge about the sea and, above all, save lives on your ship.
  • Cabin boys are inexperienced young helpers. They are maybe the least specialized, but you can address their learning path and make them be the men you want them to be.

Each class (excluding cabin boys) has three different branches that define the character specialization. For example, hunters could have the Harpooner, Man-at-arms or Survivor branch, each one characterized by specific special ability to use during the game. We will speak about abilities in the next weeks, since it’s something that covers a lot of aspects of the game not yet discussed on these pages.

Apart from their working experience and specialization, each character has his own personality, defined by Traits. Character personalities aren’t something to ignore, since they will matter a lot at sea, affecting the relationship with your crew and social dynamics among them.

Finally, time to pay. Actually, not yet. Nantucket uses a waging system similar to the one historically used on whaling ships, based on a Lay system. Each hired character comes with a lay, so a share of the catch of your next travel. Higher is the character experience and higher will be his lay request, lowering yours. Don’t be greedy, you could regret it once facing the charge of a 60 foot whale.

Well, since we are here, time for a drink.

A whiskey for me, bartender!



Sweet Home Nantucket

by Mex

Nantucket! Take out your map and look at it. See what a real corner of the world it occupies; how it stands there, away off shore, more lonely than the Eddystone lighthouse.

Herman Melville

Ahoy there!

As anticipated last week, starting with this post I’m going to present you the key features of Nantucket, and there is no better place than Nantucket itself to start this series of articles. Nantucket is not only one of the cities you can visit during your travels across the oceans, but it’s the place where the game starts, so the really first look at the game you will have.

You have survived the Pequod’s disaster and spent sleepless nights thinking about what happened that day, questioning the way fate and God operate, and in the end you’ve decided to stitch up that laceration from where it started. The Pequod is no more docked here, but her shadow is everywhere.


A Newspaper Boy is waving the newest issue of The Sailor’s Post in a corner, just outside the Tavern, where sailors are waiting for a new job drinking away the boredom. Your pockets are full of gold, everything you have saved, but that gold is not going to be there for long time. You will need a ship to chase Moby Dick, and the Shipwright is just there, not far away from the Merchant, where you can find everything you need to set sail.

Welcome back home, Captain.

Next week we are gonna enter the tavern, and I’ll present you crew members and their attributes. Stay tuned!


Land ahoy! A first look at Nantucket.

by Mex

But more wonderful than the lore of old men and the lore of books is the secret lore of ocean.

H.P Lovecraft

Ahoy, Picaros!

We’ve been quite silent for the last few weeks (cough cough months) and I’m sorry about it, but we were super busy coding, testing, breaking, fixing and breaking again features. Don’t worry, we are alive and kicking hard.

The mist around Nantucket is getting thinner and now that the coast is on sight, we would like to start sharing the view with you all. If you still don’t know anything about Nantucket, I can tell you it’s a seafaring strategy game set after the events narrated by Herman Melville in his masterpiece, Moby Dick. Playing as Ishamel, the sole survivor of the Pequod’s disaster,  you will have to make your mark as a whaling ship’s captain in order to fulfill Ahab’s revenge on the White Whale. In December we released a teaser trailer (if you have missed it, you can find it here), showing some art and hinting about the story behind the game, but in the next weeks we are going to present you the key features, so that you can get super excited about it and start throwing money at your screen.

I’ll start sharing with you the first gameplay screenshot, it’s a work in progress, so things could change before the release of the game. Any feedback is more than welcome. Enjoy it and stay tuned for more updates!