<<29-11-2020>>

00:03:00FromDiscord<iWonderAboutTuatara> I see
00:03:01FromDiscord<iWonderAboutTuatara> thanks!
00:09:24*hmmm quit ()
00:14:43*wiml joined #nim
00:31:07*krux02 quit (Remote host closed the connection)
00:33:35FromDiscord<notchris> If I have an enum of the type NamedColor, how can i use it as an int
00:33:58FromDiscord<notchris> i have a procedure that expects an int, but i wanted to pass in an enum which represents the int
00:35:06FromDiscord<notchris> ohh I do ord(), sorry!
00:42:07FromDiscord<notchris> @iWonderAboutTuatara you have to build raylib to generate the so, or use homebrew, get the raylib cask
00:42:18FromDiscord<ElegantBeef> Chris i've got to ask as i'm interested, did you do the hint thing yet?
00:42:21FromDiscord<notchris> For raygui, its more difficult since its not built into raylib by default
00:42:32*wiml quit (Ping timeout: 260 seconds)
00:42:33FromDiscord<iWonderAboutTuatara> Oh is it a seperate process for raygui?
00:42:47FromDiscord<notchris> Wow good timing @ElegantBeef I was about to do that
00:42:53FromDiscord<notchris> have it open now lmao
00:43:03FromDiscord<ElegantBeef> Ah, i'm just interested in seeing if it works
00:43:20FromDiscord<notchris> @iWonderAboutTuatara if youre on osx, its like 1 or two more steps, it was annoying though, i have it working on osx latest
00:43:37FromDiscord<ElegantBeef> I'm uncertain if they're on macos, but it should be similar for linux
00:43:49FromDiscord<iWonderAboutTuatara> I'm on Linux which should be similar
00:43:51FromDiscord<iWonderAboutTuatara> Yeah
00:44:08FromDiscord<iWonderAboutTuatara> I don't think we have brew in Linux?
00:44:10FromDiscord<iWonderAboutTuatara> Not sure
00:44:12FromDiscord<iWonderAboutTuatara> Might be in apt
00:44:18FromDiscord<ElegantBeef> We do, but it's just a package manager
00:44:28FromDiscord<notchris> The only thing to watch out for id say
00:44:33FromDiscord<notchris> Is once you do install raylib
00:44:47FromDiscord<notchris> the so may be named differently than what the package is looking for, so you may need ot make a dlink
00:44:58FromDiscord<notchris> i think that happened to me
00:44:58FromDiscord<ElegantBeef> You dont want to install raylib, you want to dynamically link it afaik, so you can ship it
00:45:33FromDiscord<notchris> yeah sorry i used poor terminology
00:45:53FromDiscord<notchris> brb gonna grab a snapple
00:45:55FromDiscord<ElegantBeef> I suppose you could statically link it though, but seems like trouble when they didnt even know where to get the .so (no offence) 😄
00:46:21FromDiscord<notchris> in their defense, the build steps arent documented super well for multi os
00:47:52FromDiscord<notchris> btw I can confirm multiple issues with raygui still exist, mainly input /textbox stuff, the 2d/3d rendering was great though, was able to run multiple shaders and apply custom materials on objects etc
00:51:41FromDiscord<iWonderAboutTuatara> this is so confusing
00:51:44FromDiscord<iWonderAboutTuatara> I got a make error
00:51:53FromDiscord<iWonderAboutTuatara> sent a long message, see http://ix.io/2FRw
00:52:02FromDiscord<iWonderAboutTuatara> (edit) "long message," => "code paste," | "http://ix.io/2FRw" => "https://play.nim-lang.org/#ix=2FRx"
00:52:13FromDiscord<ElegantBeef> oh you're installing
00:52:24FromDiscord<iWonderAboutTuatara> oh I should sudo?
00:52:25FromDiscord<ElegantBeef> for that you need sudo to move it to the directory, but like i said you dont want to make install
00:52:28FromDiscord<iWonderAboutTuatara> or should I not install at all?
00:52:41FromDiscord<ElegantBeef> you want the dynamic shared library
00:52:50FromDiscord<iWonderAboutTuatara> how do I get that without installing?
00:53:02FromDiscord<ElegantBeef> I guess you can install it
00:53:15FromDiscord<ElegantBeef> Just need to ship it with the binary whenever you ship your application
00:53:20FromDiscord<notchris> @ElegantBeef this one, right? SDL_HINT_VIDEO_WINDOW_SHARE_PIXEL_FORMAT
00:53:35FromDiscord<iWonderAboutTuatara> how do I do that?
00:53:43FromDiscord<iWonderAboutTuatara> just copy the folder it's installed to?
00:54:04FromDiscord<ElegantBeef> After installing `locate libraylib.so` and cp it from there next to your binary
00:54:17FromDiscord<ElegantBeef> @notchris `SDL_HINT_VIDEO_HIGHDPI_DISABLED`
00:54:36FromDiscord<notchris> Awesome, trying now
00:55:04FromDiscord<iWonderAboutTuatara> that should be fine right?
00:55:12FromDiscord<iWonderAboutTuatara> or is there a better way?
00:55:29FromDiscord<ElegantBeef> I mean i told you what i'd do, idk much about libraries though
00:55:41FromDiscord<iWonderAboutTuatara> I'm extremely new to this
00:55:41*wiml joined #nim
00:55:53FromDiscord<iWonderAboutTuatara> This kind of thing is quite a bit easier in python than C
00:56:02FromDiscord<iWonderAboutTuatara> so i have no idea what I'm doing
00:56:11FromDiscord<ElegantBeef> It's the exact same in python as in C
00:56:20FromDiscord<ElegantBeef> If you need a library, you have to build it and get the so
00:56:25FromDiscord<iWonderAboutTuatara> how would I dynamically link it?
00:56:31FromDiscord<iWonderAboutTuatara> In python everything is in pip
00:56:38FromDiscord<iWonderAboutTuatara> pip handles everything
00:56:47FromDiscord<ElegantBeef> ~~Uncertain if that's true~~
00:56:49*lmariscal quit (Quit: I'm Out!)
00:56:53FromDiscord<ElegantBeef> Just copy it next to the binary when you ship it
00:57:07FromDiscord<ElegantBeef> After you install it, the .so will be in your search path so should work
00:57:21FromDiscord<iWonderAboutTuatara> just `locate libraylib.so` and cp it?
00:57:33FromDiscord<iWonderAboutTuatara> Got it
00:57:35FromDiscord<iWonderAboutTuatara> that's not bad at all
00:57:36FromDiscord<iWonderAboutTuatara> thanks!
00:57:39FromDiscord<ElegantBeef> np
00:58:04FromDiscord<ElegantBeef> Though like i said you might be able to statically link it, but i'm uncertain how to do that
00:58:27FromDiscord<iWonderAboutTuatara> How would I locate it?
00:58:27FromDiscord<ElegantBeef> Which means the so would be included in the binary, so it's actually "dependancy less"
00:58:36FromDiscord<ElegantBeef> locate is a command
00:58:42FromDiscord<iWonderAboutTuatara> I don't necessarily need it to be dependany less
00:58:45FromDiscord<iWonderAboutTuatara> oh do I need to install it?
00:58:50FromDiscord<iWonderAboutTuatara> Ubuntu doesn't seem to recognize
00:58:52FromDiscord<ElegantBeef> I mean it's installed on my system
00:58:58FromDiscord<ElegantBeef> I'm un an ubuntu derived
00:59:03FromDiscord<iWonderAboutTuatara> there's an apt package called mlocate apparently
00:59:07FromDiscord<iWonderAboutTuatara> might be installed by default
00:59:12FromDiscord<iWonderAboutTuatara> are you on popos?
00:59:17FromDiscord<ElegantBeef> No regolith
00:59:23FromDiscord<iWonderAboutTuatara> never heard of it
00:59:36FromDiscord<ElegantBeef> @notchris i dont like that i dont hear a celebratory hoorah
00:59:48FromDiscord<ElegantBeef> It's just ubuntu with i3wm-gaps and gnome intergration
01:00:10FromDiscord<ElegantBeef> So gtk applications use an easy to customize colour theme and i can use gnome settings to control my system
01:00:26FromDiscord<iWonderAboutTuatara> looks super nice actually
01:01:55FromDiscord<notchris> haha @ElegantBeef so far im testing on 800x600
01:02:02FromDiscord<notchris> toggling that flag yields...
01:02:06FromDiscord<notchris> https://media.discordapp.net/attachments/371759389889003532/782411027375456286/Screen_Shot_2020-11-28_at_8.01.27_PM.png
01:02:12FromDiscord<ElegantBeef> In theory it should now be a 800x600 px window
01:02:23FromDiscord<notchris> so 1/4 the size
01:02:27FromDiscord<ElegantBeef> yea
01:02:44FromDiscord<notchris> hmm
01:02:53FromDiscord<ElegantBeef> Which it seems it is, no?
01:03:13FromDiscord<notchris> It does, but the window would also need to factor that in
01:03:20FromDiscord<ElegantBeef> I'd say try with nico
01:03:28FromDiscord<ElegantBeef> It has that whole scale image to window size
01:03:35FromDiscord<notchris> well im trying this on a vanilla sdl2 project
01:03:40FromDiscord<notchris> because on nico, we're using opengl renderer
01:03:43FromDiscord<notchris> so we can use shaders
01:03:54FromDiscord<ElegantBeef> It's not on by default though iirc
01:04:04FromDiscord<notchris> I think it is
01:04:22FromDiscord<ElegantBeef> https://media.discordapp.net/attachments/371759389889003532/782411601227677736/unknown.png
01:04:25FromDiscord<notchris> Err, you're right its off
01:04:31FromDiscord<notchris> oh you mean opengl being off?
01:04:35FromDiscord<ElegantBeef> yea
01:04:40FromDiscord<notchris> yeah we had to enable opengl
01:04:41FromDiscord<JSGRANT> Would there be any point in trying to get "idiomatic 'dear imgui' bindings" for Nim -- or does it map close enough as-is via cimgui? Haven't messed with imgui in-general but just recently saw https://github.com/hoffstadt/DearPyGui and it seemed very nice to use. (Know there are some pretty-straight bindings out there for Nim -- just don't know how idiomatic it feels with no context lol)
01:04:52FromDiscord<notchris> you pass a flag in the compilation to enable opengl for nico
01:05:07FromDiscord<notchris> which isnt in the docs
01:05:13FromDiscord<notchris> iirc
01:05:15FromDiscord<ElegantBeef> I mean imgui is immeditate GUI, so even idiomatic it should be.... identical
01:05:17FromDiscord<ElegantBeef> Yea i know that
01:05:20*lmariscal joined #nim
01:05:32FromDiscord<ElegantBeef> I did show where it imports opengl, so i'd hope i know how to enable it 😛
01:05:42FromDiscord<iWonderAboutTuatara> apparently mlocate takes >20 minutes to install on windows
01:05:44FromDiscord<iWonderAboutTuatara> so that's fun
01:05:44FromDiscord<notchris> lmao
01:05:49FromDiscord<notchris> that was you, wasn't it @ElegantBeef
01:06:00FromDiscord<ElegantBeef> @JSGRANT how do you suggest nimdiomatic IMGUI
01:06:28FromDiscord<ElegantBeef> I mean it's in `/usr/local/lib/`
01:06:54FromDiscord<ElegantBeef> Just locate atleast on linux isnt too long to install and works quickly
01:08:05FromDiscord<ElegantBeef> Uh oh exelotl is here to call me out 😄
01:08:52FromDiscord<JSGRANT> @ElegantBeef I mean I don't know the api in-general and/or really at-all; To make any suggestions -- just find it weird that such an attempt in Python is "that popular" but it may just be ... because it doesn't nicely map via Python so there is more concious effort needed so more attiention / focus there generally
01:09:04FromDiscord<exelotl> I was about to change the topic completely lol
01:09:19FromDiscord<ElegantBeef> imgui is a lot of `if button: #doThing here`
01:09:47FromDiscord<ElegantBeef> It's a very declarative UI method
01:10:22FromDiscord<ElegantBeef> Impbox has his own imgui implemented for nico you could look at for a nim example of an imgui https://github.com/ftsf/nico/blob/master/examples/gui.nim#L21
01:10:27FromDiscord<exelotl> re: my question the other day about getting the number of values in an `enum` - is there a better way to get a full set than `{T.low .. T.high}` ?
01:11:22FromDiscord<JSGRANT> @ElegantBeef Oh wow, yeah that's pretty simple & clean
01:11:27FromDiscord<ElegantBeef> I think that'd be the cleanest method exelotl
01:11:50FromDiscord<ElegantBeef> You could do something silly where you figureout the size you need and just write that many bytes as `0xff`
01:12:00FromDiscord<ElegantBeef> Since "all" is just the entire bitset enabled
01:12:24FromDiscord<exelotl> hehe, yeah could do that, but I guess there's no point
01:12:45FromDiscord<ElegantBeef> exelotl you sometimes worry about weird things 😛
01:12:58FromDiscord<ElegantBeef> ~~Guess that's why you're making a GBA game in 2020~~
01:13:39FromDiscord<exelotl> I want to rewrite this file to be pure Nim https://github.com/exelotl/natu/blob/master/natu/private/input.nim :P
01:14:01FromDiscord<ElegantBeef> ah
01:15:06FromDiscord<exelotl> the funny thing is, the original C module had an enum-like thing going (KI_A = 1, KI_B = 2, etc.)
01:15:13FromDiscord<exelotl> I didn't know about Nim sets at the time
01:15:31FromDiscord<exelotl> I looked at it and thought "what's the point in that" and got rid of it xD
01:15:47FromDiscord<ElegantBeef> @JSGRANT obviously though you could use macros/templates to make it a bit less redundant, but for the most part imgui already pretty idiomatic, although i think the dear imgui due to interoping to C++(C?) does do some things a little weird
01:17:09FromDiscord<ElegantBeef> I assume the tonc.h is just a basic input manager file
01:18:04FromDiscord<JSGRANT> Wonder if there are any notable "pure nim immediate-mode guis" floating around; Seems like a neat project
01:18:32FromDiscord<ElegantBeef> The one i just showed you was 😛
01:19:38FromDiscord<ElegantBeef> Seems like atleast on github no one is embarking on that
01:19:38FromDiscord<JSGRANT> @ElegantBeef Oh, that's a seperate immediate-mode gui ; Which name just happens to be imgui ...? lol
01:19:50FromDiscord<ElegantBeef> imgui... is just immediate mode gui
01:20:04FromDiscord<ElegantBeef> i hate that dearimgui is the default "imgui" people think of
01:20:43FromDiscord<exelotl> wait there a library that's just called imgui? xD
01:20:48*mbomba joined #nim
01:20:50FromDiscord<exelotl> there isn't
01:21:06FromDiscord<ElegantBeef> https://github.com/ocornut/imgui
01:21:13FromDiscord<JSGRANT> Isn't Dear Imgui a rename or something?
01:21:19FromDiscord<ElegantBeef> the repo is imgui, but dearimgui is the name of it now
01:21:34FromDiscord<JSGRANT> Yeah, was going to say
01:21:35FromDiscord<ElegantBeef> It's a horrid case of the name being what it is, so it just confusues people
01:22:19FromDiscord<JSGRANT> Probably for like 3/4th of people aware of it equivicate the concept and that "shorthand"
01:22:20FromDiscord<ElegantBeef> not all imguis are imgui but imgui is an imgui
01:23:01FromDiscord<ElegantBeef> This is why nuklear is cool 😄
01:23:16FromDiscord<JSGRANT> Is nuklear the C one?
01:23:20FromDiscord<notchris> all of the nuklear builds for me have faildd
01:23:22FromDiscord<ElegantBeef> It has a name that's not ambigious
01:23:23FromDiscord<ElegantBeef> Yea
01:23:40FromDiscord<ElegantBeef> I have never used nuklear, have use the nimgl imgui bidnings and they're pretty nice
01:24:00FromDiscord<ElegantBeef> Think zachary did the wrapper for nuklear and they're a bit outdated iirc
01:24:02FromDiscord<ElegantBeef> or rely on bgfx
01:24:04FromDiscord<ElegantBeef> dont recall 😛
01:24:40FromDiscord<JSGRANT> _still sorta-kinda wants to try to replace his stream setup with immediate-mode graphics ... to get away from all this freaking web-tech / widget bloat and has been loosely looking at options. Are there any other biggens besides Dear Imgui & Nuklear to look out for?_
01:24:56FromDiscord<ElegantBeef> You could try nimx/fidget instead 😄
01:25:24FromDiscord<Daniel> https://github.com/Immediate-Mode-UI/Nuklear
01:25:43FromDiscord<Daniel> Yea, go with fidget, it uses Figma drag and drop gui builder.
01:25:45FromDiscord<ElegantBeef> They arent imgui's but they're gui frameworks
01:26:00FromDiscord<JSGRANT> Is Fidget themeable? Haven't really messed with it
01:26:08FromDiscord<ElegantBeef> I've honestly never used the figma editor, which probably causes treeform an anyuerism
01:26:13FromDiscord<ElegantBeef> You'd have to make the theming yourself
01:26:45FromDiscord<JSGRANT> Yeah, not too interested in the wysiwug styled editor / builder for guis
01:27:43FromDiscord<JSGRANT> Does this basically entail CSS I'm guessing?
01:27:51FromDiscord<ElegantBeef> Well whatever you want
01:27:57FromDiscord<ElegantBeef> You could use nimscript to theme it if you so wished
01:28:10FromDiscord<ElegantBeef> Got my moe fork doing just that for reference
01:29:34FromDiscord<ElegantBeef> It is as simple as passing in a hexcolour into `fill`
01:29:39FromDiscord<ElegantBeef> For fidget that is
01:29:41FromDiscord<JSGRANT> Will need to look into my options more; Really want to get "something" going by mid next-year. I was considering an immediate-mode gui more-so with the intention I could run some sort of shader in the gaps behind it or something for a visual boost
01:30:22FromDiscord<ElegantBeef> Well fidget does use shaders to render
01:30:28FromDiscord<JSGRANT> Right now, all the streamlab widgets use a disgusting amount of resources on this budget workstaiton computer
01:30:33*a_chou joined #nim
01:30:58FromDiscord<JSGRANT> And want to start actually streaming once-a-week next year doing somesort of gamedev; Godot (x Nim) or otherwise
01:31:45FromDiscord<ElegantBeef> Just be like pmunch and program things to make your stream/life better whilst streaming
01:34:04FromDiscord<JSGRANT> @ElegantBeef Also yeah, I'll def look into it; I just have VERY LIMITED knowledge in this domain -- the most I've ever done via a 'real gui' was a few GTK apps like a decade ago (which btw, Ginto looks like a decent option generally ... probably not for this though).
01:34:26FromDiscord<JSGRANT> @ElegantBeef Honestly that's probably the way to go; Just perma-dogfood it.
01:35:01FromDiscord<ElegantBeef> I also have 0 knowledge here 😛
01:35:08*lritter quit (Ping timeout: 272 seconds)
01:35:32FromDiscord<ElegantBeef> I want to make a text editor so i have tried fidget/nimx for those, but i'm just questioning if i should attempt to
01:36:08FromDiscord<JSGRANT> @ElegantBeef Make a text-editor ... with a gui scenebuillder for fidget in fidget lol
01:36:19FromDiscord<JSGRANT> fidgma
01:36:31FromDiscord<iWonderAboutTuatara> so I've built it and libraylib.so to the same folder as the file
01:36:52FromDiscord<iWonderAboutTuatara> but the compile still fails with the same error
01:36:55FromDiscord<iWonderAboutTuatara> any idea why/
01:37:21FromDiscord<ElegantBeef> I mean the text editor i want to make is more akin to like a Vim + tmux, but a gui rendered editor, with easy splits/movement between windows
01:37:32FromDiscord<ElegantBeef> so it's next to the binary?
01:38:09FromDiscord<iWonderAboutTuatara> yeah
01:38:29FromDiscord<JSGRANT> @ElegantBeef So a non-gross https://onivim.io/ ? lol
01:38:34FromDiscord<ElegantBeef> Well i'm uncertain why it's not working
01:39:02FromDiscord<ElegantBeef> Sorta
01:39:13FromDiscord<JSGRANT> I'd want something closer to https://github.com/rxi/lite tbh
01:39:18FromDiscord<iWonderAboutTuatara> https://media.discordapp.net/attachments/371759389889003532/782420388105814056/unknown.png
01:39:37FromDiscord<iWonderAboutTuatara> `could not load: libraylib.so↵(compile with -d:nimDebugDlOpen for more information)↵Error: execution of an external program failed: '/mnt/d/Scripts/Misc/Nim/Nim/nim-chess/chess '`
01:40:20FromDiscord<ElegantBeef> Yea i mean it'd be similar to vscode or sublime, just with more a tiling window manager feel
01:40:56FromDiscord<ElegantBeef> I figure i could have "widgets" which are just nimscript files, but considering i dont even have way to render text little far
01:41:30*pietroppeter quit (Quit: Connection closed for inactivity)
01:43:05FromDiscord<iWonderAboutTuatara> any idea what I should do to try to fix it?
01:43:21FromDiscord<iWonderAboutTuatara> I don't think I've explicitly told the compiler to load libraylib.so
01:43:32FromGitter<matrixbot> `Benjamin` I'm planning to use fidget to make a simple markdown editor with live preview, but I'm still slowly checking fidget out to see if it's at all viable.
01:43:58FromDiscord<Rebel> I mean you can check if that file even exists first....
01:44:01FromDiscord<Rebel> `find / -name libraylib.so`
01:46:22FromDiscord<iWonderAboutTuatara> it's in the same directory
01:46:33FromDiscord<iWonderAboutTuatara> it's right next to the .nim file actually
01:50:47*a_chou quit (Remote host closed the connection)
02:01:03FromDiscord<Rebel> Ok I may or may not be blind lol
02:01:17FromDiscord<iWonderAboutTuatara> lol
02:02:27FromDiscord<Rebel> And you did google the error right?
02:02:31FromDiscord<Rebel> You did try this right?
02:02:32FromDiscord<Rebel> https://github.com/raysan5/raylib/issues/706
02:02:32disbot➥ 5[build] Cannot find libraylib.so.2
02:02:57FromDiscord<iWonderAboutTuatara> I don't think this quite applies here because I don't have .2 or .301 there
02:03:05*hsh quit (Quit: Connection closed for inactivity)
02:03:22FromDiscord<Rebel> If you move the so file to `/usr/local/lib` does it work?
02:03:42FromDiscord<iWonderAboutTuatara> I odn't tihnk I've tried that
02:03:54FromDiscord<iWonderAboutTuatara> i will try
02:03:56FromDiscord<iWonderAboutTuatara> lets see
02:04:55wimlHey all, the compiler gives a handful of [ObservableStores] warnings on my code (lots of async procs). Is there a good writeup or resource somewhere for what problems this can cause and the best ways to deal with them?
02:05:40FromDiscord<iWonderAboutTuatara> I stilll get the error could not load libraylib.so
02:06:22FromDiscord<Rebel> Did you compile with the extra flag for more information? As well as maybe `--verbosity:3`?
02:07:00FromDiscord<iWonderAboutTuatara> I will try that now
02:07:05FromDiscord<iWonderAboutTuatara> I've never heard of the extra flag
02:07:25FromDiscord<Rebel> `(compile with -d:nimDebugDlOpen for more information)`
02:07:25FromDiscord<iWonderAboutTuatara> could not load: libraylib.so↵(compile with -d:nimDebugDlOpen for more information)↵Error: execution of an external program failed: '/mnt/d/Scripts/Misc/Nim/Nim/nim-chess/chess '↵/home/runner/work/nightlies/nightlies/nim-1.4.0/compiler/extccomp.nim(398, 15) compiler msg initiated here [MsgOrigin]
02:08:07FromDiscord<iWonderAboutTuatara> it does't give me any more information
02:08:14FromDiscord<Rebel> oh maybe try moving it here lol `/usr/lib/local`
02:08:17FromDiscord<iWonderAboutTuatara> sent a code paste, see https://play.nim-lang.org/#ix=2FS4
02:11:52FromDiscord<iWonderAboutTuatara> really weird
02:13:42FromDiscord<iWonderAboutTuatara> any ideas?
02:13:52FromDiscord<iWonderAboutTuatara> oh try moving the script to usrliblocal?
02:16:54FromDiscord<iWonderAboutTuatara> that didn't work
02:17:08FromDiscord<iWonderAboutTuatara> after compiling with sudo I get the same error
02:19:12FromDiscord<Rebel> Idk just keep googling I doubt you are the only person to ever come across this error could also check github issues and see if someone else had the same issue.
02:20:41FromDiscord<notchris> @iWonderAboutTuatara so libraylib.so is in usr/local/lib ?
02:21:02*apahl quit (Ping timeout: 264 seconds)
02:21:03FromDiscord<notchris> or w/e on linux
02:22:40*apahl joined #nim
02:24:34FromDiscord<iWonderAboutTuatara> yeah
02:24:44FromDiscord<iWonderAboutTuatara> usr/local/lib
02:25:14FromDiscord<notchris> and its called libraylib.so
02:25:15FromDiscord<notchris> ?
02:25:53FromDiscord<iWonderAboutTuatara> yes
02:26:10FromDiscord<iWonderAboutTuatara> in ls it showsup as [email protected] but the file itse'f is called libraylib.so
02:26:40FromDiscord<ElegantBeef> What bindings are you using?
02:26:56FromDiscord<iWonderAboutTuatara> !repo raylib-forever
02:26:57disbot12https://github.com/Ryan1729/nim-raylib-forever-raylib-audio-bug -- 9nim-raylib-forever-raylib-audio-bug: 11 15 0⭐ 0🍴
02:27:03FromDiscord<iWonderAboutTuatara> nevermind
02:27:12FromDiscord<iWonderAboutTuatara> Raylib Forever by Guevara chan
02:27:18FromDiscord<iWonderAboutTuatara> https://github.com/Guevara-chan/Raylib-Forever
02:27:43FromDiscord<notchris> im using those on osx, no issue
02:28:09FromDiscord<iWonderAboutTuatara> it's completely possible that I'm doing something wrong
02:28:09FromDiscord<notchris> @iWonderAboutTuatara whats the result of `test -f "user/local/lib/libraylib.so"`
02:28:31FromDiscord<iWonderAboutTuatara> nothign
02:28:42FromDiscord<iWonderAboutTuatara> just makes a new line in terminal
02:29:45FromDiscord<notchris> oops
02:29:48FromDiscord<notchris> `test -f user/local/lib/libraylib.so && echo "exists."`
02:30:12FromDiscord<iWonderAboutTuatara> still an empty line
02:30:13FromDiscord<iWonderAboutTuatara> weird
02:30:38FromDiscord<iWonderAboutTuatara> ah no it exists
02:30:50FromDiscord<iWonderAboutTuatara> I had to adapt the syntax a little but it echos exists
02:30:56FromDiscord<iWonderAboutTuatara> test -f /usr/local/lib/libraylib.so && echo "exists"
02:31:02FromDiscord<iWonderAboutTuatara> (edit) "test" => "`test" | ""exists"" => ""exists"`"
02:32:19FromDiscord<notchris> @iWonderAboutTuatara sorry i goofed
02:32:22FromDiscord<notchris> thats not right
02:32:35FromDiscord<notchris> you want `test -f user/local/lib/libraylib.so`
02:32:43FromDiscord<iWonderAboutTuatara> user?
02:32:45FromDiscord<notchris> then do
02:32:48FromDiscord<iWonderAboutTuatara> on linux it's usr I think
02:32:50FromDiscord<notchris> right
02:32:57FromDiscord<notchris> then `eho $?`
02:32:59FromDiscord<notchris> echo
02:32:59FromDiscord<iWonderAboutTuatara> but that did echo "exists"
02:33:20FromDiscord<iWonderAboutTuatara> says that it expected the name of a variable
02:33:32FromDiscord<notchris> ok from the start, im sorry that was messy
02:33:47FromDiscord<iWonderAboutTuatara> no issue lol
02:33:52FromDiscord<notchris> `test -f usr/local/lib/libraylib.so`
02:33:57FromDiscord<notchris> then
02:34:02FromDiscord<notchris> `echo $?`
02:34:08FromDiscord<notchris> it should be 0 for not found, 1 for found
02:34:16FromDiscord<notchris> as the result
02:34:51FromDiscord<notchris> https://media.discordapp.net/attachments/371759389889003532/782434367006834688/Screen_Shot_2020-11-28_at_9.34.41_PM.png
02:34:55FromDiscord<iWonderAboutTuatara> 0
02:35:04FromDiscord<notchris> right, so it cant find the file
02:35:07FromDiscord<iWonderAboutTuatara> weird
02:35:21FromDiscord<notchris> you said the file was a dynamic link righ
02:35:28FromDiscord<notchris> can you find the source
02:35:34FromDiscord<iWonderAboutTuatara> possibly?
02:35:41FromDiscord<iWonderAboutTuatara> I'm not really a unix person so idk how all this wokrs
02:35:43FromDiscord<notchris> right click on your current so
02:35:50FromDiscord<notchris> see if it says like show original or something
02:35:59FromDiscord<iWonderAboutTuatara> 8 https://media.discordapp.net/attachments/371759389889003532/782434655076483082/unknown.png
02:36:10FromDiscord<notchris> ok thats ur prob
02:36:14FromDiscord<notchris> copy the one that says
02:36:16FromDiscord<iWonderAboutTuatara> I'm using WSL meaning I have no gui
02:36:19FromDiscord<notchris> .3.0.0
02:36:21FromDiscord<notchris> or w/e
02:36:27FromDiscord<notchris> and rename it so libraylib.so
02:36:33FromDiscord<iWonderAboutTuatara> .3.0.0 or .301?
02:37:10FromDiscord<iWonderAboutTuatara> weirdly, it says they're the same file
02:37:11FromDiscord<notchris> copy libraylib.so.3.0.0
02:37:26FromDiscord<iWonderAboutTuatara> for both of them
02:37:51FromDiscord<notchris> https://media.discordapp.net/attachments/371759389889003532/782435122631671828/Screen_Shot_2020-11-28_at_9.34.41_PM.png
02:37:54FromDiscord<notchris> oops
02:38:02FromDiscord<notchris> https://media.discordapp.net/attachments/371759389889003532/782435172011212820/Screen_Shot_2020-11-28_at_9.37.42_PM.png
02:38:07FromDiscord<notchris> the white one, copy it
02:38:12FromDiscord<notchris> rename is libraylib.so
02:38:20FromDiscord<notchris> (edit) "is" => "it"
02:38:20FromDiscord<iWonderAboutTuatara> right, it tells me they're the same file
02:38:37FromDiscord<iWonderAboutTuatara> https://media.discordapp.net/attachments/371759389889003532/782435318019653682/unknown.png
02:38:40FromDiscord<notchris> then rename the one with the @ to something else for a second
02:38:48FromDiscord<notchris> then try to copy the other one
02:38:50FromDiscord<notchris> and rename it
02:39:03FromDiscord<notchris> or
02:39:11FromDiscord<notchris> change the line in your raylib.nim
02:39:18FromDiscord<notchris> to point to libraylib.so.3.0.0
02:39:25FromDiscord<iWonderAboutTuatara> oh
02:39:41FromDiscord<iWonderAboutTuatara> I just moved libraylib.so to libraylib2.so
02:39:48FromDiscord<notchris> k
02:39:52FromDiscord<iWonderAboutTuatara> and copied 3.0.0 to .so
02:39:55FromDiscord<notchris> nicee
02:40:07FromDiscord<notchris> now make sure u remove ur nim apps binary and then re-run
02:40:37FromDiscord<iWonderAboutTuatara> I still get the same error
02:41:17FromDiscord<notchris> take a pic of the dir files
02:41:27FromDiscord<notchris> now that youve renamed
02:41:31FromDiscord<iWonderAboutTuatara> https://media.discordapp.net/attachments/371759389889003532/782436040933376070/unknown.png
02:42:00FromDiscord<notchris> why is is u/l/lib
02:42:03FromDiscord<notchris> does it just truncate the names
02:42:11FromDiscord<iWonderAboutTuatara> in the display yeah
02:42:16FromDiscord<notchris> gotcha
02:43:40FromDiscord<notchris> hmm
02:43:44FromDiscord<notchris> wait are those all in a cmake dir
02:43:51FromDiscord<notchris> not in usr/local/lib/cmake
02:44:06FromDiscord<notchris> or is that in the same dir
02:44:17FromDiscord<notchris> yeah nm
02:44:21FromDiscord<iWonderAboutTuatara> no it's just in the same dir yeah
02:44:31FromDiscord<iWonderAboutTuatara> it shares a dir with /cmake
02:45:13FromDiscord<notchris> try adding
02:45:20FromDiscord<notchris> `-d:nimDebugDlOpen` to your build command
02:45:41FromDiscord<notchris> maybe you can find out where its looking for the file
02:49:25FromDiscord<notchris> @Trustable
02:49:25FromDiscord<iWonderAboutTuatara> libraylib.so: cannot open shared object file: No such file or directory↵could not load: libraylib.so↵Error: execution of an external program failed: '/mnt/d/Scripts/Misc/Nim/Nim/nim-chess/chess '
02:49:28FromDiscord<notchris> oops
02:49:30FromDiscord<iWonderAboutTuatara> lmaooo
02:49:36FromDiscord<notchris> @iWonderAboutTuatara Maybe try this
02:49:39FromDiscord<notchris> in raylib.nim
02:49:45FromDiscord<notchris> https://media.discordapp.net/attachments/371759389889003532/782438117457133568/Screen_Shot_2020-11-28_at_9.49.18_PM.png
02:49:54FromDiscord<notchris> see how i added the path to the pragma
02:50:03FromDiscord<notchris> idk if thats standard, but it didn't break my proj
02:50:33FromDiscord<iWonderAboutTuatara> still failed
02:50:38FromDiscord<notchris> did you remove the binary
02:50:39FromDiscord<iWonderAboutTuatara> could not load: usr/local/lib/libraylib.so↵Error: execution of an external program failed: '/mnt/d/Scripts/Misc/Nim/Nim/nim-chess/chess '
02:50:42FromDiscord<iWonderAboutTuatara> but it updated
02:50:45FromDiscord<notchris> oh ok
02:50:46FromDiscord<notchris> hm
02:50:47FromDiscord<iWonderAboutTuatara> do you need to rm the bianary?
02:50:48FromDiscord<iWonderAboutTuatara> wil try that
02:50:58FromDiscord<iWonderAboutTuatara> could not load: usr/local/lib/libraylib.so↵Error: execution of an external program failed: '/mnt/d/Scripts/Misc/Nim/Nim/nim-chess/chess '
02:51:41FromDiscord<iWonderAboutTuatara> oh wait no that wa sjust be being dumb
02:51:48FromDiscord<iWonderAboutTuatara> it worked now
02:51:55FromDiscord<notchris> Wooooo
02:51:57FromDiscord<iWonderAboutTuatara> but it can't find raygui.so
02:52:00FromDiscord<notchris> correct
02:52:15FromDiscord<iWonderAboutTuatara> ok so that's intentional?
02:52:21FromDiscord<iWonderAboutTuatara> how do I get raygui.so?
02:52:22FromDiscord<notchris> https://github.com/raysan5/raygui
02:52:24FromDiscord<notchris> you have to build it
02:52:28FromDiscord<notchris> with like cmake
02:53:01FromDiscord<notchris> it was less easy for me than raylib on osx
02:53:06FromDiscord<notchris> hopefuly it wont be hard for you
02:54:23FromDiscord<iWonderAboutTuatara> oh and do the same thing with this
02:54:23FromDiscord<iWonderAboutTuatara> got it
02:54:25FromDiscord<iWonderAboutTuatara> thanks!
02:54:44FromDiscord<notchris> i think you want to build in `https://github.com/raysan5/raygui/tree/master/projects/CMake`
02:54:59FromDiscord<notchris> np good luck!
02:55:59FromDiscord<iWonderAboutTuatara> so when I distribute this, what do I do with libraylib.so?
02:56:05FromDiscord<iWonderAboutTuatara> also, how do I compile this for other platforms?
02:56:23FromDiscord<iWonderAboutTuatara> will it be built into the binaries?
02:56:56FromDiscord<iWonderAboutTuatara> by the way, I instead of using from /u/l/l I changed it to ./ so I just put libraylib.so next to the raylib.nim file
02:57:05FromDiscord<iWonderAboutTuatara> to make it easier to manage
02:57:09FromDiscord<notchris> nice
02:57:15FromDiscord<notchris> i cannot answer those questions
02:57:19FromDiscord<notchris> not experienced enough
02:57:32FromDiscord<notchris> but it seems like you should be able to compile
02:57:49FromDiscord<iWonderAboutTuatara> and the binary should hopefully work on other machines without too much fiddling?
02:58:08FromDiscord<notchris> My guess is yes, but i don't know exactly how it works
02:59:28FromDiscord<iWonderAboutTuatara> Thanksf or the help!
02:59:34FromDiscord<iWonderAboutTuatara> I guess I'll cross that bridge when I get to it
02:59:36FromDiscord<iWonderAboutTuatara> thank you!
02:59:46FromDiscord<notchris> haha np man, good luck and have fun
03:02:56FromDiscord<iWonderAboutTuatara> weirdly, removing the gui code then running doesn't spawn a window
03:03:15FromDiscord<notchris> you tested the basic example?
03:03:42FromDiscord<notchris> hmm
03:03:59FromDiscord<notchris> try this one https://github.com/Guevara-chan/Raylib-Forever/blob/master/examples/core/camera_2d.nim
03:10:24FromDiscord<iWonderAboutTuatara> still no
03:10:28FromDiscord<iWonderAboutTuatara> weird
03:11:38FromDiscord<iWonderAboutTuatara> seems to be a wsl issue
03:14:04FromDiscord<iWonderAboutTuatara> it's looking like I should just use native windows instead of wsl
03:18:40FromDiscord<ElegantBeef> ~~Or native linux~~
03:19:12FromDiscord<ElegantBeef> Are you attempting to run the linux build throug the cli?
03:22:35*wiml quit (Quit: Leaving)
03:27:00ForumUpdaterBotNew thread by Niminem: I make my first $ with Nim in two days, see https://forum.nim-lang.org/t/7172
03:28:33FromDiscord<Revenant> hiya, i'm trying do give `{.byaddr.}` a nicer syntax. this is my unsuccessful attempt so far:
03:28:55FromDiscord<Revenant> sent a code paste, see https://play.nim-lang.org/#ix=2FSg
03:29:16FromDiscord<Revenant> but i'm just getting this error
03:29:30FromDiscord<Revenant> any tips?
03:29:30FromDiscord<Revenant> sent a code paste, see https://play.nim-lang.org/#ix=2FSh
03:29:42FromDiscord<Revenant> (edit) "do" => "to"
03:30:47*Evolver joined #nim
03:31:54FromDiscord<Revenant> (edit) sent a code paste, see https://play.nim-lang.org/#ix=2FSi
03:49:08FromDiscord<Revenant> okay, i got it to work... kinda... not sure what the implications of setting `typ` always to `nil` are though
03:49:19FromDiscord<Revenant> sent a code paste, see https://play.nim-lang.org/#ix=2FSl
03:54:49FromDiscord<iWonderAboutTuatara> yeah I realized that you can't really mae the linux cli pop a window
03:54:53FromDiscord<iWonderAboutTuatara> so I have to use windows
04:01:32FromDiscord<ElegantBeef> I believe WSL2 can open windows
04:01:48*bung joined #nim
04:05:18*mbomba quit (Quit: WeeChat 3.0)
04:06:02*supakeen quit (Quit: WeeChat 2.9)
04:06:36*supakeen joined #nim
04:13:03FromGitter<halloleo> Hey , Nim people seem to be on Discord more than on Gitter, right? Which Discord and how best to join? Many thanks!
04:15:41FromDiscord<ElegantBeef> You can use IRC, Matrix, or Discord 😄
04:16:49FromDiscord<ElegantBeef> http://discord.gg/nim is the url for discord
04:26:29*abm quit (Quit: Leaving)
04:32:05*nixfreak quit (Ping timeout: 240 seconds)
04:51:11*thomasross quit (Ping timeout: 256 seconds)
04:59:47*superbia1 joined #nim
05:01:56*superbia quit (Ping timeout: 240 seconds)
05:04:51*mbomba joined #nim
05:17:20*mbomba quit (Quit: WeeChat 3.0)
05:34:33*njoseph quit (Quit: http://quassel-irc.org - Chat comfortably. Anywhere.)
05:34:40*njoseph joined #nim
05:45:47FromDiscord<InventorMatt> is there a way or at least any easy way to use varargs for indexing nimnodes?
05:46:03*waleee-cl quit (Quit: Connection closed for inactivity)
05:47:15leorize[m]1wdym?
05:50:09*bung quit (Ping timeout: 265 seconds)
05:56:24*bung joined #nim
06:08:23FromDiscord<InventorMatt> like i have a seq of indices for a nimnode and want to access that index just using a seq
06:09:05FromDiscord<InventorMatt> so instead of foo[0][1][0] i can do foo[@[0,1,0]]
06:14:16FromDiscord<ElegantBeef> @InventorMatt how about this? https://play.nim-lang.org/#ix=2FSE
06:15:17FromDiscord<ElegantBeef> Varargs also works like an open array, so should be fine?
06:16:42FromDiscord<ElegantBeef> Alternatively you can replace it with an `openArray[int]` to not interfere with the normal `[]`
06:29:41FromDiscord<InventorMatt> So far I am not sure if that will work. I'm trying `[]=` with it but changing it to var with it's not changing the node I want
06:41:26FromDiscord<ElegantBeef> Weirdly it seems to be copying
06:47:08FromDiscord<InventorMatt> I probably messed up changing it to a var incorrectly
06:48:42FromDiscord<ElegantBeef> I mean NimNode is a ref object so it shouldnt require `var` afaik
06:50:19FromDiscord<InventorMatt> I probably did it wrong then
06:50:31FromDiscord<ElegantBeef> I mean i'm having issues aswell so... 😄
06:52:17FromDiscord<ElegantBeef> guess might have to use templates or macros
06:54:53FromDiscord<InventorMatt> I was thinking a macro would work but I wanted to test my options first
06:55:07FromDiscord<ElegantBeef> Yea i thought the proc would work due to them being ref objects
07:04:04FromDiscord<ElegantBeef> @InventorMatt Well i just made the macro if you want it https://play.nim-lang.org/#ix=2FSL
07:06:03FromDiscord<InventorMatt> awesome, thanks.
07:07:04FromDiscord<ElegantBeef> Hmm technically that could be a generic indention method
07:07:23FromDiscord<ElegantBeef> Aslong as the type implements `[]`
07:10:03*apahl quit (Ping timeout: 272 seconds)
07:10:42*apahl joined #nim
07:12:19*narimiran joined #nim
07:17:50FromDiscord<InventorMatt> is there a way to convert a symbol input to get it to work? like the seq is generated from a different proc first
07:20:46FromDiscord<ElegantBeef> Does it matter?
07:24:03FromDiscord<InventorMatt> I think so. https://play.nim-lang.org/#ix=2FSU here is what I am trying to do. I want to basically unwrap a loop and use i in the body to convert to the number
07:24:33*mbomba joined #nim
07:25:26FromDiscord<ElegantBeef> There has to be a better way 😄
07:25:52FromDiscord<ElegantBeef> I mean than my macro
07:25:59*habamax joined #nim
07:27:12FromDiscord<InventorMatt> yeah, I mainly need this because I need a for loop where the index is a static compiletime value
07:45:58*audiofile joined #nim
07:47:13audiofilewhy nim have max limit on integer size unlike python
07:47:55FromDiscord<ElegantBeef> Cause nim is statically typed and uses fixed size ints
07:48:32mipriit's not a python clone. nimble search bignum and you'll find a few libraries that'll give you those.
07:50:05FromDiscord<ElegantBeef> Dynamically sized ints are a bit hard to deal with you want stack allocated types 😄
07:52:10audiofileoh I see, didn't know it was based on beign statically typed! thanks for explain
07:52:26audiofilethe uniform function call syntax is cool!
07:52:28FromDiscord<ElegantBeef> Well you can do dynamically sized ints but it gets weird to do arrays
07:53:20FromDiscord<ElegantBeef> Afaik it's a performance/usabillity thing
07:54:10audiofilelike dynamically resizing memory if int is too big?
07:54:28miprithe type system is not really the issue. it you plotted languages by type system and whether they have bignums as a default type you'd see a relationship, but one factor doesn't cause the other, they're just both caused by wanting efficient code by default
07:55:27mipricomputers have registers that hold numbers represented by a fixed size of bits, and efficient operations on them. bignums require a lot of software on top of that.
07:55:47FromDiscord<ElegantBeef> Yea i was more saying that due to the type system and with stack allocated objects you dont really want to default to bignums assuming you change the size of them on the fly
07:55:52mipribut again you have them if you want.
07:56:40FromDiscord<ElegantBeef> I guess i'm bringing in the type system just cause i'm daft 😄
07:57:34audiofilewhat is the differencee between 'ref object of' and 'object of' is it call by reference vs call by value?
07:57:52FromDiscord<ElegantBeef> one is a reference object, one isnt
07:58:17audiofilereference object meaning if I change a value, the referred object's value is also changed right?
07:58:23FromDiscord<ElegantBeef> Yea
07:58:26mipriit's reference semantics vs. value semantics, yes. basically what you're thinking of.
07:58:53audiofilethanks I needed those search keywords
07:59:27audiofilealso % is used for creating json object ???
07:59:36audiofileI find it a bit odd that there is an operator just for that
07:59:57miprihttps://nim-lang.org/docs/json.html#%25%2Cstring
08:00:11mipriit's not a built-in operator, the json library defines it
08:00:16audiofileoverloading?
08:00:27audiofileinteresting!
08:00:38audiofilefirst time encountering a library defining a symbol hmm
08:01:18mipristrformat gives you &"strings" by defining `&`. system has `$` for stringification
08:02:09audiofileoh didn't realize those were libraries mb
08:02:22audiofilewhat does % do then if json is not imported
08:02:34audiofilenot sure how it should be used otherwise, if it is at all being used
08:02:48mipriit doesn't do anything.
08:03:00miprihttps://play.nim-lang.org/#ix=2FT6 <- you should define operators more sparingly than this.
08:03:13mipribut obviously %%% isn't a prefix operator that exists in the language that that code is just overloading
08:04:05FromDiscord<ElegantBeef> Nim has userdefined operators
08:04:12miprihttps://nim-lang.org/docs/manual.html#lexical-analysis-operators
08:05:39*vicfred quit (Quit: Leaving)
08:06:34*vicfred joined #nim
08:06:46FromDiscord<iWonderAboutTuatara> I seem to be getting the same issues I was having on linux on windows
08:07:04FromDiscord<iWonderAboutTuatara> I ahve libraylib.dll located inside my folder
08:07:08FromDiscord<iWonderAboutTuatara> right next to the script
08:07:13FromDiscord<iWonderAboutTuatara> and it's telling me ti can't find it
08:07:39*vicfred quit (Max SendQ exceeded)
08:08:11*vicfred joined #nim
08:12:58*tane joined #nim