Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 707 708 [709] 710 711 ... 795

Author Topic: if self.isCoder(): post() #Programming Thread  (Read 817272 times)

bloop_bleep

  • Bay Watcher
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #10620 on: September 07, 2017, 12:16:59 am »

Am developing a sort of politics simulator for lulz. Basically I represent any relationship between two political entities by how much each one fears and hates the other -- actions taken by various entities affects their relations with others. Simplifying obviously complex political relations to two values seems like a bit of a stretch, but it might work, in a kind-of-sort-of way.

I'm almost done coding the basic framework. After that I get to work on the AI.  :D
Logged
Quote from: KittyTac
The closest thing Bay12 has to a flamewar is an argument over philosophy that slowly transitioned to an argument about quantum mechanics.
Quote from: thefriendlyhacker
The trick is to only make predictions semi-seriously.  That way, I don't have a 98% failure rate. I have a 98% sarcasm rate.

Max™

  • Bay Watcher
  • [CULL:SQUARE]
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #10621 on: September 07, 2017, 01:13:42 am »

The UI on the other hand is a kinda-sorta working train wreck of javascript and HTML. Anyone who thinks JavaScript and HTML are the future of UI design is an idiot. I want QT or some other "real" UI library with a visual designer and decent layout tools. Oh well, HTML will be OK for the prototype.
I've learned to love css since I realized I don't need to stress about shit like mozilla finding new ways to force their crap taste in UI or breaking the various addons usually responsible for restoring the fully modifiable firefox I used to know and love.

I figured it would be too easy to expect vivaldi (and by extension chrome) to abide by the mozilla selector naming schemes, but despite having only a passing interest in figuring out the .css controlling vivaldi's UI I was almost able to successfully force what I consider the proper layout (tabs+urlbar+buttons on a single row up against the top edge of the screen) so that's interesting.

Trying to make those changes with a text editor rather than with the inspector via html sounds awful. I'll stick with the interactive/helpfully-predictive css style editor, thanks.
Logged

milo christiansen

  • Bay Watcher
  • Something generic here
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #10622 on: September 07, 2017, 08:16:42 pm »

It is relly weird to be listening to music, and glance up at the top of the screen to see what is up next... And no winamp.

On the other hand, if I still want that feature in a few weeks I can just add it myself.

Right now, I am trying to dig my way out of the roots of Bug and Missing Features Mt. without triggering a cave-in.

The UI finally tracks what is playing, but I just realized the status from the player is using the wrong names for things in the JSON.

Other issues include:
* The UI does not show track progress yet.
* The UI needs buttons for play, pause, stop, next, prev, etc.
* Lots of places where I call LibVLC functions I simply assume there was no error (bad Milo, bad. Fix it).
* The DB is full of really low quality data. Everything that was an mp3 and had good metadata is OK, but that only covers about 3/4 of the tracks.
* There needs to be more sorting options. It is anoying to click on a heading, only to remember I didn't implement sorting for that column. In the same vein, the default sorting needs to be changed from name.

I have lots to do :) At least I won't be bored...
« Last Edit: September 07, 2017, 09:03:20 pm by milo christiansen »
Logged
Rubble 8 - The most powerful modding suite in existence!
After all, coke is for furnaces, not for snorting.
You're not true dwarven royalty unless you own the complete 'Signature Collection' baby-bone bedroom set from NOKEAS

Levi

  • Bay Watcher
  • Is a fish.
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #10623 on: September 15, 2017, 01:47:06 pm »

You guys think you are so smart.

Could you code a game of Tetris?

Could you simulate a computer to run your game of Tetris!?

Could you simulate your computer on top of Conways Game of Life so that you can run tetris!?!?!

Me neither, but some people did.   :o  :P
Logged
Avid Gamer | Goldfish Enthusiast | Canadian | Professional Layabout

Telgin

  • Bay Watcher
  • Professional Programmer
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #10624 on: September 15, 2017, 02:07:36 pm »

That's thoroughly impressive.  I never would have even thought to try to make logic gates like that or even consider that The Game of Life might be Turing complete in such a way, but now that I see it, it makes sense that you could.
Logged
Through pain, I find wisdom.

Reelya

  • Bay Watcher
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #10625 on: September 15, 2017, 02:58:54 pm »

I ... don't think that's actually a working thing, it's just a pie in the sky concept. I know that people have built very simple logic gates in Conway's Life, but working games. Has anyone built even the simplest Hello World in Conway's Life? If not, then saying "make Tetris" is just pie in the sky wankery right now.

The thing to do would be to port chip-design software over to the known ways to configure a logic gate in Life. Then build a CPU inside the simulation, then you code on top of that. Hard-wiring circuitry to just be Tetris ... not practical.
« Last Edit: September 15, 2017, 03:02:05 pm by Reelya »
Logged

TheDarkStar

  • Bay Watcher
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #10626 on: September 15, 2017, 03:01:40 pm »

I ... don't think that's actually a working thing, it's just a pie in the sky concept. I know that people have built very simple logic gates in Conway's Life, but working games. Has anyone built even the simplest Hello World in Conway's Life? If not, then saying "make Tetris" is just pie in the sky wankery right now.

No, it's working (and they have it linked later on in the discussion).
Logged
Don't die; it's bad for your health!

it happened it happened it happen im so hyped to actually get attacked now

Reelya

  • Bay Watcher
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #10627 on: September 15, 2017, 03:05:17 pm »

Edit: ignore me, I hadn't read the whole thing.
« Last Edit: September 15, 2017, 03:16:20 pm by Reelya »
Logged

Levi

  • Bay Watcher
  • Is a fish.
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #10628 on: September 15, 2017, 03:16:59 pm »

The way I *think* I understand it each of those pixels is actually a a 2048 × 2048 cell of conways game of life, that makes it easier to encode simple rules.
Logged
Avid Gamer | Goldfish Enthusiast | Canadian | Professional Layabout

TheDarkStar

  • Bay Watcher
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #10629 on: September 15, 2017, 03:41:12 pm »

Yeah, they started with Conway's life, then made cells from that to emulate WireWorld (a similar cellular automata), then built basic logic gates, tiled those to create assorted parts of the computer, then created a programming language for the (very large) computer.  Then it was trivial to make tetris.
Logged
Don't die; it's bad for your health!

it happened it happened it happen im so hyped to actually get attacked now

Reelya

  • Bay Watcher
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #10630 on: September 15, 2017, 04:07:06 pm »

Well that's interesting, but it would be more interesting to look at a simple "fraction" type and see what the advantages are of the continued fraction. e.g. a continued fraction has the benefit that it can represent 1/3 exactly. However I can just make a "rational" data type and give it a numerator and denominator, it can also exactly represent 1/3, and perhaps the wiring to do arithmetic with those would just be  a lot simpler.

Or write a data type that works directly with maths expressions. It would have all the abilities of the fraction/continued-fraction type, plus you'd be able to code in ideas such as physics units and the like, so things like units are preserved by your calculations, allowing a further level of error checking.

Actually that's got me wondering on whether I can encode physics units as templates, and enforce physics unit checking at compile time in C++. Zero-overhead error checking that your equations make physical sense! I haven't done a new project in a while, I might just make something like that, could be fun and useful in future projects.
« Last Edit: September 15, 2017, 04:18:41 pm by Reelya »
Logged

Max™

  • Bay Watcher
  • [CULL:SQUARE]
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #10631 on: September 15, 2017, 05:23:58 pm »

Pretty sure that real arithmetic stuff is a route to inviting the gibbering eaters that hunger in the unspaces between universes, but I can't be sure they aren't here already because when I got done checking out that tetrislife thing I promptly thought "wonder if it could be minecarted" which is absurd because you'd end up generating a self sustaining fusion reaction as your processor imploded long before it would complete a tick.
Logged

EnigmaticHat

  • Bay Watcher
  • I vibrate, I die, I vibrate again
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #10632 on: September 15, 2017, 05:32:49 pm »

So is the practical purpose here greater precision?  As in, no need to round or use a float?
Logged
"T-take this non-euclidean geometry, h-humanity-baka. I m-made it, but not because I l-li-l-like you or anything! I just felt s-sorry for you, b-baka."
You misspelled seance.  Are possessing Draignean?  Are you actually a ghost in the shell? You have to tell us if you are, that's the rule

Uristides

  • Bay Watcher
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #10633 on: October 24, 2017, 10:03:03 am »

Programming in CUDA is like trying to fit a million clowns on 256 cars* but the cars are on fire and moving at different speeds and the clowns need to juggle a shared set of a billion bowling balls between them while on the move and still arrive alive at the same place and at the same time and organize the balls in a neat pyramid. Or something like that.

* But we live on the matrix and the cars are just a clever high-level abstraction for groups of 32 self-propelled seats and the clowns are actually agent Smith
Logged

da_nang

  • Bay Watcher
  • Argonian Overlord
    • View Profile
Re: if self.isCoder(): post() #Programming Thread
« Reply #10634 on: October 24, 2017, 01:20:32 pm »

Have programmed in OpenCL. Can confirm.
Logged
"Deliver yesterday, code today, think tomorrow."
Ceterum censeo Unionem Europaeam esse delendam.
Future supplanter of humanity.
Pages: 1 ... 707 708 [709] 710 711 ... 795