Amateur Gamedev General ~ /agdg/ /vm/

Free as in freedom edition


irc.rizon.net @ #8/agdg/
>>>/agdg/
>>>/vm/

Other urls found in this thread:

msdn.microsoft.com/en-us/library/ms173109.aspx
msdn.microsoft.com/en-us/library/fa0ab757.aspx
gamefromscratch.com/post/2015/06/28/MonoGame-Tutorial-Handling-Keyboard-Mouse-and-GamePad-Input.aspx
coursera.org/learn/game-programming
docs.unity3d.com/Manual/HOWTO-UseSkybox.html
http.developer.nvidia.com/GPUGems3/gpugems3_ch09.html
github.com/craftworkgames/MonoGame.Extended
answers.unity3d.com/questions/643942/how-does-setting-the-hideflags-resolves-leaking-is.html
imgur.com/gallery/pnjL0Gl
poal.me/92iuh1
docs.unity3d.com/ScriptReference/MonoBehaviour.OnValidate.html
docs.yoyogames.com/source/dadiospice/000_using gamemaker/006_sounds and music.html
soundcloud.com/zawazawazawachameleon
codingjargames.com/blog/2015/08/04/unity-and-initialization-order/
wiki.unity3d.com/index.php?title=Animating_Tiled_texture
docs.unity3d.com/Manual/BlenderAndRigify.html
learnrubythehardway.org/book/ex0.html
learnpythonthehardway.org/book/ex0.html
pastebin.com/5tE4Hpk5
forum.beyond3d.com/threads/yes-but-how-many-polygons-an-artist-blog-entry-with-interesting-numbers.39321/
spriters-resource.com/
twitter.com/NSFWRedditImage

Progress Report
So I got some shit working, and I'm going to make my game a bit juicier soon, I think.

Here's a demonstration of the room placement, combat, reward and level up systems. It crashes at the end.

so im at a major roadblock.
i've been making small vidya for a bit, but now i want to take on a larger project. pretty much all of my games before have all been written in my main file (C#/C++), but now i want to start understanding how to spread out my project over several files, store functions in classes, and create handlers/managers for things like my player and enemies, but im struggling with this.
i've done a couple searches for guides on stuff like this but i really dont know what to search to get what im looking for.

if any anons have any videos, written guides or otherwise would be appreciated.

I'd recommend on learning object oriented programming (OOP), and that's even if you use an ECS (entity component system) as a lot of the concepts are universally used in one form or another in other design patterns.
Here's a link to a quick overview from the official docs on C#, and you can use it to figure out your search terms, or figure out what you're looking for.
msdn.microsoft.com/en-us/library/ms173109.aspx
NOTE: ALWAYS USE DOCS FIRST

The particular terms you want look at on that page (and/or search for in conjunction with "OOP") are: inheritance (polymorphism, abstract classes), instanced classes (objects, via a constructor), static classes (like the System.Math static class), namespaces (modular-ize your code), encapsulation (sometimes called wrapper classes), and the rest you'll learn via delving into these topics.

update:
Basic mars terrain

Going from all code in one file to OOP is going to fuck you up so badly. Be prepared to waste a lot of your time if you do it.

What does /agdg/ think of the RPG that Holla Forums is making?

im just fucking struggling right now
i wanna cry

i cant even get my fucking movement code to run from my player class because C# wont pass variables set to null, so i keep getting crashes
i might just code my WHOLE FUCKING GAME in the main if i cant get this to work
whats the worst that will happen?

Playing around with 2d animation.

...

I don't know C# but when you say main file you mean file and then there's a bunch of functions in it right? You aren't writing everything in the game loop or something.

It's what they should've done in the first place anyways.


you're not going to last long as a game dev if learning a new topic makes you like this, and especially so if that's your reaction to now defunkt code

Bad practices, wasted time and code that could be put into learning best practices of OOP.

is the movement code in its own class?
If yea, then just instance it, using the new operator (which uses the constructor in your class).
Also, make sure it's exposed with the proper pre-fixes for scope (public, private, protected, etc)
So, f.e.
public class movementCode{//varsfloat speed;float somethingElse;//CONSTRUCTORpublic movementCode (float _speed, float _somethingElse = .5f){//initialize variables herespeed = _speed;//pre-initializedsomethingElse = _somethingElse;}//functions/etc herevoid faggots(){ Console.WriteLine ("faggots love em"); }}//ANOTHER SCRIPT//uses the movementCode classclass playerController{//instancing the movement class with new operator//initializes the vars specified by the movement class constructor//NOTE: somethingElse var is already pre-initialized, and doesn't need to be specified, but it can be if you wantmovementCode movement = new movementCode (1f);//functions/etc here//f.e. calling a function from movementCode class that is now instancedvoid dicks(){movement.faggots();}}

There's a shitty example of instancing a class from another script.

It's not really that hard, just read up on it, and try using it in some code.
You could even go with one of those online courses that has an instructor (like coursera, linda.com, etc).

nice art thou, and is that a tablet used for drawing or do u use an external peripheral?

I am almost done with that wig, maybe I'll add more freedom to the hair.

Learn C, use structs and function pointers.

im just frustrated.
you lost me right around there.
ive tried 3 different ways to write a working movement function in my player class.
i had so many useless variables and code after 2 hours i had to just scrap it

the other thing i notice in that block of code is, from what i can tell, its not taking sprite position into account
im understanding the OOP, what im having issues with is passing vector2s and keyboardstates through my function. since both default to null they wont fucking work.
god forbid i go looking for a tutorial, theres jack shit from what i've seen

What are you using?
Some godawfully documented engine?
bad idea if you're not well versed in at least oop, and can't just use source code to determine what is going on via your own knowledge.

There's example code in my post pointing out how to do this.

maybe start smaller, as essentially everyone here says.
First, do some basic shit like learning how to use OOP, and making basic, and I mean basic, programs.
Using something like coursera or linda.com (just for the language, as they go over OOP during the course)… and it'll make it way less frustrating; as they're instructors who guide you through it.
Also, always search the errors, and determine what is actually occurring before getting frustrated, as generally the fix is super easy once you know what is actually wrong.
As being a proficient programmer is in part knowing your stuff, and also being resourceful.

you need to initialize them before using them, else you get a nullreference error… do this via the new operator as my example post pointed out.
DOCS:
msdn.microsoft.com/en-us/library/fa0ab757.aspx

The only problem with C is low level fuck ups. I do like the idea of destructors in C++.

monogame; well documented but literally 1 ok tutorial, the others stand to be some of the worst tutorials ive ever fucking seen
ive done small stuff, as ive said.
im trying to move a step up by modulating my code, but as ive said, im having a hard time affecting variables in my main using functions ive coded in classes
i tried initializing them in the initialize() function in main, to no avail
if i write Class1 obj = new Class1();
in an update function its just going to create a new class every 60 seconds, and since ive already tried that i can say, it doesnt make it move.

whats frustrating here is how lost i feel and not being able to find a single answer

sorry for being a major cunt but i know if i dont keep at it im just going to go back to being a nodev and not doing what i want to makes me feel like shit

Thank you. I used a reference for the sketch, but changed a lot of it so it doesn't look the same any more. Just needed a motivation.

It's a Surface Pro 3. It came with 8.1, but I decided to try the update. It's basically the same, but slightly more glitchy now, ha

With blue eyes. I only wonder how this will make people's heads spin. Makes me laugh to think about it.

Google "The Cat Anderson" he was a black musician, with blue eyes, hence the nickname.

Is there a market for indie games in arcade machines? (My game pictured)

cabinet colors and controller temporary for showing it off

Maybe at barcades.

Yeah, the place making the arcade machines will be a barcade type place. They plan to showcase there and sell to other business.

ah, I don't use monogame… so I don't have specific answers, but I'm sure someone else here could chime in on the specifics.

Try getting at least some output (like console output) in monogame's equivalent to a start/initialize function (executes when the game is initialized); so you can at least initialize classes.
Debug it until you can at least get it to output something small.

usually the update function is called once per frame
You want to use the update function for something like polling your input class (polling basically means checking if there's any new inputs, f.e. to the input class, such as a directional key).

that can be extremely frustrating, and I sympathize.
Although, if I were you I'd use all the tutorials possible on monogame to get familiar on how it works (even if they're shit tuts), and/or look at some github source code on how to do this.
Tut for inputs:
gamefromscratch.com/post/2015/06/28/MonoGame-Tutorial-Handling-Keyboard-Mouse-and-GamePad-Input.aspx
coursera overview tut for monogame:
coursera.org/learn/game-programming


how accurate is it for using a stylus?


that's pretty bad ass satan, nice.

You don't need to initialize a class in the initialize/start function btw.
You could do the same as my example here>>9875238

sage for correction/clarification

Whats the best way to create cartoony sky boxes for Unity?
All the tutorials are on importing HDRI images or using the default ones

docs.unity3d.com/Manual/HOWTO-UseSkybox.html
To actually make the skybox look, and have it be catroony (as it's just images), you'd have to draw them and/or create them in ps using some brushes + adding cartoony effects.

I'm just at a low level of understanding.
If I knew how to do half of that I would.

I just want to get into a workflow so I can begin tweaking things

thanks

i was being sarcastic user, and no worries most people don't.

good luck, and good plan!

What? That's not even a thing

When you pass a variable, it depends on the variable's type semantics. If it's a value-type, then the value itself is copied to the function (which can be locally modified no problem). If it's a variable with reference-type semantics, then a copy of the reference is passed to the function, eg if you have an array of int[], the function can change the reference it uses to a different array, but values changed here will affect the original array.

Monogame is basically a wrapper around XNA (which is what I use)

When you start a new project, you have a default Game class that contains Update, Draw, LoadContent methods, etc. You'd set some kind of global variables (within the Game class itself), and then in the update function, you'd give it logic to do.

For example, you could add a simple Vector2 to the game class to track the player's position. Vector2 has two parts to it, X and Y. You can do something like "Vector2 player = new Vector2(100,100);" to give them an initial position.

Then, in the update, you'd do something like:
protected sealed override Update(Gametime time){ // Gets a copy of the current KB state, we only need to call this once per update, // eg we wouldn't call Keyboard.GetState().DoSomething every time KeyboardState state = Keyboard.GetState(); // Polls the state to see if a key (right) is down (pressed/active) if (state.IsKeyDown(Keys.Right)) { player.X += 4.00f; // move right by 4 pixels }}

I think the 3 only had 256 levels of sensitivity. But the 4 improves this, and I can only imagine the 5 will be incredible. Microsoft has impressed me with this series of devices. The one I'm using is the cheapest model for 800 smackers, but the 4 GB of RAM and the quad core processors hold up amazingly well. I even edited a couple of images that were 20k by 9k pixels, and it didn't crash.

More 2d junk I have no idea what I'm going to do with.

Adding variable wall heights was 100% harder than it needed to be, because it fucked with the ceilings and there was a bug in their generation.

How unfun does this look?

It'd be more fun if you automatically landed on that one on the bottom left. That's fun, right?

If you're attempting to end up on that last little plateau, it pisses me off to no end. Otherwise it seems like a thing I'd have to do to progress, rather than a thing that stands out specifically as fun. It's still nifty though.

if you dont mind me asking
what tilemapper do you use?

procedural generation is a bitch.

Does anyone know how to get good dynamic global illumination going on in UE4? I've tried out the Light Propagation Volume, but I get low res splotches of lighter coloured walls.

Pic related is how interiors look without any sort of GI, only a SkyLight and a movable directional light is applied, plus some AO. It doesn't look too decent.

Well, that's impressive. What's your end goal?

Decided to write my own Blender exporter.

Came to a major issue I can't fucking get around.

Pic related. The vector holds weird values that just aren't representative of the vertex co-ordinates - but when I print them, they're okay. I just can't OUTPUT THEM TO THE FUCKING FILE WITH A PRINT.

Anyone care to explain to me what the fuck this is about?

did you make the roof non light blocking? I mean it's gonna look shit anyway, but it looks like you're getting duty light or something because there's no light in your level

No, fam. There is light in my level. The thing is, it's indoors. Here's a look from just outside the building's entrance, you can see the shadows being generated.

What do you mean by duty light?

Needs casting to a float.

print('%f %f %f' % (verts[0].co.x, verts[0].co.y, verts[0].co.z))

Wrong link.

The sun casts a directional light. There should be shadows on the inside of the building.
My first bet would be that your UVs are wrong. You need a separate set for textures and lightmaps.

Inventory is coming along nicely

Really? I thought that directional lights only could have shadows that tone down colours uniformly, regardless of distance from shadow caster, or distance from lighted areas.

By the way, lighting is completely dynamic, no baking. How would lightmaps influence?

Directional lights are lights with a) no origin (all shadows go in the same direction rather than run towards a point) and b) (often) infinite distance. Other than that they work exactly like point lights.

You still need to bake lighting. Now, I am not 100% sure, but if memory serves, Unreal uses the same approach as Unity in that you have a semi-dynamic lighting model. You bake static lights (because why wouldn't you?) and GI information, because good looking realtime GI doesn't work without doing some heavy calculations beforehand.
The limit of these systems is that your level geometry isn't allowed to change. Dynamic GI only works on static geometry.

You keep the momentum you had in the direction the pad isn't facing though.I don't really want top down platforming sections TBH anyways, I just wanted to see what other people thought.


TileD

Anything relating to light is either normals (used by the vert shaders for light direction, and pixel shaders to fill this in using the specific lighting model), and tangents (used by vert shaders to perturb normals, and same as normals for pixel shaders).
UVs are for the texture coordinates, and you'd immediately see if they were incorrect due to stretching/tearing of textures.


It's an issue with your shader, or normals of your mesh.
What lighting model are you using, and I can be more specific; also is it a custom or prebuilt shader?
If u want, u can post your shader code so I can check it.
Also, grab a shader that displays your normals, and make sure you're setting up your normals correctly (it'll display the direction of normals on your mesh).

So, your lighting looks way too "drab", meaning, even lighting levels across everything (even with those shadows, as that's something like ssao)… this can occur for a few reasons.
It looks like it's not accounting for the direction of normals (grabbing this in vertex shader step, passing to pixel shader), and/or isn't being accounted for in the actual step of determining the light direction when coloring in each fragment (pixel shader step, which is based on the steps taken via the lighting model function you have setup).

It could be as simple as not having reflectivity/specular checked, normals being miscalculated, or a missing step in the shader.


You can have fully dynamic lighting as long as your shader accounts for the changing of position of a light source in the shader; as normals are a moot point and essentially just tell what direction the surface faces and hence light should reflect (i.e. no need to be recalculated, unless you changed the actual surface).
Unity has a command to do this in their shaders, i.e. accounting for each light source per frame, but I'm not sure about Unreal.

You need them for lighting too. You always have a separate set of lightmap UVs, because lightmapping requires UVs that fulfill a few conditions "normal" UVs usually don't. If I'm not mistaken, those UVs are also required for realtime GI.


I was talking about realtime GI there. It needs a lot of pre-processing.

I hope C64-user is doing fine.

[NSFW] Warning, nude alien progress on making my animu look more 2D.

Ah, I missed that post of his pointing that out, and also I have no experience with GI (just looked it up actually, looks legit).

welp, fuck me right, wasted my time posting that fucking wall of text

No, no, I have my directional light set to Movable, which doesn't have any sort of static lighting whatsoever. I don't need to bake lighting, because all lighting is dynamic when selecting this option. I did this because I have huge levels that would take forever to build lighting for.

I think it's the normals, I'll check it out.

Forgot my pic.

Where can I get game art like this

NOTE: I have no idea if that applies to GI, as i have no experience with it (my post only applies to lighting models like phong, lambert, and pbr).

I'm looking over the GI algorithm atm and this user seems spot on >>9885330
As it requires a different set of UVs for lighting as seen here http.developer.nvidia.com/GPUGems3/gpugems3_ch09.html at the bottom of the page for the vertex shader pre-processing step.


I believe that user did all of that by hand.

The lights don't have to be static, but the geometry has for it to work. That's the point of the pre-processing. You get to turn lights on/off while keeping all the nice and fancy realtime GI.
Why not just try it out and see what happens?
There is a "Build Lighting Only" button in the build menu.

how old are you?
answer just for me, pls.

thanks, but its not quite as impressive when you know that ive basicly given up on real procedural generation. right now im basicly building handcrafted 5x5 tiles modules that fit together and proceduraly generate a map out of those. the original plan was to do it on a room by room basis, but that gets realy fucking complex realy fast and for our purpose the current solution may well be better.

the endgoal is to have a mazelike and not quite linear level that still forces the player in one direction by closeing specific doors behind him. there are a few bossfights on the way and an endboss at the end and weapons and other items on the way that will help you.
basicly a roguelike, except that the term has been run into the ground and means almost nothing now.

you are playing as a teddy who fights the nightmares of his owner. so you start out with a wood sword and some ductape to patch yourself up.
in terms of gameplay we are going into the direction of dark souls. relatively slow paced third person melee combat. thats coming along quite nicely, but right now we're focused on getting a level done so we can see how it plays.

Now I have an AI that hangs out at a spot, then comes up and kisses the player when they fire a gun.

But seriously, this is a WIP. Eventually the AI will be guarding a point, I just haven't set up the part that lets the AI react to seeing the player, so they go to where the sound was made then go back.

Slap an anime girl face on it and give it have a chu~ sound effect

Holy fuck that song is catchy as fuck and that boss is cool

are you using this?
github.com/craftworkgames/MonoGame.Extended
or one of the other options?
if you are using monogame extended, is it worth it?

Here we go, this will be a nightmare.

What are you doing nigga put more edges for each toe

I am just getting started.

hey guys. Sorry for all the stupid questions.

Why isn't this guy going into the idle animation. Am I missing a step here?

Do you have the animator attached to the gameobject (your moonman), with the controller component in the controller field of the animator?
Once you have this, it should at least have the idle, because the animator will know what state machine it's working with.

To actually transition from idle -> walk, you'll need a parameter setup in the statemachine, which you'll need to update from a script; then you'll need to set this basic logic (conditions to switch to/from states) in the statemachine for the transition.
To do the code part, you'll need to have a reference to the animator in your script, and you'll need to use the setFloat/set"Insert data type here" to actually set the value in the state machine.
so.. f.e. (have in a monobehaviour script attached to your moonman + with animator on same GO for it to work).

//outside of class deceleration[RequireComponent (typeof (Rigidbody))][RequireComponent (typeof (Animator))]//inside classAnimator anim = gameObject.getComponent();Rigidbody rig = gameObject.GetComponent ();float speed;void animatorStuff(){//get the linear velocity, that has been changed from world to local space (going forward is positive, etc)speed = transform.InverseTransformDirection(rig.velocity).z;//setting param in animator//parameter name in animator is "linearVelocity", without quotesanim.SetFloat ("linearVelocity", speed);}//if you use a rigidbody to move your character use fixedUpdatevoid FixedUpdate (){animatorStuff();}

may have spelling errors, did it by hand from memory

Manage to make a simple demo in Irrlicht by following the tutorials. Gonna optimize the code tomorrow and add in audio. Gonna make some Kraft Mac'n'cheese now.

crit on the facial proportions please
(the eyes and the face are seperate, so ignore shitgons)

I want to make it more fappable/cute

Something is odd about the ear, maybe some roundness around the eye sockets.

ayy lmao

When you think about it, if you took anime girls and made them bald, no clothing just the way I like, and made them all white they would look exactly like aliens.

Yeah hair that long should be bouncing in an almost wave like pattern when running

Ear looks like some kind of Shrek ear. Fix it

Nondescript errors that don't even point to locations in code. They just exist. Without fail, when googled, they'll have been 'fixed' months or years ago.

It's the same with the mysterious ABBA error that's caused by unity's particles leaking from the game into the editor after you exit play mode. It sounds even more asinine when I say it.

Are you putting the all the flaws that you're documenting in a pastebin or something fam?
I'm really, really interested to see the end result someday.

Yeah.

And this isn't exactly something with the engine, but the closest thing they have to documentation for some of their newer features is shitty blog posts. What exactly does "Google Play Store-specific product identifier subscription product." mean?

That's an assertion and it's an engine-internal error. The reasons why it doesn't point you towards some code are because a) your code isn't the problem and b) it's somewhere deep inside the compiled Unity binaries.
Those are extremely rare. The only place where I saw them frequently was the Unity 5.4 BETA.
Not being too helpful isn't that big a deal considering you're not even in the position to fix them.

If it happens again or you find a way to reproduce it, submit a bug report.

what you're plan with google play store?
Was crashing your game with no survivors apart of your plan?


have you tried hideflags?
That'll probably fix it, and here's the reasoning behind that:
answers.unity3d.com/questions/643942/how-does-setting-the-hideflags-resolves-leaking-is.html

what's your plan*
fuggin a, i fucked that up hah

I already sent it to my client, he liked it, now I need to retopo that model, I think I will only rework the general body shapes since the face may not need that much work to begin with.

I'm programming something for an Indian guy.

Well now the animation works but I'm back to my original problem I thought I fixed.

Without having the actual project open, and not knowing what you changed; I'd be making shots in the dark as to the exact cause.
Although, I can give you some rudimentary advice… do some basic troubleshooting, i.e. disable components until you determine what's offsetting the transform position of your model when you initialize your game, and then once you've found the culprit adjust it accordingly.

I added bees
That was a fun diversion

Im pretty sure I exported it incorrectly. But I'm really not sure how.
Thanks anyway

imgur.com/gallery/pnjL0Gl

wwwww

Anyone here have experience writing domains for HTN planners? I'm having a bit of trouble writing them.

...

Hey, I just heard that guy who did the cyberpunk barman game was from here.

Though I'd say congrats.

For memes, and to monitor normalfag tastes/values

I took a screenshot earlier today for specifically this situation

It's a complete and absolute mess, trash it and start over.

imgur is literally reddit territory
this is beyond the point of irony
you disgust me

well, if you frequent reddit, you can't really ignore imgur :)

Do you want to make games for profit, or because you want to make the game?

>>>poal.me/92iuh1

Surprisingly, they realize that mass immigration fucks up a country and that trannies need mental help.

Well, if my poll of like 5 answers is correct than /agdg/ might benefit from over the net teamwork, why don't we see this very much?
autism and paranoia?

I feel like a modern game dev already. Just need a twitter account and a patreon.

Why aren't you making a game of a genre you love?

So I've been trying to decide what engine/libraries I want to use to make a 2D game and I'm having trouble. Part of me wants to save time by using an engine like Godot or Love2D, but after trying those out I was pretty dissatisfied. Godot is great, but little documentation and GDscript are annoying. Also, Nodes. While they are a nice way of organizing your game and establishing an object-oriented hierarchy, trees can incur a lot of overhead and if they get too big they become more of a hindrance than a help. Plus, the engine just feels unfinished; although I might use it in the future depending on how it changes. Love2D was also nice, but I'm not a big fan of Lua.

In short, I guess I'm having trouble picking the right framework for my game. How did you guys decide on a framework for your game? Right now I'm picking up SFML to see if I like it, and I'm enjoying it so far.

Time, money, ability. I'd like to actually make a full game before I run out of time. And it turns out most projects take far too many years for me to waste.

Hopefully I'll have something to show in the near future, even if some of the mechanics and their inspirations are a bit weird.

I am not confident enough in my skills to contribute.
I want to make at least one polished work before going in headfirst.

I also like to be able to control everything

Fair enough, but sometimes I wonder if a dedicated group of shitters could make something good, especially with how the hobby is currently


But I suspect most folks have this problem and it would fall apart as a result.

I wouldn't mind making something simple and fun.

problem is that I am this guy
and don't even understand how to plug in the simplest things without my hand being held.

speaking of which.
Map update

decided on more bees
can't have enough bees

That's actually quite nice, user!

...

you already know

What size do you think would be good for the standard low level enemy?
I'm thinking I could keep them at varied sizes like this

a y y l m a o

You going to have kush smoking ayyliens?

Maybe as a joke I'll throw a really slow one in with a blunt.

But their death sound will bee a squeaky "ayy"

Sounds great.

Thanks! You'd be appalled if you saw the code.
I was lazy and used LINQ for half of it

kek

Really good movement with the hair, along with the body.

Another gun for the gun pile. The theme of this one is "compromise." As it, how much sickass looking detail are you willing to part with so you can meet your geometry goal. It's ok though, because my baby is beautiful no matter what her polycount is.

This time I made the darling of videogames and the most aesthetically pleasing shotgun to grace our precious Earth: the illustrious, the gorgeous, the sexual, the spitting image of beauty, the SPAS-12. Oh, if she were only as flawless IRL as her stunning looks let on. R8, h8, masturb8 (Lord knows I did. A lot)

When I open the editor again, several objects have leaked from gameplay into the scene file

what

Looks neat as fuck. Would it be possible to make it so that the bees move faster and more erratically when the box is moved?

While I'm at it, the OnValidate function is godawful. It runs when the editor starts, and when it closes, and gives no indication of why its running or what property changed in the editor; It just runs.

I think making them move faster and spread out would do that.

meant to quote this guy

One more animation hammered out subject to improvement

I am not fast at this

did you end up saving prefabs while the game was running?
i wouldn't do that

this is a PS1-level night terror

I Instantiated some GameObjects on the OnValidate function which seems to fire before and after the game is actually running. Creating something in that timeframe causes it to leak into the editor.

My mistake, but the OnValidate function in the Unity Docs mentions nothing about when it fucking fires or that this could lead to the editor crashing and altering the scene file.

not to be an ass, but…

docs.unity3d.com/ScriptReference/MonoBehaviour.OnValidate.html

What?

someone needs something playtested?

Not to make you look like an ass, but can you tell me exactly when it considers a value changed without running a bunch of tests yourself?

Image related is the code I just added.
Two validations when saving the code.
Three more when running the code.
One more when closing the game

Completely fucking arbitrary. Any reasonable person would expect it to fire when someone changes a value on the inspector; It does it 6 times on its own.

As someone who is absolute shit at drawing, would it be possible to git gud at making sprites n sheit assuming I give it my all?


Also where exactly do I start? Do I just jump in making a vidya in whatever engine or do I need to know something beforehand or what? I know very little of python and java and had picked up a book about C++ that I had started a few days ago.

Eh… you really want to know the basics of drawing, especially anatomy, for pixel art. Pixel art is just a very low res drawing. The only caveat with pixel art is it lets you skip detail, but you can't skip the other groundwork you need for a good drawing.

Look what I found.

I was talking more SNK quality sprite art

Unrealbro, do you have an email that I could contact you with in the future if I need your help implementing stuff for a shooter?

I bookmarked a bunch of stuff you pointed out a few threads ago, but I figure it would be good to have you as a backup plan in case I'm too retarded to get something working on my own.

Is it really outside the realm of possibility that someone might do it for both?

Just ask here you nigger. I have a whole bunch of network replicated shooter and rpg mechanics all set up.

Anyone know shit about why audio put into Game Maker often sounds tinny?

The fuck is everybody?

Programming, I bet!

Working on my game.
I need to wrap my head around how I can add blueprint components from C++ code in Unreal 4.

Check what GM does to the audio files. It may compresses the audio to the point of it sounding crap.

It's Canada Day / American Holiday

Also I'm too busy being upset at how I'll be a fucking useless nodev all my life, despite having good technical knowledge

That's where I was between those two posts, but I somewhat expected at least a few people to be around and nodevving long enough to answer the question within an hour and fifteen minutes. I don't know if I'm worried or proud.

It definitely does some amount of compression. At the very least, it specifically mentions that it's converting the file type, but I don't know what settings to give it to make it not do that. I tried giving it the same conversion instructions as what it started with, but it still sounds weird. You'd think that a sound file simple enough to be played on the GBA (recorded from an emulator) would be left unmolested.

programming while i wait for valkyria chronicles to be finished downloading

almost wrapped my head around monogame
still debating if i should get rid of my botched float to int function i shoehorned in to make muh vector2s work
i could just make 2 int variables and replace the draw and movement code with the ints, but that would feel a bit to much like giving up

docs.yoyogames.com/source/dadiospice/000_using gamemaker/006_sounds and music.html

I bet none of you fags even use unit tests. All of you are horrible """programmers"""

wrong nigga, nigga

oh fuck no im not, im just some idiot doing what i gotta do to make the vidya i've always wanted to
if i knew what i was doing i would be finished already

I am an artist, not a programmer, so joke is on you.

get a load of this pajeet

worked some more on the unit list. This weekend im going to add more naval an air units, and make more placeholder sprites. Progress is slow but steady

Who you callin' "nigga", nigga?

He sayin' I'm the nigga you wuz s'pozed to be quotin', nigga.

Thanks.

I see. Thanks for clarifying nigga

im calling you a nig, ya nog!

I take it you already finished your game, given that you have the time to shitpost here.
So, where is it?

It's never a guarantee that someone will still be posting here in the future.

Anyone figured out if it is possible to decompile cooked unreal 4 projects? Epic has an exe in the binaries folder called UnrealPak.exe that is capable of decompiling pak files but all the files are fucked when you try to open them.

Would like to get my hands on this "Active Ragdoll" system from the marketplace but the dev is a faggot and is charging 12€ for it. It is something rather simple and I've been trying to figure it out on my own to no avail. He released a demo and I managed to decompile the demo he released, even getting a uproject that I could start but whenever I try to launch it it just complains that the files are fucked or something. Even just importing some of the files into a fresh project just fucks everything up. Any ideas on how to get it to decompile properly? Or if anyone has figured out active ragdolls in general. (in Unreal 4)

That's a big concern of mine, really. I'm worried that people will try to tamper with the game it's an online game, so cheating is a thing to worry about. Personally, I have no idea, but in your case, you could try torrenting that system. You could try public trackers, or CGPeers, which is a private tracker that specializes in shit from asset stores.

I have access to CgPeers, sadly nobody has uploaded it. But I guess I'll have to keep an eye out.
And even if people managed to decompile it and mess with it. I doubt they can put it back together and launch it as a "legit" version of the game and connect to the online system. Shouldn't be too hard to stop.

nowhere near finished, i was tabbing back in because i was reading something
now im off to play valkyria
happy Canada day nerds

lel

It shouldn't be complicated. It should just be blending an animation over the ragdoll but unreal is a bitch. The concept of it isn't complicated is what I'm saying. But I agree with you, I shouldn't be struggling with this.

Can I us-ably run photoshop in a windows vm? I have an i7 2600k, a radeon 480, and 16gig ram.

an user made it
soundcloud.com/zawazawazawachameleon

Holy shit I want this so bad. Seriously, that is such a cool idea.

looks good, user

Might be nice to add hair on top too pic related, kinda looks like a dome. Looks very good though.

The outline I got was a hime cut basically.

cuck

No matter how many times I plan stuff out on paper, my ideas for games are always RPGs.

Should I stick to making something basic purely for myself (platformers,etc)- or should I dive in the deep end and learn to make an RPG if that's what I want my "wheelhouse" to be?

What should I be looking at to make an RPG? I've heard RPG Maker produces diamonds in the rough, but without decent graphics/art style its hard to stand out from the trash. Freedom of options when coding is priority 1.

i personally would not, my biggest reason is because of ruby. Ruby was my first programming language besides a couple other small little things like batch, and even then i hated it.
if you want to make an RPG, i would reccomend game maker. its stupidly easy to build prototypes for games, and will give you the free time to draw sprites that arent 16 bit trash and even maybe make some music. Theres a lot of decent tutorials for game maker RPGs on youtube, and a lot of what they teach will transfer over to pretty much any game that isnt a 2d platformer
i remember spending a morning following tutorials and i had a whole small little game done.

ganbare user!

Thank you!

Is the price of access worth it, or should I "borrow it from a friend"?
Or do I need to pay some licensing shenanigans before I even start a project if I intend to sell it?

oh, in that case, it's perfect

Sorry to double post- but do you mean Yoyo games Game maker?

I can't see the tutorials on their website, but other people have made them.

Their showcase looks brilliant- but the games on their own "client" that lets you download other people's stuff looked jank ass and brower game-tier as fuck.

Is it purely art style- or does making Game Maker games look good a challenge?
Not that a challenge ain't fun mind you.

you need to have your own license or you'll cause shit to get fucky, at least that was my problem. i kept logging in and using my key on 2 different computers and it was confusing the shit out of the client or something
just start using the free version until it goes on sale
its all the same except the free one doesnt let you change splashscreen and shit like that
they dont make the tutorials, just go youtube search game maker tutorials

the other thing i reccomend is to read over their documentation
its really top notch
if you're in gamemaker i believe the hotkey is f1 or f2 to bring it up
not at all
it all depends on what you make and how you put it together

as for it being for browser tier games, i direct you to go look at their showcase. a lot of decent 2D games are in game maker. its not as much for programmers as it is for "content creators"
you still work with code, but its easy enough to where you only really need to understand the BASIC BASIC syntax of GML and game logic
and GML is very lenient with it's syntax
anyways im gonna stop shilling, if you have any more questions google's better off to answer than I

Yeah sorry, I saw the client list first before the showcase. Hence the deleted post.

Thanks for all your help man!

Now I just need a decent PC. Not that the Game-Maker is that intensive, buy my potato tier laptop doesn't meet the specs for the graphics.
Which really kills me since I have no income, and it's on sale now.
I think I might peruse the tutorials until I get the money together. I'm really hoping my /tg/ project takes off because otherwise I can't see "Well, I need a career switch. Mom can I have some money for a career that's another gamble" would go over well. "Just get a job" like that's possible just like it was 20/30 odd years ago.

POST.
SPECS.

Processor:
Pentium(R) Dual-Core CPU T4500 @ 2.30GHz

RAM:
4.0 GB

Video Card:
Mobile Intel(R) 4 Series Express Chipset Family x2
That's 1.7GB (64 Dedicated) each. Yet, it behaves like it only has one, I swear.

The only games I've been able to run in the last few years were Terraria and some 3D robot online game.

On system requirement labs I am in the 11th percentile.

Life is hell.

But, maybe I can run it.
Testing on Can I Run It says I can't run Hotline but I can run Deadbolt.

Wait, I got my MB to GB conversion wrong. I've got MORE than enough to do this!
Hot-damn!!

You need a new PC, user. A proper desktop.
Please tell me, you don't live in a third world shithole.

user, there's "able to run" and there's "able to properly work on".

Anyone know how to make an animated texture run in unity?
Everything online says I need to buy unity pro or write a script.

Just want to have the word "buy" moving around on the screen. Which I can make in a gif or multi-image format. How do I import and use it?

Unity pro the feature you're looking for, with animated textures. You can do it yourself, but that'd require using a script. Because the feature exists and you aren't allowed to use it.

Seems simple enough, right? Make the screen a separate plane or texture, and then adjust the UV coordinates in code.

In Ren'py, how can I replace a character's name with an image that appears whenever they talk?
Trying to get it to look like the mockup

The new independent country of britbong. So next election could make it a new empire, or a caliphate.


I'm hopping it'll be the latter.
I assume it's not possible to make a game you can't test on a rig, since it'd just grind to a halt during the compiling or when you run it it'll just stop.

True, but I can almost guarantee that I will be.

Well that's odd, the docs are generally pretty concise about monobehaviour related functions.

There has to be a good reason for that.
I did an exact replication of that, in a new scene, and it fired three times (two makes sense, but not three).

Here's a good article though, which made the onValidate behavior make a bit more sense to me:
codingjargames.com/blog/2015/08/04/unity-and-initialization-order/


there's a pretty simple script to do that on the unity community wiki, which essentially makes it drag and drop.
wiki.unity3d.com/index.php?title=Animating_Tiled_texture

thanks guys

Calling any freetards out here: is there an 'acceptable' F/OSS alternative to Clickteam Fusion or Construct 2 yet? Because that shit's what i grew up toying around with ever rarely.

Still sticking to Godot once their 3D/Vulkan overhaul comes around

Have any UE4 anons had troubles getting multiplayer to work over the internet? I've gotten LAN to work.
It's almost certainly something with my router after going through and doing all the port forwarding and firewall exceptions.
Are any anons intergrating miniupnp or NAT punchthrough? i want to stay away from steam as much as possible.

Hey guys. Before I waste a lot of time.
Can you animate a mesh then delete its bones?

I'm not sure at what point in this tutorial it wants me to animate
docs.unity3d.com/Manual/BlenderAndRigify.html

I'm no expert, but to my knowledge, it's borderline impossible to animate with out bones, since animations are actually deformations of the mesh, and which parts are being deformed are defined by the bones, the movement of which based on the tracking of the movement of the bones.

AFAIK with my limited animation experience, yes, bones are required to do animations with models using the Unity animation system (i'll get back to how to animation without bones later, but it's a bit off topic…).

I read that tut, and it seems that the rigify plugin adds two sets of bones, one set of deformation bones (one you want), and one set of WGT bones (one you want to delete).
I.e. animate just with deformation bones.
So, it appears to be a compatibility/clutter issue, and is essentially telling you to eliminate the set of bones not being used in the unity animator tool.

Animating without bones is generally only applicable to visual effects, and this is in the context of deforming a mesh via a vertex shader (generally using some noise, pre-programmed deformation, or a repeatable pattern like sin waves).
It's generally used for something like waves, bullet holes, lava, or something along those lines.

Got enemy AI working for muh space game

With prediction targetting and physics based flight

redid the ear

and I threw away the head and remaking it to give it that better 2D look

Which online subsystem are you using? If you use Steam, and you have the Steam app test ID, which is 480, you won't be able to find servers worldwide, that ID has a sort of region lock.

IMO you want to have name AND picture.
I don't know why, but I've seen most VN style chat boxes do it.

Plus, you can then have multiple people in one scene, and don't have to have the sprites constantly dissappear and reappear.

This might all be personal taste tho.

Attn 3D modelling fags:

Does anyone know a good place for an absolute beginner to pick up tutorials? I feel like my google-fu is shit and would like a nice source that kind of has an all-in-one (modelling, UV unwrapping, texturing, rigging, animating etc.)

Embed related goes through all the steps for simple characters.

Could you be a bit more specific?

If you'd stick around this community you'd find that in fact the majority are not programmers, and most that do program have very little idea what they're doing.

could you fedora any harder?

I'm not sure, but I think that he meant that the anons in these threads aren't »real« programmers, not that gamedev isn't »real« programming.

Cross-board links require three chevrons.
>>>/agdg/21934
and
>>>/agdg/24909

I'm really tearing up because of this. I'm trying to get an event to fire in every client in a multiplayer environment at the same time, when a boolean variable is changed. Previously, I was checking in every tick if the variable was true, and if it was, I'd execute the following logic. Though of course, this is inefficient. How can I do this?

I forgot to say that I'm doing this in UE4 and Blueprints.

WIP level editor in my 3d game engine

What I wanted to do was have a different-colored nametag for each character.
Maybe that's too complex, I dunno. I still barely know the basics of ren'py

Did you watch embed related?
This one should be the relevant video but the playlist is a good explanation of how blueprints interact with MP.
(The Playlist link should be in the description.)

...

No, that's not what I mean. I know how function replication works already.

On my first pic, you can see my game state script's logic for when the round ends. This logic has, in turn, to trigger the logic on each player character script connected to the server. The last node in the first pic calls the event depicted in the second pic, which at the same time rund the logic needed on the player character script. However, when I do it like this, it only runs on one player, not on everyone.

Note that I don't know shit about Blueprints but could it be because you are targeting the Player before sending the event (Maybe its sending it to just one player instead of only one player reacting?,I mean the function is replicated to ALL but if its target is a specific player the others wouldn't act as intended yeah?)

That's pretty much my problem. I don't know of any way to target every player.

You could try targeting a specific object that is the same in every client and have it trigger a local end function.
While its quite roundabout,It should at least let you know if its a problem with the event being recieved or with its targeting.

Alright, somebody explain this shit to me, 'cause I just spent like 2 hours ready to kill someone. (In Game Maker.)

I have a text box which does a typewriter effect, typing one character at a time. In order to allow the player to skip text, I have an if statement saying that if they press Z or X before it's done, then it skips the typewriting and just immediately displays the whole message. If they press it again, it continues to the next message. However, if I write it as in the first image, where the check for Z and X are in the same statement, it always evaluates to true on the first message, and the whole body of text is immediately there. This should be impossible, since none of the three conditions are true. It's as though either Z or X is being pressed immediately for one frame when the text box is brought up. I confirmed that it's this particular statement with the draw_text function there, which flashes for one frame when that statement is true. It shouldn't be a conflict, either, since the box is brought up with A.

But for some fucking reason, if I separate it into two statements, like in image 2, it works just fine. What gives? Is there something I don't know about ord(), or using ||?

Actually, this isn't even true either, because even if it was, the text still hasn't been displayed all the way, so it can't meet all of the conditions.

Install Godot

...

if (keyboard_check_pressed(ord("X")) || keyboard_check_pressed(ord("Z")) %% time < text_length) { // ...

That works, (sans the typo,) but if that's how it's meant to be, then I don't understand why it's worked elsewhere now. Thanks.

Pure luck, that it didn't break in an obvious fashion.
Do you understand why your code is wrong, or should I explain? It's important to understand your code, not just write something that seems to work at the moment.

My understanding now is that, for whatever reason, keyboard_check_pressed() not able to intelligently use ||, however, I don't understand why that's the case. I understood || to be relatively universal, or something understood by GML as a whole, not by individual functions, so I'm not sure what to think now. Knowing that ord() returns a unicode character's value, I thought that it was the same as saying "If it's this value or that value."

Do you understand how enumerable types work (in general, not just GML)? They're basically a label applied to specific value and backed by a value type (usually an int)

In most cases, you can also use bitwise operators (such as || ) to set individual bits, and also treat said bit value combinations as "flags". In C#, for example, you could see something like:

[Flags]public enum Direction{ None = 0x00, North = 0x01, East = 0x02, South = 0x04, West = 0x08,}

If you wanted to represent northwest, it would have a value of "9", or "Direction.North | Direction.West"

I assume that GML uses a similar concept.

Anyways, the reason that keyboard_check_pressed() only works with one button at a time and doesn't play well with || is likely because each key has a specific byte assigned to use (either unicode or ascii) and you can't really flag them like above.

Is there any info on how to organize tiles in an rts/rtt?
Looking for technical details to handle large maps in a performant way.

I'm guessing you'd use a 2D array?

is on the right track, but he made a small oversight.
In any sane programming language, the expression inside the keyboard_check_pressed function would have given you a compiler error, because you are using || inside it. What was referring to was the bitwise OR-operation which uses the | operator (at least in sane programming languages). ord("X") | ord("Z") would have made sense. ord("X") || ord("Z") shouldn't even compile.

Let's take a step back.
// Expression 1 a and bif (keyboard_check_pressed(ord("X")) && time < text_length) { }if (keyboard_check_pressed(ord("Z")) && time < text_length) { }// Expression 2if (keyboard_check_pressed(ord("X")) || keyboard_check_pressed(ord("Z")) && time < text_length) { }// Expression 3if (keyboard_check_pressed(ord("X") || ord("Z")) && time < text_length) { }

The combined expressions 1 a and b will, for every input, have the same result as expression 2 => They are equivalent.
Expression 3 is not equivalent to them. With expression 3, you check for something different. To understand that, you have to look at them and interpret them as a computer would. That means interpreting them step by step and interpreting them logically/literally.

I'll ignore the time factor for this explanation: See pic 2.
If you do the same with expression 3, you will find out that it does something completely different.
Try it.

I made a small mistake in this post. The fact that ord("X") || ord("Z") compiles does make sense, if what Game Maker uses works anything like C/C++.
Booleans are simply numbers. 0 equals false and everything else equals true. Since ord() returns a number (that will not be zero in your cases) you get false || false.
Always.

It only calls on the first player because you're getting only the first player. You could probably get every player connected to the game from the game state, which I think is automatically stored in the "PlayerArray", and then from that, for each do finishing round.

If you're working on networking and replication NEVER use "Get Player Character". Never ever.

Humm, if you want easy organization of tiles plus a lot of concurrent units going on each tile, and require customized spatial subdivision for your logic (collision, physics/combat logic, i.e. dividing tiles into sections); then I'd go for a quad tree.
I'd imagine this is a very basic view of how a game like total annihilation manages it, as in, organizing 1000s of units on screen at a time with interactive frame rates.
Although, one crux of a quadtree is that it's specialized for spatial subdivision of 2D space, and 3D space with some major limitations.
As in, it can't be used with a situation like so: going from above ground -> subterranean natively (i.e. it uses x/z axis, not x/y/z, as that's where an octree comes in handy, i.e. a 3D spatial data structure).

The benefit here isn't just customizable subdivision of your game's tiles, but also the spatial subdivision of parts of your game's logic into "quads" of the quadtree (I'll touch on why later in my post).
The quadtree can be subdivided using custom splitting rules, and makes it possible to specialize it to your particular needs.
Such as, splitting the quadtree until it includes less than your pre-defined amount of units per quad (like a tile in this case, but subdivided down to the size you specified via split rules).
So this means, you could use that split rule to make sure only 25 units are within a quad at a time, and hence you only have to deal with those 25 units at a time with this quad for collisions, combat logic, AI, etc.

Not sure on the tuts for quadtrees, as I use octrees… but I'm sure you can find a few out there.
If you do decide on pursuing this, then I'd recommend doing a tut or looking over some source code, and always try to implement the recursive full quadtree first to get a handle on it.
After all that, if you want a more performant quadtree you can try implementing one of the more efficient variations of the quadtree: sparse, balanced, or linear.

That's kind of misleading; at any given point, you may have units that cover more than one space. That's why each set will have to interact with its neighbors for collision, attacking, etc.

This is a moot point as it's generally handled with special case logic, or altering your implementation to having overlapping quads; which tutorials tend to go over as it's the first issue nearly everyone runs into.

There's plenty more cases where this has to occur, and is generally one of the main reasons you want to organize data this way; as it's specialized to "narrow down" what has to be sifted through to get your desired data/unit/etc.

I was under the impression that leaving the online subsystem as Null in the ini would let it access the epic subsystem, thus letting me connect to a listen server via direct ip.
I did a steam multiplayer tutorial, but did not try it online.

So if I wanted to
>jump straight into making a 3D game
From knowing C++ but never having done anything with graphics, what engines/ides/libs/resources are suggested?

If you actually want to make a game, you should use an engine, because making a 3d game will be enough work as it is.
I can recommend Unity and Unreal. I'll give you more details later. Breakfast comes first.

Okay, how do I go on from here?

Are you trying to fire FinishingRound for every element in the Player Array?

Yeah.

Okay, it works. I will detail how I did it later. For now, I can say that I moved the Finishing Round logic to the player state script and not the player character, to avoid headaches when referencing the player character.

just connect array element to target and you should be done

I presume print() rounds those values to the nth decimal place, whereas the first values are your interpreter showing you the highest possible degree of accuracy.

im not really entirely sure what you are suggesting but
As far as i can tell this shouldn't really be much faster that just using an array
sure you don't have to test for as many cases
but you would have to move units in and out of various parts of the tree all the time
I think excluding everything outside of the area of influence of a unit with a simple if statement would be just as effective
though i suppose it does depend on the number of units there are and how fast they move around

Physics and collision in my game engine, it's kinda fun

That's the good shit man

(1/2)
I started to make my game in Unity and, not long ago, decided to switch to Unreal. Here's the basic breakdown for you:

Unity pros:
If people who know jack shit about game development and/or programming, can produce »something« with Unity, it speaks volumes about how easy it is to get into.
Unity is all about programming (in C#, which should be no problem for you). Everything you do, you do with programming. If you're anything like me (a guy who likes programming a lot), you will feel right at home.
Unity is designed for programmers and you can tell by the API alone. As I said, it's all about programming and Unity's API makes it easy to add new functionality or extend existing ones.
The Internet is full of all sorts of tutorials. Unity has official ones, which are top notch.
Thanks to using C#, Unity's development process is comfortable. Extremely fast iteration times, safety and stability, on top of a powerful standard library.

Unity cons:
You start with a blank slate. On the one hand, you don't have to learn a big, fat framework in order to get something done. On the other, you have to do A LOT yourself; Even things where you would think the engine does for you. This will cost you a fuckload of time. Alternatively you can also pay a lot of money in the asset store. And yes, it will be »a lot«, if you decide to buy everything Unity lacks.
While it has its upsides, it also has severe downsides, which will become clear once I explain how exactly Unreal differs in this aspect. Simply put: There are things where programming is a shitty approach.
C# is not an upgrade from C++ (at least in gamedev), since you make big trade offs. Safety vs performance. Comfort vs flexibility. The automatic memory management in particular, is a huge PITA. I have a Xeon E3-1231v3 which is quite powerful. A single garbage collection easily took 7.6ms. Since you're new to gamedev: You have to fit your entire game into ~16.6ms. Not your game-logic, mind, but literally everything (game logic, AI, input, networking, rendering, audio, etc.). The result is that it's easy to write Unity code, but hard to write good Unity code. Unreal also uses garbage collection, but C++ is more flexible. You can do a lot yourself and explicitly allocate memory on the stack, if you need it. C# forces you to go with whatever it wants. (I assume that you know how what garbage collection, heap and stack are. If not, I'll gladly explain, if you're interested.)
Unity has some systems that have been neglected for far too long. Shitty input system (no ingame rebindable keys, if you can believe it), awful terrain, poor post-processing and shitty OpenGL renderer. There are more, but those really stand out. The good thing is that all of those are being worked on, but you shouldn't hold your breath. No one knows when they will be there and whether they will be any good once that happens.

(2/2)
Unreal pros:
Epic made sure that UE4 is easy to use for non-programmers, which make up the majority of big studios. They took it so far that you can make entire games, without writing a single line of code. It's not that you have to, but you can. One particularly great feature is the level-blueprint. You have blueprints visual scripting (a visual scripting system where you create logic with graphs rather than code). Level-blueprints are blueprints that are embedded into each level. They are there for stuff that is level-specific. This is insanely useful, as level-specific code is a pain because it's stuff you won't reuse, but still needs a lot of overhead to be actually build.
Prototypes are only a few clicks away thanks to blueprints. Without having to write any code, you can quickly try things out and change them, until you get what you want. Afterwards, you can still write code, if you wish.
Performance + flexibility. They added A LOT of helpers (in the form of macros), so Unreal C++ development is not like normal C++ development, for better and worse (more on that later).
You can tell that Epic knows a lot more about gamedev than UT, when you look at what Unreal gives you out of the box. They have an entire "gameplay-framework" that helps you do things that basically every game, regardless of genre, needs in one way or another.

Unreal cons:
As someone who knows a lot about Unity, I can guarantee you that Unreal is much, much harder to get into. I am not sure if this has something to do with the learning resources, of whether it's simply a result of there being much more to learn in the first place. All the features Unreal offers are things you have to learn first, before they are of any use. On top of that, the engine clearly expects you to use its framework, whereas Unity's blank slate approach let's you do things your way (within limitations). That framework might be nice, but unless you understand it, you'll be scratching your head, not knowing where your code goes.
Awful iteration times, (I think) incomplete and TERRIBLY slow intellisense. You'll basically have to program without auto-completion and -correction half of the time. By "slow" I mean that you shouldn't wait for auto-completion (unless you have a lot of patience) and auto-correction will often underline your entire class as wrong, until some time after you successfully compiled your code and Visual Studio finds out that it actually does work. The reason for this are all the macros Epic added. They might be awesome, but they fuck Visual Studio up really bad. You better have a fast CPU and SSD for that (it'll still suck, but less). Debugging is also a lot less comfortable than in Unity. You have to restart the Unreal Editor every time you want to debug, because you need to compile your game without compiler optimizations. Otherwise you could put breakpoints on code that doesn't actually exist (at least in this form) inside your game's binary.


In the end, you have to decide how much work you're willing to put in. If you're serious about gamedev and actually want to produce a game, you absolutely should go with Unreal. The downsides of the programming experience are a small price for all you gain, and the fact that it's harder to learn becomes moot, if you're willing to put in the effort anyway.

Hope this helps.

The data structure you choose is entirely dependent upon what the main purpose of the data structure is, and what your essential requirements are.
As in, what you require to be blazing fast, what you're required to use constantly (can't be abstracted away), and the inverse of what you don't need to be fast (as in, what you can make sure you almost never need it, or can abstract away).
E.g. you wouldn't use a screw driver to hammer in a nail, while it's a tool that could do the job, it's highly inefficient, use the tool specialized for this job… a hammer.
The same thing applies here, use what fits your needs the best.

Moving on
Basically, the quadtree is a highly specialized data structure for organizing + subdividing + searching spatial data, i.e. things like tiles, and what will occupy them (units, projectiles, and related game logic which requires querying this spatial data).

An array is faster for random reads (indexing, O(1) constant time), or iterating through the entire collection O(n), because that's what it's meant to do.
Although, that's not to say it's the best at everything… it's certainly slower in certain tasks when compared to what the quadtree is specialized to accomplish (apples and oranges); or say a dictionary/hashed collection.

A quadtree is good at searching for a specific spatial related query O(nh) [h is depth of quadtree, i.e. levels of subdivision that data is at]; so this is things like finding units in a game world in this specific range of coordinates, find all projectiles near this unit that could collide, adjacent/neighbor units due to explosion going off, raycasting queries, LoD, culling, etc. etc.
I should also explicitly note, that it's widely used for subdividing the game world, that is, the game objects, and the game logic.
In addition to retrieving data that can be specified via some spatial input.
Insertions times for a quadtree are O(nd) (d = depth you want to insert into, via split rules).

Although, this is for a simple recursive octree, and these limitations can be overcome; with some clever abstractions or a different implementation style as I mentioned in my other post.

You should write your own engine, I recommend checking out thebennybox and ThinMatrix tutorials on Youtube. They write in CPP and Java but the concepts are language-independent.

I know this is an unpopular opinion but I think that knowing how things work from the inside is important, and having full control over your code will let you do all sorts of magic. Not to mention that you won't have to pay any license fees.

Also not to mention that epic actually develops games on their engine, and due to this fixes bugs that most people would encounter while actually making a game.
I also really like that they're opensource'ish, and allow people to do branches of their source code + making it easier to let players fix engine related bugs they run into.

Comparatively, Unity only does engine development, and they're known for having lingering bugs that many encounter when actually making a game; i.e. issues that they've left that essentially cripples a lot of developers.
As in, they focus on implementing new features instead of refining the one they already have (i.e. fixing the damn bugs, or making certain features work at an acceptable speed to conserve that 16.6ms budget).
In this sense, using Unity to develop a game from 0-90% is made quite easy, but that last 10% is going to be a goddamn struggle (any game's last 10% is hard to finish, but unity makes it more difficult in this sense due to said lingering issues).
As you mentioned, the garbage collector is one of the main culprits here, and essentially makes the entire appeal of C# (automated memory management) pointless; due to requiring manual memory management.
Once they fix those issues (some others too), and fire the new ceo, I'll be happy; until then, I'll remain a pessimist.
Though it's not all bad, unity does have a few things that has made me stick with them for quite a while, and I'll keep sticking with them unless something like an EULA change occurs not to mention I'm in too deep to leave.

Is it possible to make a level editor in Gamemaker? I mean, something that can spit out a file containing level data and then be read / written to?

I was in the same position, but stopped two weeks ago and just gave Unreal one week, not more, not less, to impress me. Even if I decided to stick with Unity, I'd still have made a decision based on actual experience, rather than anecdotes by third parties. I specifically set myself no goals, but rather went with the beginner tutorials to just see where I would end up after 7 days.

Well, one week later I started to port my game. Money spent on third party assets and hundreds of hours of experience did not stop me. It was a very hard decision, but I am certain that I made the right call. The thought of having to develop some of the more painful systems again in Unreal, made me sick. The thought of having to develop some of the things Unreal gives me for free in Unity, made me slightly sicker.

Don't get me wrong, Unity does have a lot of things going for it. However, if you're serious about developing a game, I don't see how you could choose Unity over Unreal. You'll waste orders of magnitude more time reinventing the wheel in Unity, than what you gained from Unity being easier to pick up.

I'm talking about shit like GDevelop, and how much it stacks up to Clickteam or Construct 2, for I admittedly haven't even seen any 'notable' indieshit come out of it yet.

ok so to find an object at a certain position with an array you would get an average of O(n/2) to find an object in a certain area/position
and you say that doing the same thing with a quadtree is O(nh)
so how is that faster?
And even if it was that still leave not only insertion into the quadtree but also removal.
whereas with a simple array you don't have to remove or insert objects nearly as often

Alright, anons. I have a serious question:
What is the best way to learn to code? I've been seriously considering buying books on learning C# or C++(Convince me as to which one I should learn) because most free tutorials you can find online are either incomplete, in-progress(So you have to wait unknown amounts of time for the next lesson), out-of-date(Many of Unity's tutorials) or are complete and comprehensive, but don't deal with game development.
Are books a good way to go? Would $30 on a book for C# or C++ be a better option than constantly sifting through the mountains of YouTube tutorials? Because after two straight weeks of YouTube tutorials I still feel like the only thing I'm capable of doing is following tutorials.

Fucking firetires your website ate my image

Just team up with a programmer.
ez

I am friends with some actual game devs who have a lot of spare time. The overlap of our spare time is infrequent though so I'm not sure if that'd end up being all that helpful.

that's iteration, not doing some search/sort

>same thing with a quadtree is O(nh)
I mistyped, nice catch, as O(nh) is the iteration time over the complete quadtree.
To search for a specific position, or insert into the octree, it's always: O(h), h is the height at which the value is at or specified to be inserted into.

Yup, that's one the key things one has to consider when implementing a spatial data structure, but in the sensibly implemented case it's a non-issue as long as your quadtree isn't something like 10 levels deep (that's terribad design, usually should be 3-4 levels, at max 5-6).
It's also dynamic in size, and removes the issues of say a huge static sized array to store all tiles/units/etc; while also making manual memory management extremely easy w/pooling design.
Now, the static sizing for the array approach can obviously be solved via using a list instead of an array, but for this case it's horribly inefficent due to resizing, copying values, GC'ing old collection when resizing, etc etc.


Of course, none of this even matters if it doesn't fit your requirements, i.e.:

Those numbers demand respect.
You make a sensible argument, and I do agree with your logic… I may give it a go in the near future.

It depends on what you're doing.


What quadtrees (and other similar trees) do is allow you to drastically reduce the set of points you need to evaluate. Imagine resolving collisions between 2d objects like circles. Circles and spheres have the fastest collision checks, because you just need to check if the radii and distances of the two objects in question. It is really easy and really fast.
If you have 100 circles and need to resolve their collisions, that means running that function for 100 objects and checking each object against the others. This means that you have a runtime complexity of O(n^2), which, in this case, would mean having to run the function 10.000 times.
With a quadtree you can efficiently find the nearest neighbor of any given point. This means that you can reduce the amount of times you have to run the collision function, because the quadtree already tells you which points are too far away to be canidates for a collision. If memory serves, a quadtree runs that algorithm with O(n*log(n)) which for our 100 points means running the collision function 665 times (rather than 10.000).

The same applies to operations like finding the k nearest neighbors or all neighbors within a certain radius. Around arbitrary points, mind.


I'm not 100% sure for quadtrees, but kd-trees (an alternative which are better at some things and worse at others) have logarithmic depth. I never looked too much into quadtrees, but aren't they the same?
In that case it's O(log(n)), which is fantastic. It means you get one single extra step, for every time you double the amount of points. If you increase the amount of points from 1.000.000 to 2.000.000 in an array, you will, on average, require a million extra steps. With a kd-tree (and possibly quadtree), the amount of steps it takes to retrieve your data increases by exactly 1.

Shit, I made a mistake too.


It's actually O(log(n)). O(n*log(n)) is for finding the nearest neighbors of all n points.

It's not the first time this question is asked here and I now regret for not saving my previous recommendations in a text file. Luckily I answered that question in the Unity forums too, so here is a screencap. It applies to gamedev in general; Regardless if you want to learn how to use Unity, CryEngine, UE4, Source 2 or roll your own.

As for literature I recommend "The C Programming Language - Second Edition". It contains far more than you'll ever need to know about C as gamedev, but at least it's complete and nobody forces you to read the parts you aren't interested in.

Hope it helps.

Can second that C book. Most of it is still useful, but bear in mind that it's rare to use C instead of C++ in gamedev.

Also there's no getting around learning actual programming. You're gonna have to learn to slog through shit like algorithms because they have practical applications, and you need to know when to use what and why (for instance, linked lists are great but suck when you need cache locality).

Also one of the best ways to learn is to just practice. Make a shitty game. It'll be shit, but the experience will be valuable.

does he genuinely look cute?

sorry if he's not, I'm blind to 3d (started just this summer)

Couldn't tell that's a guy, the hair looks more like a girl's hair. The eyes are kinda wigging me out. Sorry but not cute.

Can't argue with those digits. Will look into that book for sure.

akaik they follow roughly the same idea, but quadtrees use a static arrangement for subdivision (4 children quads for each parent node, repeat ad infinium); which is generally used for 2D purposes.
I primarily use octrees tbh, but quadtrees came up due to the user asking for a good way to organize tiles (2D I presumed)

Humm, I was just using the steps required to traverse the height of the quadtree as a metric (as to insert a value, or search a value, but only considering the amount of levels we need to traverse).
Although, akaik you're 100% right when we consider the amount objects we'd have to compare against as to find an object via searching the quadtree; i.e. it would be O(log(n)) comparisons

Yeah I heard that it wasn't too cute by others too

is it because the eyes are flat? I made it 3d before but it looked more creepy

I can't exactly place it, but it might be the colors or it might be the slant. The first thing I thought of when I saw it was Orochimaru.

Aside from that it looks like a girl due to the hairstyle, you're kinda riding a line between cute and scary. The eyes are kinda intense, largely because of the color, and to a lesser extent, the shape of them. Can you show us what they'd look like if the sclera/iris were just a normal white/blue?

I think a lot of it is the texture work or rather lack thereof.
It looks like you used the paint bucket tool in MS paint (which isn't very kawaii).

Honest question:
How many of you say "I want to make a game!" and then just spend hours upon hours making models in blender etc. without advancing at all?

The shader you're using doesn't help.
It gives off an odd appearance, as the face doesn't have any discernible depth/details to it.
Also, there's too much details in the eyes, but that's because I'm comparing it to the rest of the face (if you added better details to the face, and removed that shader… the eye detail would be great).
So the eyes appear intense/creepy, and the rest of the face is indiscernible/non-descript due to the lack of details + the shader you're using.

it's just placement checking
it's not exactly the final textures

I'm going to add much better transition between colors and shading later

But we can hardly give you feedback on on things that you are going to do in the future, can we?

I wanted to get feedback on the general proportions and placement of facial parts mostly

overall, are the issues just because of texture? nothing wrong with the mesh?

It was like that for me for a while, with music. When I first started, I'd often think "Today will be the day that I just like make game!" then immediately open FL Studio, dick around for 8 hours, and ultimately have basically nothing to show for it.

Not that I'm a well-experienced dev or anything, but what progress I've made has largely been about learning curve. I've found that the more I know, the less time I spend fucking around on minor details that matter way less. It's probably the product of avoiding the uncertainty of having to face the fact that I don't know where my limitations are.

I'm one of those guys.
Except instead of 3D Models, it's 2D art.

oh yeah, you also need the hard edge outlines for features that anime is known for, which can be done with a shader.


mesh and proportions looks like an anime character to me

The problem is that I can hardly judge the mesh, if the model looks so 2D, it could be a cutout. Due to the texturing and shading, I can't see any depth. Properties look good though.

I assume you're using Blender here.
Go to the object tab in the properties editor, then check wire and "draw all edges" and make another screenshot.

Proportions

Hey again; Mom user here, I have finished the HUB map for my game, and I thought I may as well show off a few screen shots!

More images in the next post!

...

The indoors shots look awesome man, but I think that outside it is a bit too bright.

I was actually considering using several data structures for the same data for faster access based on what i need
You see i need to access the data in a variety of different ways as you pointed out you should pick a data structure based on what you need out of it
but really I need all the data structures
that is to say in some cases accessing them by position might be preferred but in some cases might need random access or sequential.
Using several data structures for the same data does incur the problem of adding and removing the same reference several times
but this could be solved by adjusting the actual underlying values of the data to indicate whether they are in use or not but then the containers become much larger than they need to be which in turn slows everything down.
I think some experimentation may be in order
But i should probably leave that for when performance becomes a serious problem

If you don't know any coding at all, I suggest you to start with an easy language so you don't burn out easily, lots of times learning C/C++ as your first language will make you hate it.
I reccomend learn python the hard way, it's here and it's free:
learnrubythehardway.org/book/ex0.html
Erm, Godot uses python, but it's just that from here you can basically branch out to other languages without many difficulties.

FUCK, I posted the wrong link.

Here's the python one, that one was for ruby:
learnpythonthehardway.org/book/ex0.html

I should of probably added shadows on the outside, which may be difficult to do due to the way shading is handled (Its sector based, so even if you are high in the air, the shadow would still affect you even if you are above the house)

is that the game that feels like a Cute Doom with anamial characters and weird weapons?

Oh, you meant for creating games without programming.
Sorry, the only FOSS engines that I know of are Love2D and Godot, and they both require programming.

This is the Fantasy RPG doom with the Imp, Skeleton, Lizardman etc characters, yes!

Having the data in several data structures isn't a problem, if you're working in C/C++. You have the actual data in one place, while your complex data structures are used as various indices and merely contain pointers to the actual data.
It makes sense to have some sort of isValid flag for your data. When you remove an element from your set, you clear its isValid flag. Obviously every data structure checks for that flag and treats ones that aren't flagged as valid as nonexistent when it accesses them.

Depending on how often you remove data, you can then either clear your advanced datastructures at the end of each frame, do it with a timer or wait till they a sufficient amount of changes were made. You would remove any entry that points to an invalid set of data, thus saving some time when accessing them during the next frame.
It really depends on what exactly you're doing though.

very true
i think ill just stick to a simple array until im ready to tackle optimization
but i will keep the quadtree thing in mind it might be quite useful later

What language are you using?

C++

Checking ID's to see if you are me

Phew, I'm still myself

Shit, I just remembered that's not a relief

Then it's fairly straightforward.
You have your data in structs within a single array. You then build yourself as many arrays of pointers to those structs as you need. This could be quadtrees, kd-trees, grids, or simply arrays that contain subsets of your data that you need often.
It's not only about how you access the data, but also about what data you access.

Think about an array of all units in a RTS. You have that array, which contains »all« the data. You can iterate through that for stuff like general AI behavior updates and statistics.
However, there are certain subsets of this set of all the data, that you will find yourself using a whole lot. Your own units come to mind. Very often (read: for almost every single player command) you will only need to process your own units. So it makes a whole lot of sense to have an array that just contains pointers to your own units in the whole set.

You need to iterate through all units? You iterate through the array directly.
You need to iterate through all your units? You use your all_my_units array to iterate through your data.

I just wanted to add that this is a contrived example. If you're doing an RTS, good god, do not keep all units in one array as it will absolutely kill performance.

There is nothing wrong with doing this, though. In fact, keeping everything in one place in memory is good to maximize cache hits. Problem would be processing each unit in this array each frame even if they don't have anything to process, that's when you need to copy a reference to units that require some routine to a different array.

Having data redundancy in memory is not bad. We have a fuckhueg amount of memory, but a more limited amount of CPU power. If you have to cache something to improve performance, do it without fear.

which one do you do first,

should I check and learn more about the pose rigging
or finalize the textures?

I am actually making an rts and i have been keeping everything in a single Array
I have yet to test performance with large amounts of units no more than 50 so far which gives me ok performance
Honestly though i have a profiling tool which i use for optimizations so unless it indicates the array is a serious issue i won't bother with complicated data structures.

AFAIK, quadtrees are unbalanced kd-trees. In quadtrees, there is a grid, and points adhere to that grid; with kd-trees, there is not a clear grid, and chances are some areas of the grid with less element density are bigger than those that have a higher element density.

Say, in a quadtree, you have a root with four children, and each child is of size 0.25. In child A, there are 5000 elements, whereas in child B, there are only 5 and in every other child, there are 0. In a kd tree, you can have four children (although it's a binary tree, so not in the strictest sense), but you won't know how "big" each one is because it tries to balance its children. That said, the tree should have aproximately 1250 elements in each node.

Games often take profit from quadtrees/octrees because it's easier to make sense of nearest neighbors and volumes this way, and also because insertions and deletions from a kd-tree are slow.

Is this gonna be a collectathon?

You shouldn't keep all the units in one array exactly because of cache misses (at least in the example I made).
In my example iterating through all your units was an operation that was performed very often. The problem with keeping all the units in one array will be that you'll inevitably fill your CPU caches with enemy units you don't need to process. Keeping the array sorted, is out of the question. I was accessing the array using a second array to filter the data. This produces a cache miss for every single unit, which is terrible. It's what you do, if you need to do random access on your array, not if you need to perform a linear iteration over the entire set.

In that case you either do what you proposed (i.e. keep a redundant copy of your data) or you simply split the array up into two; One for the enemies, one for your own. If you need to iterate over all units, you first iterate over one array, then the other. This produces, at most, a single cache miss more than if you kept all in one.


I doubt that you'll be able to do that. The problem is how exactly do you judge whether it is good or not? If it gives you a number like 1.3ms, how do you say whether this is good or bad, if you have nothing to compare it to?

Before this thread dies, I'd like to acknowledge that you make particularly good posts. Thanks for the help.

This looks fucking great user

Hey, if you're still here, could you explain the
>(I assume that you know how what garbage collection, heap and stack are. If not, I'll gladly explain, if you're interested
Thing please?I'm interested.

I think you misunderstand i would profile the complete game not just a part of it
The results would show me how much the CPU spends on each function if some of the array functions take a lot of time i can take the appropriate measures.

This may likely be wrong due to lack of specific terms and obscure exceptions, but generally, a garbage collector is a "routine"provided by your language's runtime that runs at certain intervals and checks for objects that are no longer accessible by the program and removes them from memory. The easiest example would be an enemy object that was generated and put in an array, then removed from said array when it died. The enemy itself is still in memory, just no longer accessible because there are no references in the entirety of the program; there is no way to recover it, and basically, it's taking up space. Once the garbage collector runs, it will remove it entirely.

Garbage collectors make programming much easier, but they may hurt performance because their routines are not exactly simple and take a lot of time to execute. Manual memory management allows you to destroy elements at any given time as long as you do it yourself, which allows for some interesting things such as only removing objects from a previous scene during a loading screen. Not like manually deallocating memory takes much processing power, though.

The heap and stack are two concepts related to persistence of memory, and it's easier to explain with examples: say, we have a function called foo, and inside that function you declare int x, int y and int z to be used. x, y and z make no sense outside of the function because they are function variables, so they can be safely removed from memory after leaving the function. That's what stack allocation is, you are declaring variables to be used by a scope, then destroy them when they are no longer needed. Problem is, the compiler needs to know the exact amount of space you want to use in that function beforehand, so things like arrays of variable size are impossible in this context. That's where the heap comes in play.

Sometimes, you want to keep a variable outside of a function, or simply want to allocate a different amount of memory depending on some parameters obtained during runtime. When you want to do this, you make a heap allocation (they are easy to spot in C since they use malloc, but beware because not all languages are this obvious), which requests an amount of bytes from memory to the OS to be used by the program. You can now shape this amount of memory as you wish, but since a primitive runtime is not clever enough to figure out when should it assume this portion of memory will no longer be used, it either needs a garbage collector or manual freeing of used memory.

In languages like C++, allocating in the heap is sometimes not immediately obvious, so be careful. Stack allocation and access is more often faster than heap allocation and access because of OS and CPU fuckery, not even taking into account you can forget to deallocate heap-allocated memory and keep some reserved memory space occupied until the end of the program (which is known as a memory leak, and is a real problem if your program forgets to deallocate too much) so avoid using heap allocation as much as possible.

Thank you for the nice and concise explanation man, I've been hearing about these terms a lot and didn't know what they were exactly.

Glad someone finds my posts useful. The only downside is that the time I spent making these posts, is time I spent not working on my game. There are some upsides though.
Every time you explain something to someone, you repeat it for yourself too.
Besides that
>I like that feel (I need to practice my smug for when I take to twitter and taunt the indie clique with being all smug all the time)

Once I get my Unreal skills anywhere close to my Unity skills, I'll start making posts/tutorials like these in the Unreal forums. They have an indie dev fund for Unreal projects they find promising. I really want to get my hands on some of that money, so I won't need to crowdfund that much/at all. I should make myself a presence in the forums by helping people out.


What I meant was that if you profile your application and it gives you the values, on what basis do you assess whether they are good or not? You don't know how it would perform, if you used other data structures. (Well, you could do approximate calculations, but that would be a ridiculous amount of work.) If it really stands out, taking up the majority of your processing time, then it's obvious that you should take a closer look, but what if it doesn't? If this function isn't a huge, glaring performance hog? It is still entirely possible that you could get the same results in a fraction of the time.


explained it bretty gud, but I'll go into some more detail. 4 U

Based on the framerate of the game
I don't know how it would perform with other data structures and i don't actually care if i can get the framerate to 60 with 400 units thats good enough for me
I use the profiler to determine which parts of the code cause the biggest slowdown
And then go down the list and fix what i can from biggest performance hog to smallest
Yes it could be much better but if the array stuff isn't taking up a majority of the CPU time then there is no need to change it

Rate my robot.

it looks like a can with arms

I'm trying to learn about engine level optimization techniques. I'm looking at how engines optimize their levels and they all use BSP it seems like. I thought BSP was shit for modern systems. From my understanding: Back in the day GPUs couldn't handle too much so BSPs where used to make it so the CPU filtered out all the unnecessary vertices. Nowadays this actually is slower because it's putting too much strain on the CPU while GPUs have improved vastly since then.

Looks like that casual filter from Fallout 2

Ahh, I see. That's fine. I'm just a bit more on the gotta go fast side of things, since I want to sell my game once it's ready. Running good on my PC doesn't mean shit to me, because not everyone has a PC as powerful as me. The faster the game runs, the lower the minimal hardware requirements, the more people can run my game well/at all, the bigger the target audience.
It's not like I go to John Carmack lengths of optimization, but this kind of stuff is basic. Those algorithms and data structures have been developed and used for those purposes for ages.

(1/?)
Let's take a small step back and talk about memory for a bit

There is more than one kind of memory in his PC. You have your permanent storage (HDD, SSD) and your RAM, which is volatile (data is lost shortly after your PC is turned off). Your files go on your permanent storage, while programs load data into your RAM and keep it there until they terminate. There is another very important relation between these kinds of memory. Keeping all the data on your permanent storage (including the data your applications work with), is a terrible idea, because your storage might be large, but it's also much slower. Your RAM on the other hand, might be blazing fast, but is also much, much smaller (aside from being volatile).
There are more kinds of memory in your PC and this relation holds true for all of them now, and always did:

If you program in assembler, you manage all of them (except for the caches) by hand. If you program in C/C++ you can manage these by hand, but usually only deal with your RAM and permanent storage (again, by hand). If you program in languages like C# or Java, you manage your permanent storage by hand, the RAM is managed for you and you have no way of directly influencing anything below that, or even know what's happening there.
Depending on what you're working on, this can cause huge problems, as not using your CPU caches efficiently can make your application multiple times slower.

For today, we're going to focus on the RAM.

Your OS actually separates your RAM into two parts: the heap and the stack. One on each end, growing towards each other. The stack is a small part of your RAM. The most of your RAM is used for the heap. Despite both of them being on the same physical piece of hardware, they have the same relation I told you about earlier. The stack is a lot smaller, but also a lot faster.

The heap is what people who know a bit about computers think of, when they think about RAM. Your application loads/creates data and puts it in the heap to use it. Unless something goes horribly wrong, the heap exists for as long as the application needs it to. From the point of view of the application, it's permanent. You "allocate" (request and reserve) memory on the heap using the "new" operator in C++ or the "malloc()" function in C. You "free" memory on the heap using the "delete" operator in C++ and the "free()" function in C.
The reason why it's so slow, is because being permanent has some huge implications in modern, multi-tasking operating systems.
If applications allocate chunks of memory, your OS needs to make sure that there is no overlapping. Otherwise horrible things would happen. So your OS needs to keep track of which application currently uses which chunks of your memory and intelligently manage them. Which part of your memory should you give to an application exactly? Applications that were terminated or simply freed some resources, will have inevitably left lots of free "holes" in between allocated memory. I think you get how this isn't a simple task.

Every time, you use "new" in C++, this has to be done. This is the reason for why particle systems and similar things, with too much throwaway data for the stack, use something called "object pooling", if they were developed by a competent developer (which is something one should do A LOT when working with Unity).
You create a »new« particle, send it on its way, some time later it dies and is »deleted«. Actually using the new and delete operators (or your language's equivalents) is the naïve implementation, which will run like absolute arse. What you're supposed to do, is create all the particles up front, turn them off by default and put them in an array for particles that are ready to be used. Then, instead of using the new operator, you always simply take the first element out of the ready-array, turn it on and send it on its way. Once it dies, you turn it off, reset all its variables and put it back into the ready-array.

(2/?)
Other than the heap, the stack is something (usually) only programmers know about. It's a special part of your RAM that, from the point of view of the application, is volatile.
As the other user already pointed out correctly, it's there for things you do in functions like temporary variables used in calculations, counters for iterating through your loop, etc. Simply put: It's there for throwaway data. Things you only need for a short period of time. As soon as you leave the function/loop/whatever those variables "go out of scope" and are "deleted" (not really, but we get to that later).
The stack is called like this for a reason. The reason being that it literally works like a stack of cards. You have to operations "PUSH" and "POP".
PUSH puts a new variable on top of the stack, while POP takes the topmost one off the stack. The reason why it's so much faster than the heap is that, being volatile managing it becomes a whole lot simpler.

The only thing your OS needs to keep track of, is where the top of your stack is. Earlier I mentioned CPU registers as being the fastest memory available to us. There is one special register, designated to that exact job: the stack register (or stack pointer). With multi-tasking operating systems it, again, gets more complicated (stack-frames and shit like that), but the general idea is the same. You just need to keep track of where your top is at the moment.
If you push a variable onto the stack, you take your stack pointer, increment it by one, then write the data. If you pop a variable off the stack, you return the data at the current position, then decrement SP by one. You don't even have to clear the data. You just take a step back in memory, because the next time you push again, you'll overwrite whatever has been there earlier anyway, so nobody gives a shit.


Manual memory management means allocating memory when you need it, using it for whatever you need it, then free it, once you don't need it no more. Sounds simple enough. The problem is that manual memory management is the source of one of the biggest PITAs a programmer can experience: memory leaks. It is really easy to write code that allocates more memory than it frees. If this happens in some sort of loop, your application becomes a memory black hole that eats up all the RAM. If it eats too much, too fast, your computer will simply crash. You'll have to pull the plug or press the reset button.
Automatic memory management works differently. Java and C# have a a huge-ass runtime environment your application runs in. It's basically a virtual OS within your OS and what it does, among other things, is keep track of resources you allocate on the heap and free them for you, when it's clear they won't be used anymore.
It's a huge help and makes developing so much faster. However, there are severe problems with this approach.

(3/3)
The part of the runtime that checks whether a certain resource can be deleted and does so, if it can, is the garbage collector or GC. The obsolete resources on the the heap it frees, are called garbage, which shouldn't require any further explanation. I will now list a couple of facts, that should make clear where the problems lie.

When the GC kicks in, it needs to check all the data and free whatever it can. While it works, your application is completely stopped until the GC finishes its job.
You have no direct control over the GC. The runtime will decide when it runs by itself. (You can have some minor influence here and there, but the general situation stays the same.)
Java/C# have no manual memory management, so they themselves decide what goes on the heap and what goes on the stack. So there's only so much you can do to prevent producing garbage.
A GC collect is really fucking slow in the kind of time windows realtime (soft and hard) applications work with. Vidya is soft realtime, which means that it is one big loop that repeats itself over and over, and needs each iteration to finish within a certain time frame. You either have 30 ms for 30 fps, or 16 ms for 60 fps. On my, quite powerful CPU, a single GC collect took about 7.6 ms in Unity. That's stealing almost half the time I have for a solid 60 fps. That's on top of everything else, every now and then, without prior warning and with no way of really preventing it.

You should see what this can lead to (hint: Minecraft). Compared to C++, which not only gives you the possibility to allocate shit on the stack explicitly (even arrays), a memory leak in C++ might be pain to find, it might be a pain to fix, it might even crash your computer, but at the very least it FORCES you to fix the issue. A memory leak in C# or Java on the other hand, won't ever crash your computer. It will just degrade your application's performance in a subtle way, due to spreading the increased GC collects out. You'll barely notice unless you fuck up really bad or write realtime applications.
The Minecraft modder who makes Optifine revealed that Minecraft leaked +200 MB/s some versions ago. If Minecraft would have been written in C++, it would crash the most PCs in under a minute with no survivors.

C# and Java make it easy to write programs fast. They just make it hard to write fast programs. There are good reasons why Unity might use C# for gameplay logic, but is itself written in C++.

This concludes our little lesson. I hope you'll have as much fun reading, as I had writing.

You're using a ton of vertices for the arms, but not that many for body of it. Kinda inconsistent.

Dang, thank you user, this was a quite informative and fun read, I hope that I can put this knowledge to use soon.
Seriously, not many people bother to explain this stuff in a such an easy to read while still explaning stuff like you do, thanks again.

What can I say? I'll go to quite some lengths in order to not have to work on my game. ;_;

Do you mind if I put your post on a pastebin by the way?

Why would I? Go ahead.
Put it on a pastebin, make a screencap, print it out and glue it to the ceiling above your toilet, so you have something to look up to while shitting.
I don't mind.

Thanks.
Here is user's posts for anyone that wants them, since the bread is dying.
pastebin.com/5tE4Hpk5

too many faces.
I like the bot tho

I respect the robot and those 3s.

Programmer art/character design :(


I don't know what that is…


Easy fix, juts takes time. Thanks.


Thanks Mr. Quints. I'm working on decreasing the poly count as suggested by . What's a good number to aim for? Currently at 1,032.

RIP thread, didn't even know it was autosagging

It happens, see you in the new one.

That probably fine actually.
It really depends on the visual style of the game. If you're developing for a modern system then that sucker can be 10 times as polygon heavy.

Just always ask yourself if you can make it more efficient and keep the same look. Is this robot gonna be in the main players face or will he be off to the side and only seen once.

Base it on this list. Think of the visual qualities of each game. Specifically the art style.

forum.beyond3d.com/threads/yes-but-how-many-polygons-an-artist-blog-entry-with-interesting-numbers.39321/

You can have a low poly game like wind waker that has a fantastic art style that keeps the low poly from aging

Start off by going to sprite websites, grab a shitload of sprites and go into a pixel editor whether it's Photoshop, Piskel or even MS Paint. From there you fuck around with pixel art and get used to how shading works and how to make smooth edges without anti aliasing, as well as learning basic art like proportions, scale and what not.

I've been doing pixel art for years and I started off making shitty street fighter sprite edits in high school. Just grab some sprites and toy with it to get an idea of how sprites work. in an editor. Here's a website to get you stated.

spriters-resource.com/

In terms of wanting SNK quality, you can grab Metal Slug sprites o the website no problem. If you're looking more at their fighting game sprites then start off with Garou: MotW. It has fairly little pixel colors surprisingly enough and it can give you an idea on how to make smooth animation.

Also, what this user said here
Learning anatomy is crucial for pixel art. If you are shit at art, you can also learn basic anatomy by fucking around with the sprites.

Is there a way to draw specific regions of a sprite at different depths, in Game Maker?

Also, new bread when?

I don't follow, what do you mean at different depths?

In Game Maker, every object is automatically given a variable named depth, which is used as a reference by Game Maker to determine what order the objects should be drawn in, and therefore, what objects appear to be on top of what other objects. However, I'm in a circumstance where I need part of one object to be on top of another object in one region of the sprite, yet below that same object in another. Therefore, I'm wondering if individual parts of a sprite can be given depth.

I can't remember but I think is possible.

Well, the thread's over, for anyone who's still here, the only solutions I found were to either:
A: Use draw_sprite_part to place parts where I needed them, but since there's no depth control, it has to be on multiple objects.
B: Just modify the original sprite to have the other sprite be on it. Kind of a shit method, but it'll work for what I need to do.