« first day (1858 days earlier)      last day (3459 days later) » 

Jon
Jon
00:00
Dudes, this is on sale, get it now!!
00:13
hahah
00:41
@Lokkij @IcyDefiance yay Unconditional achievement in TIS-100!
wow you can create new TIS puzzles with LUA scripts... o_0
01:20
thank you @Chris I appreciate you taking the time to answer me :)
 
1 hour later…
02:58
Carbon is a lot better when it's missing two electrons. (C++)
 
5 hours later…
user92578
07:36
OOOOkay
user92578
Now back to the level file IO
user92578
It's gonna be quite messy
user92578
I need to separate the actual level loading and the loading to the level editor, because their needs are just so different
user92578
Maybe I can clean it up once I'm done
user92578
Basically the level editor doesn't load triggers or collision meshes, only the tiles and the entities, and it generates the collision data and the triggers based on the tiles and entities
user92578
07:38
But the level needs triggers and collisions, so I need to write them to the file
user92578
See how messy this already is?
user92578
</rant>
user92578
sorry
Just got a brand new monitor for my birthday, but it turns out that windows 10 has ruined my HDMI port -.-
@Tyyppi_77 Not too bad. Just add optional metadata :P
user92578
@Hjorthenify nice and not nice
user92578
07:49
it's your birthday?
user92578
grats a lot!
Thanks :)
At least I can use the monitor for my pi
user92578
Ah
happpy bdayyy
RIP HDMI port
Win10 just not liking it?
07:58
I think it has something to do with the way windows 10 handles dualgraphics
and thanks :)
Just tried to disable my intel card. That just made win10 go nuts
:(((
08:15
I really need to get my dual boot setup..
Happy birthday @Hjorthenify!
user92578
08:40
How old are you now Hjor?
user92578
08:55
user92578
It's something I guess
user92578
Ah,I think I was writing in the wrong order
user92578
Okay, now I've got tile saving & loading working!
user92578
Now I need to clean up, and then add trigger & collision saving
09:18
@KevinvanderVelden Thanks!
@Tyyppi_77 20
user92578
That's a nice and round number!
user92578
Feel old yet? :D
user92578
09:38
WinAPI file dialogs totally freeze when I try to use them
Do you keep doing the windows event loop?
user92578
I don't think I need to do that
Then you would think wrong :)
user92578
Well
user92578
It's working fine now
user92578
09:41
I just didn't make the dialog a child of my game window
Ah
That would also help
user92578
I don't do any events stuff, and now it works smooth
Are you still rendering the game or are you busy blocking till you get a response?
user92578
I'm not sure how that works
user92578
I'd think that the game freezes
09:42
Check it out, do things still render? =p
user92578
Now if froze again
user92578
It's not a child of the game window
user92578
Game window is unresponsive
user92578
The file dialog is just all white
I don't think I've seen a game use the OS file dialog box before
09:45
I have back in the day.
they just get the directory structure but render it in-game, rather than using anything native
yeah for sure, but these days...
I think I have anyway.
I was probably like 4 though.
user92578
I think that doing my own file dialog would be way out of the current scope at least
Windows 3.1 maybe
No. LOL.
I'm not that old.
I'm 16.
user92578
09:46
Sure, it would be cross-platform, but for simple dev tools...
user92578
What? You sound so smart that I've thought you're a lot older
I'm thinking Castle of the Winds had a save/load feature with that
user92578
Or maybe it's just the fact that you use your full name
Well I didn't intend to use my full name, I just never bothered changing it.
@Tyyppi_77 Sounding smart isn't that hard these days :D/:(
user92578
:D
09:50
Sweet, pathfinding is done! :D
user92578
Nice
I'm at 11101 bytes
@KevinvanderVelden What method?
user92578
Any ides why my dialog might freeze?
09:51
Ah
@Tyyppi_77 SDL doesn't handle some events correct?
No short circuiting (i.e., it searches the entire map instead of stopping when it has a proper target), no diagonals (they would look weird in the isometric map anyway) and it uses the javascript build in sort
user92578
Here's what happens:
user92578
Because that is way easier :D
user92578
I don't think it's an SDL event thing
user92578
09:56
fuuuuck
user92578
I just want to get this done quickly because I have loads and loads of homework to do
You could try plugging this thing in: github.com/mlabbe/nativefiledialog
user92578
I actually thought about that
user92578
However I am more of a "do it myself" type of guy...
user92578
Also looking at the source that seems to do it exactly like I'm currently doing
10:12
@KevinvanderVelden How are u with C#?
@Tyyppi_77 that's so different with the layout I use
user92578
10:30
user92578
That's my usual layout
user92578
Then I have to filled layout for debugging
usually keep solution explorer in the left, and output window is usually open
user92578
Now I'll do a lot of homework
user92578
Ah
user92578
10:31
I keep the solution explorer on the right because then it's on the edge of my monitor, as I keep VS on my right monitor
user92578
It wouldn't make sense to keep the solution explorer in the center or my focus
user92578
I'll be back once I'm done with the homework
10:47
@Tyyppi_77 I never thought of it that way... but then again, I usually have VS in my left monitor, so I guess it's the same logic as your :P
@Hjorthenify it's my day job
=p
Ah cool :D
Pip
Pip
11:17
morning all
Pip
Pip
@Hjorthenify Happy Birthday!
user92578
11:40
Well I was really productive!
user92578
Wrote my part of the physics project and finished my religion summary for this week
user92578
Hey @Pip, how's it going?
Pip
Pip
still have some homework to do before school starts
otherwise, good!
user92578
Now on to the dialog fighting
user92578
Fuck
user92578
11:51
Sometimes it works, sometimes it doesn't
user92578
Ha!
user92578
I had to disable Visual Leak Detector
user92578
12:09
So yeah, I can now edit and test (almost) functional levels
user92578
Pip
Pip
awesome
12:24
Hi guys
user92578
Hi
Sup? Newcomer here
user92578
Welcome!
user92578
I'm working on a level editor for my game
Pip
Pip
Tyyppi is doing work
12:25
what game engine are u using?
Pip
Pip
He's not
user92578
I use SDL2 for everything, but the whole framework is my own
Pip
Pip
All of his graphics are straight SDL
user92578
C++
Pip
Pip
welp. Sniped :P
user92578
12:26
Haha :D
wow
hardcore there i reckon
user92578
Not really
user92578
I just like being in control of everything
user92578
Well, of most of stuff
go for obama's replacement in next election then
jk
:D
user92578
12:27
lol
have you ever use unity?
Pip
Pip
I have
@Jon uses it frequently
i'm new to unity, so i'm not sure what's this kind of functionality called
basically
i wanna make a game, which skin can be purchased via iap (like crossy road char change)
so, players can change his/her char in-game
how to learn about that?
i mean
Pip
Pip
I mean
the keyword to google
Pip
Pip
12:30
that's not super hard.. there's no real key word
not sure how to phrase such functionality
Pip
Pip
you literally just assign a different sprite to it
so you are not making a new prefab to every single character right?
Pip
Pip
nope
Pip
Pip
12:31
one prefab, keep track of the sprite in an encrypted text file or something
assign the correct one on game load
so, if I'm correct, the character prefab is just an empty object with a script attached to manage which sprite is shown. right?
Pip
Pip
It needs a sprite renderer
and any other components that you want
but yes
oh sure. forgot to mention sprite renderer
1 more thing i'm not quite sure
Pip
Pip
sup?
what's the best method to keep screen:character same?
Pip
Pip
12:35
screen:character same?
so, on larger device (tablet or such), the object will be larger
Pip
Pip
oh i see
user92578
The aspect resolution
Pip
Pip
you want the resolution the same
Pip
Pip
12:36
(aspect ratio, sorry)
i want to make a character is 1/8 of the screen width
Pip
Pip
both answers are solutions
so i'm not going to "assign" the value directly
ok i'll check it out
Pip
Pip
12:37
coolcool
english is not my main language, so looking the "keyword" to google for certain problem is common
haha
Pip
Pip
heh, not an issue
A lot of the people speak other languages in here. We all chat in English, but... yeah
user92578
Small thing, but I added file type filters to the dialogs:
user92578
Pip
Pip
Make it "Level File (.lvl)"
user92578
12:40
Ah right, sure, thanks
Pip
Pip
np
user92578
Uuuh I would so like to wrap rapidxml in my own XML layer...
user92578
hmm
user92578
Maybe another day
Pip
Pip
what's rapidxml?
oh nvm
user92578
12:45
It's the library I use for reading & writing XML data
user92578
@Pip dude I so thought that there was a piece of dust on my monitor on the second line of that
Pip
Pip
lol sorry
Unintentional :P
user92578
:D
user92578
13:08
Hmm
user92578
Something is fucked up
user92578
3c4c 6576 656c 2000 3d22 3230 2220 003d
user92578
Stuff like that ends up to the level file, no human-readable data
user92578
It's valid text data
user92578
But it looks like that
user92578
13:11
I dumped it into a hex editor and it turns out to be valid XML
user92578
Something is wrong
user92578
No idea what
Jon
Jon
wizard put a hex on it
user92578
heh
Jon
Jon
you are not saving it as hex data?
user92578
13:14
No
user92578
And it just worked, I just added a convenience method for adding attributes
user92578
Got it
user92578
Super weird behaviour
user92578
So it was a string lifetime issue
user92578
Which for some definitely sane reason ended up with the document writing it's data as hex
13:32
@Pip hi pip. is unity doesn't detect field of view when changed via script?
private float myDesiredHorizontalFov = 9f;
private float defaultAspectRatio = 9 / 16f;
private Camera myCam;

void Start () {

myCam = GetComponent<Camera> ();

Debug.Log (myCam.fieldOfView);
myCam.fieldOfView = myDesiredHorizontalFov *defaultAspectRatio / ((float)myCam.pixelWidth / myCam.pixelHeight);
Debug.Log (myCam.fieldOfView);
}
the "Game" view seems doesn't changed
user92578
Does the code run?
user92578
What does Debug.Log show?
testing on 9:16 and 10:16 respectively
another thing which is weird is, the 9:16 should equal, since it's the same as my defaultAspectRatio
but it's not
user92578
Tells you to use the "Main" camera
13:53
yes, it's my main cam
user92578
and is the camera orthographic?
user92578
Yeah field of view doesn't apply to orthographic camera
not sure on what orthographic means. (it's a 2d game so..)
user92578
orthographic camera ignores perspective
user92578
13:54
All tough you'd want to confim this from an Unity guy
perspective camera somehow scrambled up the view
not sure why
user92578
> Field of view is ignored when camera is orthographic (see orthographic)
yeah. i never tweaked that prop before. thanks for reminding me
perpective cam! scrambled up the view lol
so
i have another idea on this
user92578
for a 2d game you probably want to use the ortho camera
13:57
yeah
i think i'll tweak it a bit first
thanks
@MosesAprico Use Size, not FOV for ortho also use Camera.main to access the camera instead of getting the component(unless you plan to have multiple cameras)
Size (when Orthographic is selected) The viewport size of the Camera when set to Orthographic.
Field of view (when Perspective is selected) Width of the Camera’s view angle, measured in degrees along the local Y axis.
From the documentation
@Pip Thanks!
Pip
Pip
HOLY CRAP Hjor
@Hjorthenify hi there. thanks for replying! actually i'm going to check out the size too now (inspiration after going to toilet lol). :)
Pip
Pip
that startled the crap out of me XD
np :D
@Pip You're welcome! :D
I can't decide how I want to structure this pathfinding system -.-
14:23
It takes less than 80ms to generate this clusterfuck
Pip
Pip
looks like you need some culling, still
but nice
Yeah I need to remove nodes which are close to each other
Pip
Pip
no kidding
Well merge them :P
@Hjorthenify how did the original mesh look like?
14:24
And remove lines which are close to each other and going the same direction
user92578
Nice job
may I ask, what you were trying to do, that ended up in that mess?
Pip
Pip
It's a pathfinding visualization
@Ali.S Polygrid map
I'm refactoring my pathfinder, but otherwise I would have shown you :P
14:27
still I don't get it... but I guess it's not as bad as it seems ...
There is room for optimization, but the pathfinder itself is quite fast
if you learn one thing from TIS-100, it's that there's always room for more optimization
Haha true :P
:)
if you play that game add me on steam so i can see your scores
I will once I can afford it :D
14:36
:)
Also the code is available on bitbucket(it ain't pretty) if anyone is interested: bitbucket.org/Hjorthenify/pathfinding
14:50
Also if you take a look at it and have any suggestions, feel free to use the issue tracker or ping me here :D
Jon
Jon
holy crap
that is a lot of lines
i haven't seen that many lines since a rick james concert
@Jon I haven't seen that many lines since I saw a Trentemöller concert
user92578
Okay I think I'm ready to start adding entities
user92578
Maybe
user92578
I'll try and see what happens :D
14:59
@Tyyppi_77 What kind of entities?

« first day (1858 days earlier)      last day (3459 days later) »