-It, first of all, generates a landscape, with rivers and cities and such...
-It creates tiles and then switches off the render component, and then does a looping activation of tiles close to the player (unless they're already switched on, duh)
-It generates a mesh with a vertex for each tile
-Well, it's actually a row of meshes, as for some reason at about vertex 60,000 Unity doesn't write to the vertex list anymore.
Up next:
-make the row back into an array
-generate a lower poly (i.e. skipping vertexes) version of each mesh in the array
-maybe an even lower poly version
-switch off the renderers on these meshes so that the further they are the lower poly meshes are shown.
-generate a texture from the landscape tile data
-apply the texture(s) to the meshes...
So far I've put about two months off and on into it, so you can see why it's a moonshot...
Ok I've only been able to put some stolen hours every once in a while into this, but progress!
It's super unbalanced right now, where I think sort of everything is overpowered? If you don't make mistakes, you win really easily, but if you do make mistakes, you lose really easily.
I think the next step is adding an in-between bosses thing where you can actually tell what's happened after each boss, with progress pointed out, instead of the breakneck pace of just respawning immediately.
@Khavall this idea seems really cool! You mentioned positioning in the first post, and I'm wondering: have you considered making things able to switch rows? I feel like it might be worth the added complexity since it would open up more things on the player side (eg DPS with an attack that can only hit adjacent, or moving the tank to the other side of the monster and taunting) and on the monster side (eg pulling characters to different rows, moving between them).
Abilities could have specific ranges, like an AOE would be adjacent rows, ranged attacks would be a non-adjacent row, etc.
I hadn't thought of that, but it's interesting. Definitely one of the problems I'm having right now is that threat is sort of becoming either a "The tank will always be hit unless they're out of position" or "The tank cannot hold threat ever". A more robust positioning thing would probably let me find some other mechanic for the tank, and give options for things like the rogue being able to "dash in" and smack for extra damage as long as they can switch back from the tank.
Unfortunately, my progress is super slow these days with school, so it might be a while before I can try it out.
Anyone aware of any good resources for tackling privacy policies? Especially if they relate to AdMob? Am developing in the US.
Google has yielded some decent info, but they put a lot of the burden on developers to comply with legal standards. I may just reach out to lawyer, but just want to be certain it is necessary first.
This was one of those "motivation failed but discipline helped" weeks. I wrote out a list of tiny steps and made sure to get one thing done each day. Tasks included:
- Changing my fixed-precision number format struct to use an int instead of a long for its internal representation. This halves the size of my numbers in memory while still giving me enough number space to work with. (Because I'm writing 2D retro-throwback games, my unit of scale is the pixel. (Even) if a screen is 1920 pixels wide, and you divide all integer values by 1,000 for the three-digit precision, a level can still be about 2,000 screens wide. That is a lot of territory.) (Just like why I'm writing an ECS architecture from scratch, I'm using fixed precision with an integer backing store because it amuses me to do so.)
- Wrote the trig table for fixed-precision numbers. Rather than use any reasonably intelligent method of calculating trig functions, I instead do a lookup in a table indexed by the degrees and then lerp between the values. That is, the sine of 123.456 degrees is Lerp(sineTable[123], sineTable[124], 0.456). How did I get the trig table, though? A helper program written using Math.Sin(). Hey, it only has to be fixed-precision in the final product...
- Wrote a custom Newtonsoft de|serializer for fixed-precision. Whereas Newtonsoft could usually generate something like...
object: { fixedValue: { internalRep: 123456 } }
... my serializer sends it to a string so it looks more like...
object: { fixedValue: "123.456" }
Slightly more compact!
Also, because my random activity generator I use when I want to work on something but don't know what told me to do pixel art for an hour, I made this animation of a little monochrome squid:
This is the main character from 行く、イカ!, which is the game I'm targeting as a "minimum viable product" out of the engine. That's what Google Translate gives me when I put in "Go, Squid!" It's a shmup in which the earth is in peril, and the only thing that can save it from rampaging aliens is a squid that can shoot lasers out of its head for some reason.
My favorite musical instrument is the air-raid siren.
Moar moonshot. I'm super psyched I got the landscape generator to make a texture. I have the square mesh tiles. There's still a load to be optimized (or at least tested to see if optimising makes sense) but here's where I'm at at the moment:
This was one of those "motivation failed but discipline helped" weeks. I wrote out a list of tiny steps and made sure to get one thing done each day. Tasks included:
- Changing my fixed-precision number format struct to use an int instead of a long for its internal representation. This halves the size of my numbers in memory while still giving me enough number space to work with. (Because I'm writing 2D retro-throwback games, my unit of scale is the pixel. (Even) if a screen is 1920 pixels wide, and you divide all integer values by 1,000 for the three-digit precision, a level can still be about 2,000 screens wide. That is a lot of territory.) (Just like why I'm writing an ECS architecture from scratch, I'm using fixed precision with an integer backing store because it amuses me to do so.)
- Wrote the trig table for fixed-precision numbers. Rather than use any reasonably intelligent method of calculating trig functions, I instead do a lookup in a table indexed by the degrees and then lerp between the values. That is, the sine of 123.456 degrees is Lerp(sineTable[123], sineTable[124], 0.456). How did I get the trig table, though? A helper program written using Math.Sin(). Hey, it only has to be fixed-precision in the final product...
- Wrote a custom Newtonsoft de|serializer for fixed-precision. Whereas Newtonsoft could usually generate something like...
object: { fixedValue: { internalRep: 123456 } }
... my serializer sends it to a string so it looks more like...
object: { fixedValue: "123.456" }
Slightly more compact!
Also, because my random activity generator I use when I want to work on something but don't know what told me to do pixel art for an hour, I made this animation of a little monochrome squid:
This is the main character from 行く、イカ!, which is the game I'm targeting as a "minimum viable product" out of the engine. That's what Google Translate gives me when I put in "Go, Squid!" It's a shmup in which the earth is in peril, and the only thing that can save it from rampaging aliens is a squid that can shoot lasers out of its head for some reason.
The imperative of iku is Ike, which would give you Ike Ika, which I love :-D
Man, I was wondering about that! I've always heard it yelled as "Ike", but just assumed I was, like, missing some kind of weird inflectional thing when Google Translate said it was "Iku". Good to know it's pronounced the way I felt like it ought to have been.
My favorite musical instrument is the air-raid siren.
Man, I was wondering about that! I've always heard it yelled as "Ike", but just assumed I was, like, missing some kind of weird inflectional thing when Google Translate said it was "Iku". Good to know it's pronounced the way I felt like it ought to have been.
Started the Xbox One port last night. Took ages to compile the version of the unreal engine that can create UWP packages but I got there (My poor laptop was never designed for kind of stress).
Ok, the thing doesn't crash anymore. I had to comment out the part where it set the screen resolution but it now boots. It does raise the question of how I am supposed to adjust the resolution when it is running on Windows 10 but I'll cross that bridge later ("universal" my foot).
Ok, the thing doesn't crash anymore. I had to comment out the part where it set the screen resolution but it now boots. It does raise the question of how I am supposed to adjust the resolution when it is running on Windows 10 but I'll cross that bridge later ("universal" my foot).
Sigh. Steam was so much simplier.
Add #if/#ifdef compiler switches to your game code for platform-specific code blocks!
Ok, the thing doesn't crash anymore. I had to comment out the part where it set the screen resolution but it now boots. It does raise the question of how I am supposed to adjust the resolution when it is running on Windows 10 but I'll cross that bridge later ("universal" my foot).
Sigh. Steam was so much simplier.
Add #if/#ifdef compiler switches to your game code for platform-specific code blocks!
Not directly game dev related, but this is also a useful trick for CSS Styles or JavaScript when developing websites. You can check browser width to trigger specific styles, or check browser type for code blocks as well.
Ok, the thing doesn't crash anymore. I had to comment out the part where it set the screen resolution but it now boots. It does raise the question of how I am supposed to adjust the resolution when it is running on Windows 10 but I'll cross that bridge later ("universal" my foot).
Sigh. Steam was so much simplier.
Add #if/#ifdef compiler switches to your game code for platform-specific code blocks!
Can't do that. Afaik there are no platform check commands in unreal.
Ok, the thing doesn't crash anymore. I had to comment out the part where it set the screen resolution but it now boots. It does raise the question of how I am supposed to adjust the resolution when it is running on Windows 10 but I'll cross that bridge later ("universal" my foot).
Sigh. Steam was so much simplier.
Add #if/#ifdef compiler switches to your game code for platform-specific code blocks!
Can't do that. Afaik there are no platform check commands in unreal.
Ok, the thing doesn't crash anymore. I had to comment out the part where it set the screen resolution but it now boots. It does raise the question of how I am supposed to adjust the resolution when it is running on Windows 10 but I'll cross that bridge later ("universal" my foot).
Sigh. Steam was so much simplier.
Add #if/#ifdef compiler switches to your game code for platform-specific code blocks!
Can't do that. Afaik there are no platform check commands in unreal.
So I'm getting ready for procjam next week. I wanted to try and generate a "maze" in Unreal 4 by mashing together terrain chunks.
I'm not sure of the best way to do this. It seems like I should make a separate level for each landscape, and then load them using the level streaming functions in blueprint? Apparently I can make multiple instances of a level and load it into a different position/rotation so this seems doable.
So I'm getting ready for procjam next week. I wanted to try and generate a "maze" in Unreal 4 by mashing together terrain chunks.
I'm not sure of the best way to do this. It seems like I should make a separate level for each landscape, and then load them using the level streaming functions in blueprint? Apparently I can make multiple instances of a level and load it into a different position/rotation so this seems doable.
Yes you can but you need to use "Load Level Instanced" for what you want to do. "Load Stream Level" is for loading single instances sublevels that have been defined in the Levels windows in a fixed location. Also with "Load Level Instanced" you need to use the full asset name of the level [/game/maps/Level], not just its name [Level] but you'll figure that out pretty quickly when the editor throws you the level load errors.
I don't know how big your world is going to be but if the player travels far and fast make sure to use "Set World Origin Location" to avoid floating point errors when you start getting too far from center.
KoopahTroopahThe koopas, the troopas.Philadelphia, PARegistered Userregular
edited October 2018
My girlfriend and I have made a deal. Since I have a hard time starting and continuously working on video games, but it's honestly and genuinely what I want to do with my life, she said that she will start flossing every night if I promise to start putting time into my games a few times a week. Seems like a good compromise lol.
Update! Moonshot_RPG now combines 'tile' meshes in 4x4 batches, making the load for the GPU (an Intel Iris Pro Graphics 580 here) really a LOT lighter!
And that gives this result, on a small landscape with (4*64) * (4*64) tile, i.e. 65,536 tiles originally...
4.000 meshes now! https://youtu.be/nbwJIioZbpw
The next step, of course, is to apply the code I wrote to only render the tiles that are close enough to these blocks, and that should allow for a pretty sweet framerate on mobile...
edit: somehow the code to swap detailed for distant landscape meshes isn't tracking the player, so you're seeing the 'distant' mesh here instead of the detailed one. That's also why the player and the camera are clipping the landscape...
Getting to the end of this particular optimization rally. There are still a few things to add, but I'm pleased with the result so far. That's a sh*tload of trees... Haven't built if for the phones yet, so that's a test for tomorrow
+4
KoopahTroopahThe koopas, the troopas.Philadelphia, PARegistered Userregular
Well my game is complete (or about as complete as I can make it). Just some testing to go. I am so nervous, I've been working for three and a half years on this and now the public will finally get to see it.
Not onto something that is far harder than game development, marketing.
I just built to my OP2 and the level doesn’t even preload.
Going to progressively knock out stuff and see what is causing the issue, but since it's on Awake I have a hunch it's the seeded System.Random generation.
UPDATE
Funny thing is that the enormous amounts of trees you see in the image seem to be the problem- before they are even instantiated.
I'm going to instantiate a default cube instead and see what that gives...
UPDATE:
slow but it runs. (And, once running, can be optimized.)
But of course I don't want a super clever cubical landscape generator...
UPDATE:
with the 'standard' detail levels only it runs, but veeeryyy slow.
I'm thinking I might need to work with preset tiles rather than combine meshes into tiles at runtime. Which is actually fine by me, as I should be able to adapt the procedural generation to such presets quite quickly... And so 'Blockyworld' (working name) becomes more blocky again
Cornucopiist on
+2
KoopahTroopahThe koopas, the troopas.Philadelphia, PARegistered Userregular
I'm thinking I might need to work with preset tiles rather than combine meshes into tiles at runtime. Which is actually fine by me, as I should be able to adapt the procedural generation to such presets quite quickly... And so 'Blockyworld' (working name) becomes more blocky again
Screenshot is from the editor, but it looks like this on the OP2 and it runs at 30fps and also the phone does not smell like hot metal, which it totally did this morning.
The spacing of the nodes has been multiplied by 4 on each dimension, so I have to go 16 times the vertexes on each premade mesh. Those are currently a low +-250 vertices, so this should totally be doable!
I'm going to ignore the tricky math of setting up sloped tile sets etc, and just focus on testing whether my optimization tweaks make sense on mobile.
I'm thinking I might need to work with preset tiles rather than combine meshes into tiles at runtime. Which is actually fine by me, as I should be able to adapt the procedural generation to such presets quite quickly... And so 'Blockyworld' (working name) becomes more blocky again
Screenshot is from the editor, but it looks like this on the OP2 and it runs at 30fps and also the phone does not smell like hot metal, which it totally did this morning.
The spacing of the nodes has been multiplied by 4 on each dimension, so I have to go 16 times the vertexes on each premade mesh. Those are currently a low +-250 vertices, so this should totally be doable!
I'm going to ignore the tricky math of setting up sloped tile sets etc, and just focus on testing whether my optimization tweaks make sense on mobile.
Also, Unite LA (happening now) showed an example of a realtime tech demo of over 4million renderers, 5k AI objects, and 100k sound sources running @ 60fps and being streamed in and out in realtime (and playing on mobile).
Tests were pretty conclusive: swapping between low poly and high poly meshes gives me about 70% vsync time (which is where the processors are idling, waiting for another frame to come around so they can do stuff)
Simply having only high poly (which, they're 960 tris, 512 verts) meshes gives me excursions to 60ms (15fps) and in the end a GPU overload and crash.
So, Optimize!
The optimisation code, ran without position check, takes about 1-3% of CPU load at any given time.
So that's all good! But alas, it's a procrastinating, cherrypicking moonshot project, and it'll have to go back into the box, as soon as I add one more feature... maybe seven... Guys I need help.
0
KoopahTroopahThe koopas, the troopas.Philadelphia, PARegistered Userregular
Posts
https://youtu.be/prfBmdiI7jE
What it does:
-It, first of all, generates a landscape, with rivers and cities and such...
-It creates tiles and then switches off the render component, and then does a looping activation of tiles close to the player (unless they're already switched on, duh)
-It generates a mesh with a vertex for each tile
-Well, it's actually a row of meshes, as for some reason at about vertex 60,000 Unity doesn't write to the vertex list anymore.
Up next:
-make the row back into an array
-generate a lower poly (i.e. skipping vertexes) version of each mesh in the array
-maybe an even lower poly version
-switch off the renderers on these meshes so that the further they are the lower poly meshes are shown.
-generate a texture from the landscape tile data
-apply the texture(s) to the meshes...
So far I've put about two months off and on into it, so you can see why it's a moonshot...
Not to forget ShoutCast...
Unreal Engine 4 Developers Community.
I'm working on a cute little video game! Here's a link for you.
I hadn't thought of that, but it's interesting. Definitely one of the problems I'm having right now is that threat is sort of becoming either a "The tank will always be hit unless they're out of position" or "The tank cannot hold threat ever". A more robust positioning thing would probably let me find some other mechanic for the tank, and give options for things like the rogue being able to "dash in" and smack for extra damage as long as they can switch back from the tank.
Unfortunately, my progress is super slow these days with school, so it might be a while before I can try it out.
Google has yielded some decent info, but they put a lot of the burden on developers to comply with legal standards. I may just reach out to lawyer, but just want to be certain it is necessary first.
Our first game is now available for free on Google Play: Frontier: Isle of the Seven Gods
- Changing my fixed-precision number format struct to use an int instead of a long for its internal representation. This halves the size of my numbers in memory while still giving me enough number space to work with. (Because I'm writing 2D retro-throwback games, my unit of scale is the pixel. (Even) if a screen is 1920 pixels wide, and you divide all integer values by 1,000 for the three-digit precision, a level can still be about 2,000 screens wide. That is a lot of territory.) (Just like why I'm writing an ECS architecture from scratch, I'm using fixed precision with an integer backing store because it amuses me to do so.)
- Wrote the trig table for fixed-precision numbers. Rather than use any reasonably intelligent method of calculating trig functions, I instead do a lookup in a table indexed by the degrees and then lerp between the values. That is, the sine of 123.456 degrees is Lerp(sineTable[123], sineTable[124], 0.456). How did I get the trig table, though? A helper program written using Math.Sin(). Hey, it only has to be fixed-precision in the final product...
- Wrote a custom Newtonsoft de|serializer for fixed-precision. Whereas Newtonsoft could usually generate something like...
... my serializer sends it to a string so it looks more like...
Slightly more compact!
Also, because my random activity generator I use when I want to work on something but don't know what told me to do pixel art for an hour, I made this animation of a little monochrome squid:
This is the main character from 行く、イカ!, which is the game I'm targeting as a "minimum viable product" out of the engine. That's what Google Translate gives me when I put in "Go, Squid!" It's a shmup in which the earth is in peril, and the only thing that can save it from rampaging aliens is a squid that can shoot lasers out of its head for some reason.
https://youtu.be/ZGHI6mLOlPQ
The imperative of iku is Ike, which would give you Ike Ika, which I love :-D
Here's a decent breakdown of the basics: https://en.m.wikiversity.org/wiki/Japanese_Verb_Conjugation_-_Godan_Verbs
Either way, awesome work on your squid friend!
A native speaker would understand your meaning either way, so not a big deal. But it's my duty as a stickler to mention it.
Time to crash on the Xbox= 0.5 seconds.
Great start.
Sigh. Steam was so much simplier.
Add #if/#ifdef compiler switches to your game code for platform-specific code blocks!
Unreal Engine 4 Developers Community.
I'm working on a cute little video game! Here's a link for you.
Not directly game dev related, but this is also a useful trick for CSS Styles or JavaScript when developing websites. You can check browser width to trigger specific styles, or check browser type for code blocks as well.
Twitch: KoopahTroopah - Steam: Koopah
Can't do that. Afaik there are no platform check commands in unreal.
There most certainly are. Are you using Blueprints? http://api.unrealengine.com/INT/BlueprintAPI/Game/GetPlatformName/index.html
If not, here's more reference from the forums for checking the platform using "Target.platform" with c++ code.
Twitch: KoopahTroopah - Steam: Koopah
This seems to imply that there are (have to be logged into Github with UE-approved account to see): https://github.com/EpicGames/UnrealEngine/search?utf8=✓&q="ifdef+_Xbox"&type=
Several blocks there
Unreal Engine 4 Developers Community.
I'm working on a cute little video game! Here's a link for you.
Had finished shading the fingers when i realized i drew the wrong fucking arm.
It was from an overhead shot with light at an angle so i could not just reverse it, i tried
http://www.fallout3nexus.com/downloads/file.php?id=16534
I'm not sure of the best way to do this. It seems like I should make a separate level for each landscape, and then load them using the level streaming functions in blueprint? Apparently I can make multiple instances of a level and load it into a different position/rotation so this seems doable.
Yes you can but you need to use "Load Level Instanced" for what you want to do. "Load Stream Level" is for loading single instances sublevels that have been defined in the Levels windows in a fixed location. Also with "Load Level Instanced" you need to use the full asset name of the level [/game/maps/Level], not just its name [Level] but you'll figure that out pretty quickly when the editor throws you the level load errors.
I don't know how big your world is going to be but if the player travels far and fast make sure to use "Set World Origin Location" to avoid floating point errors when you start getting too far from center.
Twitch: KoopahTroopah - Steam: Koopah
I thought he was talking about sex ... but maybe my mind is in the gutter. No ... it's not a bug ... it's a feature.
Playstation: Dipuc4Life
Warframe_Switch IGN: ONVEBAL
No, I don't think we could restrict sex like that. I'm talking about dental flossing.
Twitch: KoopahTroopah - Steam: Koopah
And that gives this result, on a small landscape with (4*64) * (4*64) tile, i.e. 65,536 tiles originally...
4.000 meshes now!
https://youtu.be/nbwJIioZbpw
The next step, of course, is to apply the code I wrote to only render the tiles that are close enough to these blocks, and that should allow for a pretty sweet framerate on mobile...
edit: somehow the code to swap detailed for distant landscape meshes isn't tracking the player, so you're seeing the 'distant' mesh here instead of the detailed one. That's also why the player and the camera are clipping the landscape...
Yeah.
I got nothing...
I'm actually an adequate artist and should have been practicing my craft.
Edit: might as well use free video to put as title background
http://www.fallout3nexus.com/downloads/file.php?id=16534
Twitch: KoopahTroopah - Steam: Koopah
Not onto something that is far harder than game development, marketing.
Twitch: KoopahTroopah - Steam: Koopah
Going to progressively knock out stuff and see what is causing the issue, but since it's on Awake I have a hunch it's the seeded System.Random generation.
UPDATE
Funny thing is that the enormous amounts of trees you see in the image seem to be the problem- before they are even instantiated.
I'm going to instantiate a default cube instead and see what that gives...
UPDATE:
slow but it runs. (And, once running, can be optimized.)
But of course I don't want a super clever cubical landscape generator...
UPDATE:
with the 'standard' detail levels only it runs, but veeeryyy slow.
I'm thinking I might need to work with preset tiles rather than combine meshes into tiles at runtime. Which is actually fine by me, as I should be able to adapt the procedural generation to such presets quite quickly... And so 'Blockyworld' (working name) becomes more blocky again
Twitch: KoopahTroopah - Steam: Koopah
Screenshot is from the editor, but it looks like this on the OP2 and it runs at 30fps and also the phone does not smell like hot metal, which it totally did this morning.
The spacing of the nodes has been multiplied by 4 on each dimension, so I have to go 16 times the vertexes on each premade mesh. Those are currently a low +-250 vertices, so this should totally be doable!
I'm going to ignore the tricky math of setting up sloped tile sets etc, and just focus on testing whether my optimization tweaks make sense on mobile.
You may want to check out ECS, the job system, and burst compiler (if you haven't already). The Unity example goes form 15k objects on screen @ 30fps to 130k objects @30fps by switching away from mono and towards ECS, Jobs, and Burst. https://unity3d.com/learn/tutorials/topics/scripting/using-burst-compiler?playlist=17117
Also, Unite LA (happening now) showed an example of a realtime tech demo of over 4million renderers, 5k AI objects, and 100k sound sources running @ 60fps and being streamed in and out in realtime (and playing on mobile).
Simply having only high poly (which, they're 960 tris, 512 verts) meshes gives me excursions to 60ms (15fps) and in the end a GPU overload and crash.
So, Optimize!
The optimisation code, ran without position check, takes about 1-3% of CPU load at any given time.
So that's all good! But alas, it's a procrastinating, cherrypicking moonshot project, and it'll have to go back into the box, as soon as I add one more feature... maybe seven... Guys I need help.
Twitch: KoopahTroopah - Steam: Koopah