« first day (2247 days earlier)      last day (2772 days later) » 
00:00 - 17:0017:00 - 00:00

12:08 AM
HAY
OSX RL started working properlyu
@jon
 
1:04 AM
2
Q: Unity Asset Store Tools Problem

Moddwyn16MCSo I downloaded Asset Store Tools in the Unity Asset Store. When I upload my asset to my package, I get this popup: Wrong project path The path selected must be inside the currently active project. Note that the AssetStoreTools folder is removed automatically before the package enters the ...

 
 
1 hour later…
2:09 AM
0
Q: Edit an old closed question vs. create a new question

ChrisI came across this question as a suggested question from SE: What are the basic game activities? It's been closed as off-topic, though I would expect that the core question of "what are the basic activities we can provide in games?" as a very important and relevant question for Game Design. Th...

 
 
5 hours later…
7:16 AM
 
 
2 hours later…
9:03 AM
@micklh I wouldn't call it smart but it is cool
 
@ChrisMcFarland I didnt forget about you. I'm almost done with your translation. just a 200 lines left
 
9:36 AM
Mama Mia thatsa spicy tranlatiob
 
 
1 hour later…
user92578
10:51 AM
why'd you change your name @jgallant???
 
Too many jons
 
11:21 AM
you pussy
you should have had other to change their names
you are THE jon
 
user92578
^
 
@Tyyppi_77, can't remember if I already asked you.. why 77?
 
user92578
no idea, just looks cool
 
approved.
<-- same for 7 :)
 
user92578
:P
 
11:27 AM
That guy sure likes to write!
1
A: Edit an old closed question vs. create a new question

GnemlockIn context of the exact question you refer to, I would personally vote for neither. That said, your best course of action is to edit the original question, and let others decide whether it should be reopened. Ultimately, if you wish to make your case for reopening the question, you must do bette...

And good morning :)
 
user92578
yeah he does :P morning!
 
user92578
I got the preliminary results for my Swedish final today, and I did really well
 
user92578
just on the edge between the best and the second best grade though, so I'll have to wait 'till the final scores until I find out the grade I got
 
user92578
yeah I'm super happy, partly because now mom won't be asking about the scores daily
 
11:32 AM
Haha mom worries :P
 
user92578
:)
 
It's expected; parents want the best for their children.. well most of them... :P
 
user92578
11:59 AM
 
user92578
So today I've been writing a cutscene script for the introduction to bomb levels
 
user92578
I might have to think about changing the bomb mechanics to "defuse" instead of "shoot"
 
Nice.
 
user92578
As I feel like shooting a bomb to not make it explode might be a little weird
5
 
Solution. Shoot with water gun or water balloon
 
12:06 PM
Throw a kamikaze over it to absorb the impact!
Or a cow to get an instant cooked steak!
 
user92578
yeaaaaah... I think I might just go with "Press X to defuse"
 
Well that is pretty boring. Instead give player a cell phone and he can call the bomb squad. They come in and quarantine the area, then safely detonate the bomb allowing you to continue
 
user92578
haha lol
 
user92578
like a 30 minute cutscene of them setting up the fences and stuff
 
Unskippable.
 
user92578
12:12 PM
obviously
 
Then have a second bomb right after
 
user92578
yeah I mean I will make I think five levels with the bomb now
 
Then Albert Einstein shows up and says "you use my science wrong! Then does some crazy gravitational wave manipulation and the bomb just disintegrates into its most basic elements
 
user92578
and then the game changes to a physics puzzler
 
user92578
I just had this original idea of maybe like these shapes, in different colours with eyes
 
12:15 PM
I sincerely think that is the true underlying game you are making
 
@Tyyppi_77 :P
 
user92578
watermelon hotdog — jgallant 2 hours ago
 
12:30 PM
@Tyyppi_77 What does that mean BTW?
 
DH.
Nothing probably
You can't expect everything that Jon says to make sense, really
13
 
@DH. True
 
@Tyyppi_77 really subtle english bit here "to not make it explode" sounds like "i have to shoot it or i will make it explode. while "to make it not explode" sounds like "i have to shoot it to prevent it from exploding
officially, "not" shouldn't go between "to" and "make" as that's a "split infinitive" but people are pretty well divided about whether or not that matters. :)
 
user92578
oh, aight, thanks
 
few people would notice or care, but I know you're pretty picky about your use of english
ok gotta head to werk talk later :)
 
user92578
12:51 PM
wtf I have an extra key in tallowmere
 
DH.
Maybe you didn't open a shop
 
Unlock lady tallowmeres heart with it
 
user92578
oh yeah, maybe I just missed a shop
 
user92578
good point
 
1:10 PM
@Leggy7 Cool thanks, sounds like you're ripping through it!
 
I probably made my silliest bit of code last night
(new Function(
    "var f = " + str + "['" + func + "'];" +
    str + "['" + func + "'] = new Function(" +
    "'var func = ' + f + ';' +" +
    "'var callback = " + (callback + "").replace(/\s/g, "").replace(/\'/g, "\"") + ";' +" +
    "'func.apply(undefined, arguments);' +" +
    "'callback.apply(undefined, arguments);'" +
    ");"
))();
Yes, this makes a new function out of the provided string, which makes a new function out of a string
 
user92578
I have a browser plugin that allows burning chat messages, just for this reason
 
@Bálint Fun and dangerous ;)
 
user92578
 
1:26 PM
Why is it that no one answers trigonometry questions?
 
ejsy
whoops
hands were misaligned on keyboard
I was supposed to type "what's the question?"
 
I already answered it, but it was pretty much "if I have a bullet with an angle, how can I calculate it's velocity components"
@Lasse
 
okay
 
A lot of people asked on stackoverflow how he can listen to a native JS function, so I made a lib for it
 
meh, js
 
1:44 PM
@Lasse meh, unity
 
I agree
 
+++
 
the crap I have to go through every day because our project is using unity
sigh
 
I'm on day 4 of writing a network system on top of LiteNetLib... Going through the joy of letting the developer define their own messages with params of various Types, assembling the array of bytes as efficient as I can, and then parsing the bytes on the receiving end ._.
@Lasse hahahaha :)
 
1:51 PM
@Lasse Unity and Android together sucks.
 
If you think Unity and Android sucks
you should try Unity and Xbox One :|
 
oh shit
 
@Almo Lunch today?
 
I was going to ask you the same thing
 
All right, wanna go to that soup place in centre eaton?
 
1:56 PM
my friends keep wanting to go there. must be good ;)
sure that would be fine
 
All right, what time?
 
meet at 12?
 
In front of the A&W?
 
sure
 
2:11 PM
we've had less problems with android than we've had with ios
 
you guys are weird
we've spent probably 5x the time fucking with android
with marshmallow permissions, Adreno GPUs fucking things up in our shaders
 
for example the game runs smoothly on android whereas on ios it lags as hell, all because we're trying to play two compressed sounds at once
 
iOS problem we had was the need for square POT textures for compression
are you in unity?
 
yep
 
I don't have trouble playing multiple compressed sounds... that's weird
 
2:13 PM
we have ipad4 and the game runs smooth on my less powerful android tablet
 
there's some other issue then
it shouldn't be doing that
 
profiler says it's the sound and it runs good if we disable one of the two sounds
 
Cognizer performs fine on iPhone 4
and it plays background compressed audio plus sound effects that are compressed.
I wish I knew more about this to help
 
@Lasse do you have the DSP Buffer Size set to "Best latency"? Editor > Project Settings > Audio
find it helps reduce lag for me
 
no idea, I'm not at the office now
 
user92578
2:17 PM
I have nothing but my own incompetency to blame for bad sound quality <3
 
DH.
See? That's why we use engines, we can blame someone else!
 
user92578
Yeah
 
user92578
On the other hand I can just open the AudioDevice.cpp file and check if I'm initializing the audio device poorly
 
I don't want to blame the engine, which is why I am working on my own. Then I have nobody else to blame but myself
 
2:22 PM
"I don't want to blame the engine" can also be read as "I do not want to depend on unrealiable closed source software"
for example! Unity 5.4.0 broke backwards-compatibility with networking, but we had to move on to the version to fix other performance related issues and use our own network implementation
 
now the server does not need to depend on unity's networking to work, which is way more reliable
 
DH.
One can only hope that the 2D features in experimental don't break backwards compability, because I'm really interested in those although they won't come so soon
 
user92578
@Lasse just keep doing this, and bit by bit you won't soon need Unity anymore :P
 
user92578
"we had to upgrade for new profiler functionality, but that broke rendering, so we use our own rendering now"
 
2:27 PM
yeah well I've already implemented custom colliders too since we have no use for the physics engine which you just can not turn off
 
user92578
"the new build fixes all the sound bugs, but breaks UI, so we now use our own UI"
 
user92578
and now you're already at custom networking, rendering and UI
 
user92578
yeah physics too :P
 
also we don't use unity gameobjects any more that much, which helps with networking
so i guess what is left is the rendering part on the unity now
oh and the UI, we still haven't switched out of UGUI
 
I have many scripts in my Unity video-game. Where should I save user/client's information (e.g. first name)? Moreover, I chose a random script but the problem is that I didn't succeed to access the information of that script from another script.
 
user92578
@PichiWuana I don't know Unity at all, but maybe an object at the top of the hierarchy?
 
user92578
Then there's always the singleton
 
DH.
Duplicated cross sites...
I have no idea how to deal with it
 
@Tyyppi_77 You mean to create a class for the object?
 
user92578
Yeah
 
user92578
2:31 PM
class ClientInfo { public string FirstName; public string EmailAddress; }
 
Also what exactly are you doing? I didn't quite understand.
 
user92578
But I guess that mouse direction dude is kinda asking a follow-up...
 
I have a character that is composed of a camera and a box. The camera follows the box to where I move. So I have a script for the camera rotation and a script for the user movement (i.e. W A S D keys). I want that if I press the letter P the game stops. You can't move the camera or the box. So what I thought about is to put in one of the scripts the boolean and access that boolean from the other script.
 
Ah I completely misunderstood
 
The boolean to check if the game is paused or not so it knows if it can move or not
 
user92578
2:36 PM
Well that's very different from what you asked
 
Oh sorry
 
You can just set the boolean as static, like this:
class pausescript : MonoBehaviour { public static bool GamePaused; }
then you can access it from anywhere by using pausescript.GamePaused
you can set it to true or false, and then in the movement script check if it's true and not move
 
Ooooooh so the important part is static!
 
@Tyyppi_77 @DH flag for moderator attention stating that it's a cross post and add the link to the original post..
 
user92578
Yeah I just did that actually
 
2:38 PM
That's the most appropriate thing to do :)
 
I thought that the important reserved keyword is public. It allows me to access the object from anywhere because it is public for other classes.
 
Yeah public makes it public but you need to know the reference to the object, static fields do not belong to any spesific object
 
user92578
^
 
What do you mean by I need to know the reference to the object?
 
NormalObject obj = new NormalObject();
obj.GamePaused = true; // Normal field access
StaticObject.GamePaused = true; // Static field access
 
user92578
2:41 PM
you don't need an instance if you use static
 
Make sure you've been on at least 3 dates with the reference.
 
user92578
ROFL
 
then for all other scripts to use that spesific value of GamePaused on the NormalObject, you need to pass around the obj reference so everyone can use it to access the field
@PichiWuana Read this for instance objects: msdn.microsoft.com/en-us/library/x9afc042.aspx
 
@Lasse What is in this case StaticObject?
 
it's just normal class with static field GamePaused
 
2:43 PM
Ooh
I learned OOP but it was always hard for me to understand the meaning of static
Even though I used it a lot
 
user92578
That doesn't sound very good
 
yeah static stuff should be avoided, especially in unity it will cause problems
but a simple static boolean field does no harm
the problems arise when you set gameobject instances to static variables and forget they are around
I'd also avoid singletons in unity if at all possible
 
So in one class I will write public static bool moving = true; and in the other class that I want to access public static bool moving = CameraRotation.moving? (My first class is CameraRotation).
 
no you do not have to redeclare it in the other class
you just reference the original field by using TheFirstClass.moving
 
oooooh
 
2:48 PM
if( TheFirstClass.moving ) { Move(); }
 
And If I write TheFirstClass.moving = !TheFirstClass.moving, will it also change the value?
 
user92578
Yup
 
yeah that will swap it
 
Oooh
Much more easy
 
user92578
please don't start abusing this though
 
user92578
2:49 PM
statics can be dangerous because they can be accessed anywhere
 
user92578
so even some remote piece of code that's only supposed to play audio, but you decided to patch a bug, can change the value
 
well they still play well with namespaces and all, but yeah it's pretty high risk if the programmer is just using statics for the sake of it
using more statics will make your code spaghetti code and hard to debug and maintain
 
You mean that I need to have a track of the static variables if I abuse it
 
it's hard to follow what changes what variables and where when you are trying to read linear code that uses statics heavily
 
Yeah I can understand that
Thank you for your help
 
2:58 PM
No problem, you're welcome to ask for help any time :)
 
If I want a name for a client/user
I shouldn't use static
 
user92578
Well that kinda depends
 
user92578
I personally would like to believe that not a lot of things need the client name
 
user92578
And so you could either provide the name to those things, either as a value or a component or something
 
user92578
Maybe an Unity user should just take the wheel?
 
user92578
3:03 PM
a Unity user?
 
But if I do a multiplayer I need name, or at least username
 
user92578
yeah I didn't say anywhere that you won't need this
 
user92578
However if you do multiplayer, then static is definitely not the way to go
 
That's what I assumed
 
user92578
That's actually in general one of the good reasons to avoid static
 
user92578
3:07 PM
"What if one day I need more of these things?"
 
user92578
Also a good reason to avoid the Player player; thing in the Level class
 
You mean to use another name for the variable?
 
user92578
no
 
user92578
the point is that if you don't assume that there is only one played from the start, you'll have much easier time adding in local multiplayer
 
^
networking is really, really hard to add later
 
3:16 PM
Oooh I understand what you mean
 
user92578
@Almo didn't really even talk about networking
 
user92578
just local coop
 
It applies to both
 
^
 
user92578
but yeah networking later on, hard if not impossible
 
user92578
3:36 PM
thought about implementing a behaviour tree, decided that it was way OP for my game
 
Flying Spaghetti Monster?
I know :)
 
3:51 PM
I shouldn't be on computer this evening it seems, too hasty to answer questions without properly reading them
I feel stupid now :D well whatever
 
hahah :)
 
@Almo I'm there :p
 
@AlexandreVaillancourt you're where
outside?
probably, late response seems to indicate phone
 
In front of the a&w!
 
ok be there very soonm
 
3:57 PM
All right!
@ton.yeung the restaurant tha produces it, yes!
@ton.yeung Well it's a fast food chain :p
 
0
Q: 2D Lighting From Sun

JmrappI have been developing a game for over a year now and I have successfully implemented the basic foundation for lighting, but there are still a few things I'm struggling with. The biggest issue right now is the lighting that should be cast from the "sun". The sun should technically light up any bl...

Another terraria/minecraft copy
 
user92578
so what? a game like that is a great way to learn various concepts
 
@Tyyppi_77 See, almost any game is good to learn some game developement concepts and techniques
It's fine, but some people thinks he can put it only without any problems
> I have been developing a game for over a year now
THat's not just learning
 
user92578
Damn right it is learning
 
@Tyyppi_77 I don't think I understand what this sentence means
 
user92578
4:12 PM
@Bálint "It is learning"
 
@Tyyppi_77 There's a difference between learning and starting a game without knowledge of how you can make it
 
user92578
@Bálint Umm, not really
 
user92578
Back when I was starting I was mainly just working on a large sandbox game, where nothing worked together, but I got small components/game features working on their own
 
user92578
Later came GunHero
 
user92578
I had no idea how to program a 2D platformer
 
user92578
4:14 PM
I've been learning as I go, day by day
 
user92578
And besides, I don't think knowing vaguely how to make something rules out learning
 
user92578
Like seriously?
 
user92578
4:30 PM
I think GunHero currently uses like 600MB of RAM, which to me feels like a lot. My content loading approach is extremely naive, and I need to change the soon. However, I'm really not sure what kind of figures I should aim for. Any input?
 
user92578
Does 200MB sound reasonable?
 
user4704
600MB doesn't seem that bad at all.
 
user4704
See if you can cut 200MB.
 
user4704
That's probably more achievable.
 
user92578
Oh, all right. My current approach however is incredibly primitive: I load all the PNG files I can find inside the Resource directory at startup.
 
user4704
4:33 PM
Regardless of whether or not they are referenced?
 
user92578
Yeah.
 
user4704
Do you actually reference them all?
 
user92578
Most likely not. Probably most of them, but not everyone.
 
user4704
If so that doesn't seem naive. If not it seems a few deletes would make an easy fix :D
 
user92578
Well I guess that's true :P
 
user92578
4:34 PM
So is this actually a viable approach?
 
user4704
Sure.
 
user92578
My main concern is actually the level thumbnails. Each one is 1920x1080, and there currently are ~50 of those, but at release I want to have atleast 125 levels.
 
user92578
I need to display all of them when the level selection menu is open, but keeping all that loaded all the time does seem a little unnecessary.
 
user92578
TBH I've always thought that most games use like reference counting or something similar.
 
user92578
Between levels is not an issue, since all the entity images and the tileset are already loaded.
 
user92578
4:38 PM
However I know that the current approach won't be sustainable at launch.
 
user92578
Mainly, yeah.
 
user92578
Loading levels has not been an issue
 
user92578
Well the thing is that most of the stuff in the levels, will be in all of the levels.
 
user92578
Tileset is one texture. Entities have their own textures, but there are a lot of entities that appear in all of the levels. Sure, I introduce some entities later in the game, or stop using some later in the game, but still, the base is all there.
 
user92578
So I guess a way to improve this would be to add some sort of timer for assets. Unload textures that haven't been requested in a long time.
 
user92578
4:42 PM
But that would also require reference counting the sprite instances.
 
The main thing seems to be the size of the thumbnails, why not load smaller (atlassed?) images for the thumbnails and then load the bigger ones as needed
 
@Tyyppi_77 Is Gunhero moddable?
 
user92578
@Bálint You can tweak the XML files for weapons, but that's pretty much it.
 
user92578
@KevinvanderVelden Hmm, this could work I guess.
 
user92578
I need to overhaul the thumbnail system anyways actually.
 
4:43 PM
Do you use entity comoponent systems, and 8f yes, then wich type?
 
user92578
No.
 
user92578
I use a monolithic entity architecture.
 
user4704
Yes, and the type that makes sense.
 
Is there any chance you add it? That would make it really moddable
 
@JoshPetrie not a fan of ECS? =p
 
user4704
4:44 PM
I like it fine.
 
@Bálint oh yes, just let him rewrite everything, no big deal
 
user92578
@Bálint These two aren't actually related at all.
 
user92578
And no, I won't.
 
user4704
I'm not a fan of the attempt to force everything into it or aggressively apply taxonomical classification.
 
@KevinvanderVelden that's why I asked
 
user4704
4:45 PM
e.g., "how do I everything in my ECS?"
 
user92578
Please someone explain to me how components make modding easier?
 
@Tyyppi_77 They kind of are, at least for how I like to implement it
 
@Tyyppi_77 It makes some things easier to make data-driven
 
user4704
@Tyyppi_77 They are a way to factor out things (usually data or behavior) into isolated parts.
 
user4704
Making replacing those parts easier.
 
4:46 PM
And data-driven easily leads to moddable
 
If you have a certain type of ECS, then the modders can write custom components like plugins
 
user4704
They do not, per se make modding easier.
 
user4704
Factoring out and data-driving things makes modding easier.
 
user92578
Oh, I see. But the modders would still need full access to my source code and have their complication setups set-up.
 
Not if you make it data driven
 
4:47 PM
Then ECS done right makes modding easier
 
user4704
Components are one way to achieve that, and in particular a currently common approach due to the reaction to silly game developments making silly OO choices like extremely deep nested classes with obscene MI overuse, etc.
 
@Bálint No.
 
user92578
I'm a silly game developer making extremely quite deep nested classes.
 
user4704
I doubt anything you're doing fits into the same category of things I'm thinking of.
 
If you have it sufficiently data driven you can make it so that you can add, make an enemy that spawns entities. Those entities have no motion component and a suicide-bomber AI/abillity. Tada mine layer
Things like that can be done with datadriven ECS designs quite easily, but it requires a bunch of work to get to that point
 
user92578
4:48 PM
So basically defining entities in content files?
 
user4704
You already have a level editor. Between that and the ability to tweak the weapon data you probably have a sufficient modding platform and certainly shouldn't worry about it.
 
user4704
imo
 
@Tyyppi_77 that's the data-driven bit yeah =p
And the difference between data-driven and modable is not obfuscating the datafiles =p
 
user92578
Yeah I don't really care about modding :P And that's a great point, level editor is and will be enough. And if some script-kid wants to change the firerate to an insane number, and show their friends, that's cool too.
 
@Tyyppi_77 My system allows you to make custom components, every comoponent has an id and the components can reference each ither based on their id-s. Also, by just using a simple text file you can create a new entity with custom components
 
user4704
4:50 PM
I expect the time will come when you start GunHero 2 or whatever you make on this codebase next where you'll realize you want to make a ton of sweeping changes to something but you'll have to write a bunch of code to do it.
 
user92578
Yeah there will be a time like that. I want GunHero 2 or whatever the next project to have networking.
 
user4704
At that point you should probably consider driving more stuff about your game object/entity system composable and data driven, because at that point you'll see real benefits.
 
user4704
This close to shipping it would be a Bad Idea.
 
user92578
Exactly.
 
user92578
So, we arrived at "take lower resolution thumbnails"?
 
user4704
4:52 PM
I think that's a good place to start.
 
user4704
Load low-res ones immediately.
 
Gunhero 2: return of the broforce ripoff
 
user4704
Load high-res ones in the background.
 
@JoshPetrie And possibly the option to not do that
 
user92578
I actually need to try if I could move the image loading back to the loading thread.
 
user4704
4:53 PM
And/or dump them when you leave the level select screen.
 
user92578
Yeah I do want to probably try that too.
 
user4704
Basically if you think it's mainly the images for thumbnails that bloat memory usage, just focus on that
 
How much time it is to load 1 thumbnail?
 
user92578
Again: loading times aren't an issue. It's the RAM footprint I'm concerned here about.
 
user92578
And then if I find out that something else is an issue, I'll focus on that, after the thumbnails.
 
user92578
4:54 PM
Oh, also, there is no reason for me to take thumbnails at 1920x1080
 
I ask it because if not too much, then you could load it when you show the level select screen
 
user92578
I mean the game is essentially always 480x270, but with scaling.
 
I mean, they'd only be thumbnails on 4320p screens
 
DH.
If it's thumbnail you can probably cut that by half and still have a good thumbnail
 
Which don't yet exist
 
user92578
4:55 PM
So I could just take a screenshot at 480x270 from a render texture or something, and then scale the image.
 
I just wanted to ask that if you have a pixel-art game, then why the hell do you need them to be that huge
 
user92578
Lightmaps, mainly.
 
user92578
Those are actually incredibly small textures that are rendered with interpolation.
 
user92578
So I'll either need to apply those to the thumbnails separately, at the rendering stage, or think about if they are even an issue.
 
00:00 - 17:0017:00 - 00:00

« first day (2247 days earlier)      last day (2772 days later) »