Articles Blog

ARK on iOS: Leveraging UE4 for 98% Content Reduction | Unreal Fest Europe 2019 | Unreal Engine

ARK on iOS: Leveraging UE4 for 98% Content Reduction | Unreal Fest Europe 2019 | Unreal Engine

>>Morgan Hughes: Hey, Everyone. Welcome to Unreal Fest. This is kind of exciting,
right? Being in Prague talking about
Unreal all day. I am going to be covering
the content reduction of ARK: Survival Evolved.
Let us get into it. I am Morgan Hughes, the Art Director
at War Drum Studios. Earlier today, my CEO Thomas
was talking about the technical and business
side of the ARK project. I am covering strictly
the content side. I am an artist.
That is what I do. Just a little bit of background
about who we are and what we do and why we are qualified
to talk about this. War Drum Studios
has been around for 10 years. We have been
making mobile apps since the very beginning
of the app store. We also do console games,
but this is a mobile talk, so let us talk about mobile. Some of more notable projects
are the Grand Theft Auto series. One of my personal favorites
is Auralux, free to play. Our most recent
before ARK was Bully. As you can see,
we are pretty familiar with the open world
environment on mobile. We will see some similarities
in ARK Mobile to San Andreas, which was our biggest
open world game. Similarities like size
of the World, number of animating Characters,
number of Assets in total. But those projects
differ greatly. The issues that we had
with porting San Andreas are not at all the same content
issues that we had with ARK. We will get into
the very specific things that ARK
challenged us with. So let’s do it. Anybody who does not know,
this is ARK: Survival Evolved. It is an open world
survival game where you are on an island
full of dinosaurs and prehistoric creatures, and you are building,
crafting, surviving. You can do pretty much
anything in ARK. You can tame dinosaurs,
ride them, swim, fly, farm, breed. It is a sandbox
of surviving with dinosaurs. We support single player
and multiplayer up to 60 players
on a server at a time. It is a huge,
expansive World measuring about 50
square kilometers. The graphics on the original ARK
game are just phenomenal. It is a very realistic,
very immersive game, and I think that is one
of the biggest reasons why it has such a fan base, is because you can go
in the game and feel like you are really
in the world full of dinosaurs. That makes it hard as a mobile
developer, seeing this game on PC
and console. I even go back
and play it on PC, and I am like, oh man,
this thing looks so nice. As a mobile developer,
your biggest task in total is to make the experience
feel the same as it does to players
who play it on PC and console. You want them to go from console
to mobile and feel like it is the same world
with the same environment and the same creatures. That is really hard to do.
Here is how we did it. I am going to just briefly run
through some of the challenges that we encountered
in this project. Then we will go into each one
in more depth as we come across them
through the content. The first challenge
is your application size, just your downloaded app. We set a target to stay
in two gigabytes so that we could support
a wider range of devices, specifically some of
the older devices with low capacity like 16
gig iPhones or what have you. We have a real time memory usage
of 1 gig or more often less. That is because even though
the phone may say it is a 2 gig of RAM phone,
the OS is taking up RAM there and your background processes
are always running. In reality, the ARK game itself
is running on a gig or less of memory. Shader complexity. You have to be very conscious
of your shader complexity when you are making
a mobile game. The lower the complexity is, the better your frame rates
are going to be. Screen space reflections are not supported on
all mobile hardware. When we were going through and looking
at which devices supported it and which devices did not,
we said, screw that. We are just going to
take it out altogether. We do not support it
on any of our devices, and we found workarounds
for that. I will explain them all
when we get to that section. Dynamic lighting is a challenge. There is a Static Mesh light
limit of 4 lights per Mesh. We had to come up with some
creative solutions for that. Post processing.
Most of that is disabled on mobile
just straight off the bat. What is allowed on mobile
is extremely expensive. You want to pick and choose
very cautiously as to what post processing
you are going to use. The ARK PC was high,
high on post processing. They did all kinds of AO
and depth of field. Bloom, typical console graphics. You cannot do that
on mobile, sorry. Hate to bust your bubble. Here is a video
one of our community managers put together for me
of PC and mobile. How did we tackle this project? In a broad sense,
we went through from day one and put every person that we could that
was not writing code, that is our testers
and our audio guys and our community managers,
whoever we had. They got put on
content reduction. This is not
a very art-specific task. It is not like you need
qualified artists to reduce your content. If you have tens of thousands
of Textures or hundreds and hundreds of Meshes,
this is something that anybody who knows how to use a computer
and navigate Unreal can go through
and drop content. We set everybody to drop content
as low as possible. We reduced Textures
and Meshes down to the base that we could get them.
Then we made it run on device. I really wish I had a video
of that for you guys, because our first working device
run was so exciting for us two and a half years ago. It was this little island
the size of this room with 5 dinosaurs and 10 trees. We were like, yes,
it works on mobile! We obviously came
a long way from that. In the beginning, not knowing
how much of this game was possible on mobile, there was not really anything
on the market like this before. We had to make some really
cautious promises to the people
that we were working for. We promised about
half the island size. We took out
all underwater gameplay. We took out all flying gameplay,
and we removed all the bosses. But we did active development
on this game for about a year and a half
before we released it. We ended up bringing back all
of that except for the bosses. We have a full-size island. We have all the creatures
from the original game. We have all the flying.
We have all the underwater, and we left out
the boss battles for now, but our 2.0 update
coming out this summer is going to reintroduce
all the bosses. In the end,
we will have the same gameplay with just a little bit
of mobile tweaks to make it
a specific mobile port. Let us move on. I am going to start with
all the obvious stuff. This is stuff that anybody
working on mobile is going to be
very familiar with. Let me just put a note in here
that we started this project from a complete
working retail game that had millions of players. Our development process
is not going to be the same as a lot of people who are in active development
on a new game. We branched the code
for mobile completely. Any of these content reductions
that we are doing, we could do that
without having to worry about still supporting PC and console.
These solutions may work if you are
doing a wide range of platforms. You may just have to get
a little bit more creative about how to get
these low-res mobile Assets as well as keeping
the console people happy. I just wanted to throw that
in there that this is a very specific
branch for mobile only. The solution should be similar. Let us start with Textures. This game has thousands
and thousands of Textures. We went through and reduced them to about a quarter of their
original size, in most cases. That means our most high-
resolution Textures are at 512. That is stuff like the player
character, the dinosaurs. That is about it. Everything else, the majority of
the Assets are running at 256. For Diffuse and Normal Maps,
we have UI Textures running at 128, particle effects
even lower than that. You just cut them.
Nothing you can do about that. Then we took out all the bloat. That is all the stuff
that we no longer use on mobile. We will really dig into that when we get to
the Material section, but it is stuff like AO masks
or layered Materials that have
metal roughness normal. We took out all of that.
We took out any duplicate Textures that were like, this is sand, but this is
some sand with pebbles. No, sorry.
On mobile, you get sand. There is no reason
to have two versions of sand. You just do not have
the disk size, so you cut out anything
that you can. One of those things that we left
were color masks. But the original game
was custom coloring everything from armor
to structures to weapons. Players could go in and paint
all of their things to match whatever they wanted. We left that to be only
on creatures. That is mainly because when
creatures spawn into the world, you do not want them
to all be the same color green. We use color masks
only on the dinosaurs. In all these other things
that we took the color out of, we just do a straight color mode
on the diffuse and say, well, you can paint your armor red,
but it is going to be all red instead of red here
and green here and white here. It is just a concession
we have to make on mobile. But that removed
lots of Textures. They had a color mask
for every single UI item and every single
Diffuse Texture. We got it down
to just the 80 masks that are on the 80
different creatures. The next big thing that we did
that I highly recommend for anybody developing,
whether it is mobile or console, is to make custom
Texture groups for your Textures and make a pass and organize
your Textures ahead of time. You can use the groups
that are provided by Unreal, but we made our own. We said, we are going to have
a group for 512 Textures. We are going to have a group
for Normal Maps. We are going to have
a group for UI. That gives you the power
to change that whole group of Textures
all at once for any specific device
that you are working on. Something that
we do specifically is when we detect that it is
a lower hardware, an old phone or something. We say,
take all the 512 Textures and drop them to the 256 group. If your phone
is running at 3 FPS or burning up, we just switch
the Texture groups. It is a really
easy backend change. But you have to do the man work
ahead of time and make sure everything
is organized into groups so that you can utilize them
in the end. The next thing we did was resize
all of our Textures to be square. UE4 will do this
for you automatically, but they will not do it
in the way that you want. You need square Textures to utilize
PVR compression on iOS. But say you have a 512 by 64
Texture. UE4 will make it 512 by 512.
That is not what we want. We took out all
of our rectangular Textures and we resized them
the way that we wanted to. Say we would make it 256 by 256,
or even if it was not super important,
we would go 128 by 128. But just having that
manual control over how you are resizing to square
is just that little bit of extra that you need to go to on mobile
so that your game will run. The last thing we did
was we used the Mip Gen Settings a lot. We dropped the resolution
on all these Textures, and now you have a bunch
of blurry Textures everywhere. One thing that is just built in
is that you can sharpen or blur your Textures
with these Mip Gen Settings. We did that on everything. If our Normal Map got blurry,
we would sharpen it. You get back some of that little
extra detail that you lost
by lowering the resolution. We also could blur anything
that got really aliased or rough around the edges. There are all kinds
of little extra tweaks you can do with that.
It is just like free game. Now that you have made
everything really blurry, how do you make it
look decent on mobile? This is something that
we started in Vice City way back in the day.
2012 or 2013 or something, where you just have
these huge tile Textures all over the world
and they are all blurry. Well, we add a detail Texture
on top of the diffuse that is just tiled at a
different rate than the diffuse. It just adds back in that little
extra detail that you lost
from reducing the Texture size. ARK Mobile has maybe
12 detail Textures. We use them on everything.
We use them on tree bark, on grass, on skin,
on wood, stone. Everything. Our creatures specifically use
a Normal Map detail just to bring back a little bit
of that skin Texture. You are just talking about
12 small Textures to add back
in all of this detail that you lost
from lowering the resolution. It is easy and it is cheap. Let us get into the Meshes. This was the majority of my job
for the past two years or however long
we have been doing this game. I will just make a note
that we are using Simplygon because our branch
is running off of 4.17 Unreal. The new version of Unreal has
built-in Mesh reduction tools that I hear are really
better than Simplygon. But I think all
of these principles apply to both,
so whether you are suing Simplygon or Unreal,
it is the same difference. The first thing we did
was just drop triangle count across the board. If anybody was at Thomas’s talk,
he said most of our Assets are 10 to 20 percent
of their original size, and that is true for everything
except the creatures which we dropped to about
30 percent of the original size. Our base LOD is running about 3
to 7,000 triangles per creature. Then we do an LOD 1
that is half of that. Then our LOD 0
is running at 3 percent. Let me just say,
anybody using Simplygon, it clamps your reductions
at 3 percent. When we found that out,
we removed it. Because on ARK,
we have a lot of things that are rendering
at 1 percent or 1 and a half percent
of its original size. That was just a simple, take the clamp off
and let us go lower. Because sometimes we need it
for LOD 3, LOD 2, whatever. Our lowest LODs are running
at 500 triangles, 300 triangles
for these creatures. We combated
that with screen size. Instead of using the default
LOD distance that is set up in Simplygon, we overwrote that with our
manual screen size adjustments. What does this mean? That means
you are only viewing LOD 0 when you are in range
of the thing to touch it. If you are up close
to the structure that you are modifying,
it will be drawing at LOD 0. If your dinosaur
is right in your face and you want to tweak
its settings or open its inventory,
you will see the nice version, the mobile nice version
of that dinosaur. As soon as it is out of range
for you to interact with that thing,
it will drop to the first LOD. That is pretty quick. But on mobile, you are really
only focused on the thing that is right
in front of your eye. It is not a noticeable drop. Then LOD 2, we save it for way
back out in the distance. If it is across the river or down in the
woods or whatever, then you will get that really
low, 300 triangle model. But it will be like pixels
on the screen, 2 or 3 pixels. It is a little bit different
than the automatic adjustment, but it makes a big difference
in our game to drop those LODs
as quickly as possible. But keep them
when you need them. We also noticed that the fur
was not reducing well with Simplygon, so we just added
a little bit of code to change the way that the fur
was getting reduced, and that make a big difference
for us, removing quads instead
of trying to reduce vertices. Something that we noticed
was hindering our reduction when we were going through
the dinosaurs was the eyes. We found ourselves as artists
dropping the LOD, dropping the LOD, trying to find that range
in which it still looked good. That turned out to be,
when the eye disappeared, bring it back up a little
until you could see the eye, and then stop. This was giving us
triangle counts that we did not
necessarily want. It was still too high. We were like, we cannot
have dinosaurs without eyes. We painted the eye
into the diffuse and removed the eye Mesh
from our creatures, and that solved two problems. It let us go lower with the
triangle count in the beginning, but then also when it pops
to LOD 1, the eye is still there. You are never going to get the
Mesh eyeball in a low LOD 1. But if it is painted
into the diffuse, that first pop which happens
pretty close to the player is a lot less noticeable
because the eye is still there. It is like one of those things
that you do not think of when you are thinking of the
game in a technical standpoint. But when you start playing it,
you are like, why does that dinosaur
look so bad? Oh, he does not have an eye.
Duh. That is easy. The last thing that we did was
more so for weapons and saddles. We started noticing that the
reduction from Simplygon was more so reducing
the pieces of the Mesh that were in front
of the player. It is mostly a first-player
game. If you are holding your gun and the barrel of the gun
is highly reduced, yet when you are looking
at somebody on your server and the back of the gun
is really nice looking, you are like, why would
Simplygon reduce it like that? Well, when you take a look
at the Mesh itself, there are all kinds of knobs
and triggers and cloth wraps and all kinds of stuff that
happen behind the player’s back or under the barrel of the gun where first person player
does not see that. We had to take those
high poly Meshes into Maya and remove some of
that extraneous that does not apply
to the player so that we could gain back
some triangles where it mattered,
which was right on the screen. This was also really useful
for saddles. The dinosaur saddles
go under the Dino’s belly or through the mouth
where they have bridles or straps or buckles
or whatever. When you are playing,
you are sitting on the saddle and what you see is the saddle. You do not see
under the dinosaur’s belly, and you do not see
what is in their mouth. By manually taking out
that stuff that does not matter, your reductions
get more specific to what actually is in view
of the first-person player. That is just a little extra that we had to do
for high poly stuff. Another pass that we made
was particles. I am going to get
into real detail with these Materials coming up,
but we changed the Materials from using a unique
parent Material per each emitter
and each particle system to using a group
of 6 parent Materials and running all of our particles
off of Material instances. This just saved
on shader complexity. It just had to be done. The next thing we did
was we dropped the sprite count to about 50 percent.
Just across the board, cut it. Then on some big particles
like environment particles, we reduce the spawn area. This is stuff like snow or rain
or the water debris when you are swimming underwater
and there is dust in your view. On mobile, you do not have
as much peripheral vision and you do not have
as much depth of vision. Just by bringing
in the spawn area to where you can actually
see reduced overall particle systems. We removed GPU sprites
completely. They just have high overhead
and use a lot of memory, and we just took them out. We also took out a lot
of high draw call systems. This will be ground fog
or god rays, stuff that is drawing one sprite
for half the screen space. It is just too expensive to have all those transparent
draw calls in mobile. We removed a lot of that,
large environment Textures that we just did
not need that on mobile. We took all UV distortion except for we left it
on our one fire Material, and we also removed
all of the dynamic parameters. That is just basically because
we only had 6 Materials to work with, and we could not have
a new Material for each set of
dynamic parameters that we needed,
and we just removed them. I keep talking about
these Materials. Let us get into it. Why are the Materials
so important in mobile? Well, you need to limit
your overall number of Materials because switching Materials in
the base game is very expensive. If you are only
rendering on screen a handful of parent Materials, then your game
is going to run fast. Our game is running
on 20 core parent Materials. For real. We set up our Materials
to have lots of parameters that you can set
in Material instances, and we picked the 20 main things
that we needed in the game. We have a Material that runs all
of our wind Material instances, so all of the trees and grass
and everything that uses wind uses one parent Material.
We have a parent Material that runs that color mask
on the dinosaurs and it grabs the color channels
from that mask, and it is a very
specific Material just for anything with that. We have one Material
that runs metallic. We have one Material that runs
anything with a detail Texture. We got it down
to a base group of 20. We also have 20 fringe Materials
for any of those oddball cases. This is stuff like the player
map that draws little decals where the player is
and where your base is. We have an oddball Material
for the lava which is just
in on specific cave in one part of the island.
It brings up the lava Material. We have specific cases
for the human hair, which changes in length.
Those are just things that we could not fit into
our group of core Materials, and we just got 20 fringe cases.
They are used very rarely. You are never going to have more
than one or two fringe Materials in your scene at a time because they are just specific
to certain parts of the island. Then we have
the 6 particle Materials from the particle reduction
that we did before. The next thing you have to be
conscious of is your shader complexity. This means low number
of instructions overall and low Texture lookups. Mobile has a limit
of 16 Texture lookups, so the lower you can keep it,
the better. Our approach for Materials
overall is we went from ARK PC which was PBR
to a more traditional, Diffuse Normal hybrid approach that we made
specifically for ARK. That means that the PBR shader
math is pretty much the same. But we are treating roughness
more like traditional spec. Our metallic relies
on a pure environment lookup which I will get into
in a minute. On the most part,
our AO is completely baked into the Diffuse Texture. We set up single scaler params
to set metallic spec roughness on almost all of our Materials. We are not using Texture lookups
for any of those properties. Without screen space reflections
and without PBR shaders, how do you reflections
and metallic? his is how. We use a single,
250 environment cube map for the entire island.
It is a little bit washed out to maintain good
color range and SRGB. But since we took out
all of the reflection captures – mostly because it is not
supported on mobile and we did not have the space
to store dynamic Textures changing all the time – we use this single map
for everything, and it works pretty well. We take the day/night cycle
and we do a color molt on this Texture depending on what
the sky looks like at that time of day. Whether it is sunset or night
or whatever, we just do a color molt
on this base Texture. Then for the metallic,
when we dug into how the UE4 mobile metallic
was working, we did not think it was matching ARK PC as much as we
wanted it to. We tweaked it.
What our metallic is doing is it is calculating the light
from the diffuse in the Normal, and then it is lerping that
with that environment map that I had up there a minute ago after the time of day color
has been applied. Then it applies the shadows
after that. All of our metallic is running
purely on that environment map lerping with the diffuse. You can see the metallic
on the pickaxe. It is on the wet sand. It is on the water.
It is on the dinosaurs. It is all using
the same cube map. It works pretty well for us. That is probably useful to note
that our island looks pretty much the same
throughout the entire thing. I guess if you had buildings
or interiors or rooms, you would have to switch out that cube map based
on what your game is doing. For us, we can get away
with using one. You might have to use two
or three or four depending on what type of game
you are having. But just limiting, taking out the dynamic switch
of textures is a big thing. Baking. We do a lot of this
in Ark Mobile. You want to bake anything and everything you can
outside of runtime. This can help with a variety of
issues like shader complexity, Texture lookup,
the lack of Post Processing. Something that was easy
for us to do was that we had a complete game
to work with. We knew what the lighting
should look like. We knew what the saturation
should be. We knew what the final effect
of the game was. We could start baking
at the beginning. But anybody who is still
iterating on their game, I would suggest
to do all of the stuff on this slide at the end. Wait until your Post Processing
is final. Wait until your lights
are set up. When you have all of that
looking the way you want, then you want to go through
your Materials and pull out all of the stuff that you can bake
and do outside of runtime and then simplify your Materials
after the fact. What does this entail? We bake the AO
and the color on the Landscape. I am going to get into
the Landscape detail a lot at the end. We also put the AO
in the diffuse on everything. We realized when we looked
at the shader that the AO was just being multiplied
at the end of the shader. What is the difference between
multiplying it in Photoshop, reimporting
your Diffuse Texture, or letting the shader
do the work all the time? We just did it manually. It is
a little bit of manual effort, but it makes your shaders
run faster. We put the AO in the diffuse.
I think literally everything. I cannot think of a case
where we are actually using
an AO Texture lookup. Then we did a lot of manual
Texture adjustments on every Texture. This is stuff where ARK PC
was doing diffuse intensities or normal adjustments
or saturation, desaturation. They were doing it
all in the Material, and we wanted to take those instructions
out of the Material. We went into
the Diffuse Textures and we brightened them
or we upped their contrast or we desaturated them
in the Material, in the Texture Settings itself. We actually added
a little line of code to do a normal intensity. This Normal has been boosted
by one and a half times its original intensity,
but that is also baked in. we do it in the Texture.
It is done off of game time, and it is ready to go
when the game loads. If I were making a game
from scratch, I would put all of those things
in the Material to start. I would give yourself
all of these parameters that you can tweak
on the fly when you are playing. Then when you are happy with it,
go through and say, well, can I take out this
multiplying? Can I take out
this Texture lookup, and can I bake all these things
into the Diffuse and the Normal
outside of runtime? Let us get into the Landscape. This is one of the bigger
content changes that we made, and I kind of saved it to later
just to ease you guys into it. The original map for ARK PC was
just one huge Landscape terrain, and it has 30 layers
painted on it. It was taking up
1 gig of real time memory. If you remember
from the beginning, that is all we have on mobile. We had to find solutions
for this Landscape. The first thing we did
was we took the Landscape into World Machine and we broke it up into
25 individual pieces and used those
as individual maps. Each Landscape piece
is now its own map. The next thing we did was
we generated Static Mesh Proxys for each of
the Landscape pieces. There is our Static Mesh
right there. That was put into Simplygon
and reduced to about 40 percent. The other thing that making
a Static Mesh did was it baked
the Diffuse Texture. Instead of using
the 30 blended layers, when you drop to your LOD, that is a single
Diffused Baked Texture. What is the point of all this?
Streaming. That is what you want to do. In mobile, you want
to stream everything. We set up level streaming using
the World Composition tools in Unreal to use one or two
Landscape pieces at a time depending on where
the player is on the island. The rest of the time, it is using this LOD
with the baked Material. Doing those changes in the end brought our memory uses of
the Landscape down to 25 megs. This saved us a lot. It is not just the streaming
of the maps, but it is more so this Material
which I am going into next. Let us look at the Material. This is our Landscape Material
in ARK Mobile. I can say that this is our most
complicated Material in the entire game. We have a limit of 16 Textures, and this is the one case where
we even get close to that limit. We utilize every single
one of those 16 textures in this one specific case.
In all of our other Materials, we maybe hit four or 5
at the most for Texture lookups. How do we do it? We took 30 layers
and now we are using 6. We have the 6 Diffuse Textures,
the 6 Normal Maps. We have one for noise,
one for AO. Then one Texture accounts
for blending those layers. One Texture accounts
for the skylight, and one for the environment map
that we saw earlier. Let us break it down
a little bit further. Here is our Landscape piece with
the Blend Weight Texture on it. This is our one Texture lookup
for blending the layers. We modified the engine
for mobile to use all four channels of that
Blend Weight Texture. That is the R, G,
B and A of that one Texture. This was not default in Unreal.
You can see here we are layering four
different layers with the RBG, and A is the white.
But you said you had 6 layers. How do you do that?
I will tell you. We snuck in one more layer,
got us up to 5, by making the Base Diffuse
of the Material sand. In ARK Mobile, sand is
everywhere and it is the most commonly
used layer. We said, sand does not need
a mask. Sand is just going to draw
wherever there are no masks. That gives us layer number 5.
The other thing to remember is that we broke our Landscape
up into 25 pieces. When I said on
the previous slide that we used 5 out of the
6 Diffuse Textures, that is because each Landscape
piece is limited to 5 layers. But we can vary
that per Landscape piece as to which 5 out of the 6 we are going to use out
of all 25 pieces. In the end, our map is drawing
with 6 layers, but per piece,
we get 5 layers per piece. Here is a little GIF of
just how we combined the layers. We exported the layer
masks from Unreal. There were 30 of them, and we decided to group them
based on similarity. ARK PC was using 6
different types of pebbles, and we said, mobile only needs
1 type of pebble. We just layered
these in Photoshop and got our mobile mask
at the end, put that back in as our new
layer mask for that layer. We did this 6 times.
We combined all the grass. We combined all of the leaves.
We did a snow. We did a cliff rock
and pine needles. Those are our 6 layers. We also did this same process
on the clutter, although I am not going to
go into how we did the clutter, but it was very similar to this,
reducing the number of layers and combining them
to like types, that similar kind of thing. One of the other Textures in our
Landscape Materials is this AO. On PC, AO was a post
processing effect. We simply just baked the AO
to the landscape and put it in the Material
as a multiply. Then we noticed as we were
playing the game in development, that there were huge swaths
of land that looked just boring. It was just like
a field of grass. It was all the same color, and we said,
let us bake the color too. We took those original
30-layer masks and we decided which ones
were actually adding to the variety of the ground,
like the walking paths or the wet sand
at the edges of the water, or the leaves
that got really dark when they were under the trees. We turned them into
a simple color molt. You can see all the little
paths and detail that we just color molted
on top of the layers, and it brought back some of
that variety to the ground that we had lost
by merging all of our layers. That is a single Texture lookup
in our Landscape Material. Then we added the noise. This is the same concept
as the Detail Textures before, except we just take
this one noise, we put it over all 6 layers. It covers the entire Landscape
from edge to edge, and it brings back just a little
bit of that detail that we lost. Here is the before.
There is your change. It uses that same Texture
on the sand, grass, snow, rocks. You would think that
that is going to look weird, but actually it just kind of
brings back the resolution that you are losing
and makes a big difference when you are walking around
in the game, which is the majority
of the Gameplay. One of the big changes we had
to make to the Landscape — before and after with the grass. ARK PC was doing this
really nice dynamic UV scaling based on
the camera position where if you are walking
on the ground, all the Textures
are nicely tiled so they look high res. When you are flying,
they are scaled out so that you do not see
the tiling edges. But we did not have
that luxury in mobile. We had to pick a tiling range
for each layer that worked on both up close
walking and on flying. Because of that, our Textures
looked a little bit blurry while walking. This was our solution.
It really only applies to when you are walking
or riding your creature, because that is when you see
the ground up close. When you are flying,
that noise just goes away and you do not notice it.
Enough about the Landscape. Let us talk about trees.
Everybody likes trees, right? Well, ARK is all trees. There are no cool buildings
or streets to work with here. The entire world is defined
by where the trees are and where the rocks are and what is
the shape of the ground. ARK PC was running more
than 2 million trees. We reduced the instances
across the board. We actually wrote
a little Editor Action that took an even distribution
wipe of half the instances. Then, we analyzed which of
the trees we wanted to use, so instead of having
40 unique types of trees, we said, well,
this instance of this tree only has 300 instances
across the whole world. Let us take that and combine it
with a more popular tree. We got our unique tree types
down to 24 tree types. That is reducing
your Static Mesh calls and your Texture lookups just by taking out those 16
trees that we did no really need because there were 5 over there
and maybe 100 over there. Those were just not worth it. Then we took the trees and we
separated them into sub maps. The trees were distributed across each
of our Landscape Maps. There were 25 of them, but that
was not good enough for us. We took half of those
and we put them in Tree Map 1, and then the other half
is in Tree Map 2. There are 2 submaps of trees
per Landscape piece. Then we went even further with
the small stuff like the shrubs and the rocks and the stuff
that is just on the ground, our near maps. We have 8 individual near maps
per Landscape piece. That allows us to stream them
in and out when they are out of view
or too far away from the player. Because we are talking
about a huge Landscape here. Just having your instances
in smaller maps gives you more control over what you can show
to the player at any given time. We then took our 24 trees
and we put them into SpeedTree. We reduced them
even further by hand. We reduced the divisions
of the tree trunks. We reduced
the number of branches. We took the tree cards that were
originally 36 triangles per card and we made them
6 triangles per card. Those became our LOD 0s.
I think I have an image here. Then we used SpeedTree
to make the billboard version of that new, reduced tree type.
That is a 6-sided billboard. That is our LOD 1,
and the tree is our LOD 0. We experimented a little
with having an in between reduced Static Mesh
before we dropped to the LOD. But we found that it was making
the tree look less full. Then going from that LOD
to the billboard, which was based off of LOD 0
was too much of a drastic pop, and it seemed –
it worked better for us visually to go from the tree
straight to the billboard. I will say that using
the billboard system like this and setting the distance
at the range that we did is one of
the biggest concessions that we made in mobile. But having 1 million trees
rendering on mobile is impressive, I think. Making this concession in order
to do that was important to us. We had to go a little bit
further actually, with this. We found the problem
that when you were flying or up on a mountain or something,
the frame rate was tanking because it was drawing the LODs, these 6-sided LODs
all over the world. But it is still
a ton of triangles. We tried, let us stream
out the trees when they are too far away.
That left the map really empty. We had to come up
with a better solution. We did that with far maps.
We took each of our tree maps and we turned them into Static
Meshes of 2 triangle billboards. This is our far map. Here is
the triangle version of that. You can see one here.
It is 2 triangles per tree. That is a Static Mesh,
700 triangles or something
for the entire section of trees. We also made
an Atlas Diffuse Texture. That is one of our 512
by 512 Textures, and it has all the billboards
of those trees. When this Static Mesh
is rendering, when the billboard
LODs stream out, this comes in. It is a single Static Mesh
with a single Diffuse Texture, no normals, no lighting. That is cheap.
That is cheap to draw. We use the Unreal LOD streaming.
If you take a U Map and you name it
the same thing with _LOD1, Unreal will automatically switch
it for you when yours unstreams. It will pop in LOD 1,
and that is what we get there, that one.
From that one to that one. This happens really far out
in ARK Mobile. It is never something
that you notice because it is not
in front of your face. It is one or two Landscape
pieces away, and that is what you are seeing
when you are going to be flying or standing on top of
the volcano or whatever. That gave us huge savings. I have a video. This is not really the height
that you would fly in ARK, and it is not really the height
that you would walk. This is kind of an in between where you can see the transition
of the trees as they come in. You can see that everything
in the background back there are those 2-triangle billboards. Then everything up close
is the 6-sided billboards, and they do their dissolve
into the Static Mesh. This video is kind of nice
because it kind of shows you all of our LOD progressions. You can see
the rocks popping in. You can see the dinosaurs, LODs. Those little guys are probably
LOD 2 back there when they are coming in, and then the closer
they get to you, you can see they are
higher resolution LODs. You can also see the Landscape changing back there
in the background. That is what ARK looks like
in general if you are playing, anybody who has not played it. That is all I have got
for you guys today. Thank you for listening.
Thank you guys. [Applause] ♫ Unreal logo music ♫

33 thoughts on “ARK on iOS: Leveraging UE4 for 98% Content Reduction | Unreal Fest Europe 2019 | Unreal Engine”

  1. Wow whats next, designing a plant?

    You guys are amazing, leaving out content must be so hard m! Like deleting files and assets….amaaaaazing!

    While you’re at it, being super smart and stuff, can you remove content so it works on on my washingmachine?

  2. Could you goes help Wildcard? PC users would LOVE some of those work you guys have done on mobile. ARK just has too much stuff and polygons, im sure you know this well.

  3. ARK ? really don't get it how this devs get so much support for something awful on every platform

  4. THIS is how you remake ocarina of time BACKWARDS from 64 to SNES (97% content reduction required…)
    They've achieved 98% reduction!!!

  5. O K this is getting a bit ridiculous… 1822 minutes uploaded concurrently in 46 videos?!
    This is more than 30 hours uploaded faster than it can be watched lol :X

    Please consider how overwhelming this can be to people who want to learn as much as possible about your software, but… don't have infinite time?

  6. its amazing thing that they managed to make big games run on mobile platforms such as(PUBG,Fortnite,ARK) smoothly .UE4 has great potential more than any engine on these platforms

  7. Great timing on this video. I’m just starting to port to iOS. I never understood what Texture Groups were for 🧐

  8. Oh and now we can finally play crisis 1, with top line hardware and get a single framerate frame to load lol

  9. From my own experiences porting, this must've a been a bit of hell to do for the memory/size targets specified. An amazing job done though. It's intimidating enough porting something to the Switch let alone something that's 100GBs big…to medium-end possibly low-end phones

  10. I play this game on the new ipad 1TB and what they did with this mobile version of the game is mind blowing. It's up there with Black Desert Mobile.

  11. this is what I love about people who use unreal engine: here are our secrets, learn from them… I'm so thankful

  12. Sad thing is the PC version isn't optimized at all. Ram and CPU wise. You can tell someone tested it with an high end dev pc but not with an average consumer pc. Very good job on the mobile tho. Very impressive. Pls teach wildcard

Leave a Reply

Your email address will not be published. Required fields are marked *