Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Post
  • Reply
MononcQc
May 29, 2007

I've recently been working on a dispatching application in Erlang that aims to work for high-performance, low-latency resource dispatching & pooling requirements. The lib is at https://github.com/ferd/dispcount, and this morning it made it in production for some of our Cassandra connection pools:



The most important point: we no longer see nearly as many timeouts, which is vital for our real time bidding business and being able to know when we will or won't be able to bid. Plus, in general we managed to get more performance out of the same database. The 'not_found' values are only misses, and getting many of them is as good as getting 'hits' performance-wise. Not shown on the graph: doubling the number of workers/connections giving even better results.

I'm pretty happy about it. A good way to begin the week.

Adbot
ADBOT LOVES YOU

Clavius
Oct 21, 2007

Howdy!
Playing with canvas again. :getin:



Hand coded everything just for fun. It's hardly an efficient way of doing 3d stuff but it's pretty cool. For example, the 3d rotation is calculated like this:

code:
	function translate3d(p) {
		var x2 = p.x*Math.sin(this.rotation.z)-p.y*Math.cos(this.rotation.z);
		var y2 = p.x*Math.cos(this.rotation.z)+p.y*Math.sin(this.rotation.z);
		var x3 = x2*Math.sin(this.rotation.y)-p.z*Math.cos(this.rotation.y);
		var z2 = x2*Math.cos(this.rotation.y)+p.z*Math.sin(this.rotation.y);
		var y3 = y2*Math.sin(this.rotation.x)-z2*Math.cos(this.rotation.x);
		var z3 = y2*Math.cos(this.rotation.x)+z2*Math.sin(this.rotation.x);
		var x = x3/(2+z3/2)*0.85;
		var y = y3/(2+z3/2)*0.85;
		return {x:x,y:y,z:z3};
	}
Where p is the x y and z co-ordinates of a point. The z3 is stored to re-arrange an array of faces based on z value for the drawing order.

The poly itself is stored as a series of 3d co-ordinates based on the golden ratio, it's loving hideous. Eg, one of the faces:

code:
		var phi = ((Math.sqrt(5)+1)*0.5);
		out.face(0,[
			{x:s+ox,y:s+oy,z:s+oz},
			{x:phi+ox,y:0+oy,z:(s/phi)+oz},
			{x:s+ox,y:-s+oy,z:s+oz},
			{x:0+ox,y:(-s/phi)+oy,z:phi+oz},
			{x:0+ox,y:(s/phi)+oy,z:phi+oz},
			{x:s+ox,y:s+oy,z:s+oz}
		]);
S is the size, ox, oy and oz are offsets, etc.
It's a pretty versatile little setup, i've set it up with cubes and stuff. It's hardly efficient though and starts choking at about 20 or so faces with a bunch of rotation.

Oh and it's got some half assed click-drag rotation support that doesn't work right. :effort:

Clavius fucked around with this message at 10:55 on Feb 23, 2012

Suspicious Dish
Sep 24, 2011

2020 is the year of linux on the desktop, bro
Fun Shoe
Yeah, hand-rolled canvas 3D is fun stuff. (try to spot some broken z-sorting there, and laugh at how terrible my shading algorithm is)

Clavius
Oct 21, 2007

Howdy!

Suspicious Dish posted:

Yeah, hand-rolled canvas 3D is fun stuff. (try to spot some broken z-sorting there, and laugh at how terrible my shading algorithm is)

Yeah that's much more efficient than mine. I kinda built mine so I could do stupid stuff with it. My shading algorithm uses the same cripplingly inefficient add-as-you-go z values to do its thing as my z-sorting. I can do this though.

tef
May 30, 2004

-> some l-system crap ->
I wrote some code to glue our processes at work together. It evolved enough to warrant splitting off and rewriting chunks. I got permission to MIT license it and stick it on github.

http://github.com/tef/hate-rpc

I'll hopefully carve out more time to work on it, but it is just a little beyond the prototype stage and the documentation makes it look like english is not my first language.

gold brick
Jun 19, 2001

no he isn't

wil posted:



Over the weekend, I wrote a bookmarklet that allows you to quickly change the dimensions of a webpage to test responsive design.

See more / install here http://codebomber.com/jquery/resizer/
Source here: https://github.com/egdelwonk/resizer
5 or 6 of us at work are using this now. Nice job.

Interrupt
Mar 30, 2010


Been working on a dungeon crawler engine inspired by blending roguelikes with Ultima Underworld, to the end of making an iOS / Android game. The world is tile based with per tile ceiling and floor heights, which has made implementing AABB collision super simple and should also allow me to piece together randomly generated floors. Basic combat and pathfinding is in, I'm now mulling over whether to implement an inventory system or do things Hack/Slash/Loot style and just let you swap out items.

Wedge of Lime
Sep 4, 2003

I lack indie hair superpowers.

tef posted:

I wrote some code to glue our processes at work together. It evolved enough to warrant splitting off and rewriting chunks. I got permission to MIT license it and stick it on github.

http://github.com/tef/hate-rpc

I'll hopefully carve out more time to work on it, but it is just a little beyond the prototype stage and the documentation makes it look like english is not my first language.

Looks interesting, I'll watch your progress.

I've just read through the README file, I can see why you might want to use a different serialisation format than JSON for this.

At work we use JSON extensively for our internal web api's and I'd be interested if you could expand a bit on the 'hosed up unicode' support in JSON as its not a problem I've hit, yet.

tef
May 30, 2004

-> some l-system crap ->
json doesn't handle outside the bmp well.

quote:

To escape an extended character that is not in the Basic Multilingual
Plane, the character is represented as a twelve-character sequence,
encoding the UTF-16 surrogate pair. So, for example, a string
containing only the G clef character (U+1D11E) may be represented as
"\uD834\uDD1E".

the rfc also says things like this

quote:

Encoding considerations: 8bit if UTF-8; binary if UTF-16 or UTF-32

JSON may be represented using UTF-8, UTF-16, or UTF-32. When JSON
is written in UTF-8, JSON is 8bit compatible. When JSON is
written in UTF-16 or UTF-32, the binary content-transfer-encoding
must be used.

wellwhoopdedooo
Nov 23, 2007

Pound Trooper!

Interrupt posted:



Been working on a dungeon crawler engine inspired by blending roguelikes with Ultima Underworld, to the end of making an iOS / Android game. The world is tile based with per tile ceiling and floor heights, which has made implementing AABB collision super simple and should also allow me to piece together randomly generated floors. Basic combat and pathfinding is in, I'm now mulling over whether to implement an inventory system or do things Hack/Slash/Loot style and just let you swap out items.

I see you've implemented the fabled Pork Sword.

AntiPseudonym
Apr 1, 2007
I EAT BABIES

:dukedog:

Interrupt posted:



Been working on a dungeon crawler engine inspired by blending roguelikes with Ultima Underworld, to the end of making an iOS / Android game. The world is tile based with per tile ceiling and floor heights, which has made implementing AABB collision super simple and should also allow me to piece together randomly generated floors. Basic combat and pathfinding is in, I'm now mulling over whether to implement an inventory system or do things Hack/Slash/Loot style and just let you swap out items.

This looks goddamned fantastic. Have you got a devlog up anywhere?

Dijkstracula
Mar 18, 2003

You can't spell 'vector field' without me, Professor!

Interrupt posted:



Been working on a dungeon crawler engine inspired by blending roguelikes with Ultima Underworld, to the end of making an iOS / Android game. The world is tile based with per tile ceiling and floor heights, which has made implementing AABB collision super simple and should also allow me to piece together randomly generated floors. Basic combat and pathfinding is in, I'm now mulling over whether to implement an inventory system or do things Hack/Slash/Loot style and just let you swap out items.
This looks spectacular; great job. Is this an offshoot of the raycaster engine you mention on your github?

lazypeterson
Mar 7, 2008


Simple little task organizer I made, mostly to test out my AJAX skills.

thedreamless
Apr 8, 2008


Why stay to only a picture? Here's the whole project (source code, working demos, examples and everything)

http://kinect.childnodes.com/

( Kinect + Javascript)

Luminous
May 19, 2004

Girls
Games
Gains

lazypeterson posted:



Simple little task organizer I made, mostly to test out my AJAX skills.

Switch out the multiple combo boxes for an actual calendar widget. Makes date selection a lot simpler. May not matter to you if you're just testing out ajax, though.

thepedestrian
Dec 13, 2004
hey lady, you call him dr. jones!

thedreamless posted:



Why stay to only a picture? Here's the whole project (source code, working demos, examples and everything)

http://kinect.childnodes.com/

( Kinect + Javascript)

This rules. As someone who was trying to learn horribly documented Python OpenNI bindings, I thank you.

mwarkentin
Oct 26, 2004
I made a stylish extension that show Trello card IDs on the main board: http://userstyles.org/styles/61623/trello-card-ids

Factor Mystic
Mar 20, 2006

Baby's First Post-Apocalyptic Fiction

mwarkentin posted:

I made a stylish extension that show Trello card IDs on the main board: http://userstyles.org/styles/61623/trello-card-ids



I saw this retweeted by @trello before I saw this post. Cool!

lazypeterson
Mar 7, 2008

Luminous posted:

Switch out the multiple combo boxes for an actual calendar widget. Makes date selection a lot simpler. May not matter to you if you're just testing out ajax, though.

No actually that's great advice--I'm trying to refine my design skills (or lack thereof) as well. Thanks!

Batou
Jul 16, 2011
Been working on two things.
One is a SRPG written in Love2D (a great Lua framework):



Another is a proof-of-concept 2/4chan clone....made in Google sites. Its weird, but it works o.k. If you have experience in those sites the functionality should make sense to you:



URL is https://sites.google.com/site/gchanplus/google-chan.

Batou fucked around with this message at 17:24 on Mar 1, 2012

Dave Thorpe Painting
Aug 9, 2004
Dictator of The World - 2033

Jewel posted:

I love you forever. This is super clean and super nice.

Edit: I wonder if in the future you could attempt to set up some form of system that plays separate piano together to achieve the sound of the chord currently on the screen. It'd only need as many sound files as there are notes, ie not many. Then again there's guitar too, plus coding it might be a bit difficult. But seriously, if you added that it'd be the actual best site on the internet in regard to these kinds of tools.

You are the man. You just saved my rear end in my songwriting class!

SavageMessiah
Jan 28, 2009

Emotionally drained and spookified

Toilet Rascal

Batou posted:

Been working on two things.
One is a SRPG written in Love2D (a great Lua framework):



Haha, programmerart.png
What a face!

Not that I've ever produced anything better, mind.

Batou
Jul 16, 2011

SavageMessiah posted:

Haha, programmerart.png
What a face!

Not that I've ever produced anything better, mind.

Hah, actually in this version the parts of the face are customizable just like armor...I have a real artist who will be doing the sprite-work for me. Final version won't be too wacky.

aBagorn
Aug 26, 2004
Simple GUI to mimic the old WNTIPCFG GUI for our company's end users when we (finally) make the migration over to Windows 7.



You want the code?
View: http://pastebin.com/v8FkvK6r
Logic: http://pastebin.com/Mi5PCnvk

raymond
Mar 20, 2004
I've been busy working on a Python syntax checker extension for the Komodo editor. It does PEP-8 and Pylint checking. I really liked this feature from other editors but they are just so ugly on Windows for some reason.

So now I have a pretty editor which highlights bad whitespace and unused imports. Hooray!

http://community.activestate.com/node/7989

Beef
Jul 26, 2004

Toekutr posted:



A screenshot of my first game ever! an in-progress roguelike written in Common Lisp

Are you using libtcod? ncurses?

mst4k
Apr 18, 2003

budlitemolaram

I've been working on a scifi/space roguelike off and on for a while now. I'm using Python+Libtcod and it's working out fairly well. It's still really alpha but I've been working on it quite a bit for the past two months or so.





Making a roguelike in your spare time is fun :) It also made me fall in love with Python.

taqueso
Mar 8, 2004


:911:
:wookie: :thermidor: :wookie:
:dehumanize:

:pirate::hf::tinfoil:

karma_coma posted:

I've been working on a scifi/space roguelike off and on for a while now. I'm using Python+Libtcod and it's working out fairly well. It's still really alpha but I've been working on it quite a bit for the past two months or so.





Making a roguelike in your spare time is fun :) It also made me fall in love with Python.

Does it take place in space, flying a spaceship? Because that would be awesome.

mst4k
Apr 18, 2003

budlitemolaram

taqueso posted:

Does it take place in space, flying a spaceship? Because that would be awesome.

Yes, it does. Influenced heavily by the already excellent roguelike Prospector.

I don't have much of the spaceship part done except for going to different planets/space stations and poo poo. No space combat yet and I'm honestly kind of dreading figuring out roguelike spaceship combat :/

o.m. 94
Nov 23, 2009

karma_coma posted:

Yes, it does. Influenced heavily by the already excellent roguelike Prospector.

I don't have much of the spaceship part done except for going to different planets/space stations and poo poo. No space combat yet and I'm honestly kind of dreading figuring out roguelike spaceship combat :/

I had a look at the Prospector source and oh my god

pre:
for a=0 to last_ae
        if areaeffect(a).typ=1 and areaeffect(a).dur>0 then
            areaeffect(a).dur=areaeffect(a).dur-1
            if areaeffect(a).typ=1 and areaeffect(a).dur=0 then dprint "the ground rumbles",14'eartquake
            if areaeffect(a).typ=1 and areaeffect(a).dur=0 and findbest(16,-1)>0 and rnd_range(1,6)+rnd_range(1,6)+player.science(1)>9 then dprint "Originating at "&areaeffect(a).c.x &":"&areaeffect(a).c.y,14
            for x=areaeffect(a).c.x-areaeffect(a).rad to areaeffect(a).c.x+areaeffect(a).rad
                for y=areaeffect(a).c.y-areaeffect(a).rad to areaeffect(a).c.y+areaeffect(a).rad
                    if x>=0 and y>=0 and x<=60 and y<=20 then
                    p1.x=x
                    p1.y=y
                        if distance(p1,areaeffect(a).c)<areaeffect(a).rad then
                            if show_eq=1 then
                                locate p1.y+1,p1.x+1
                                print "."
                            endif
                            'Inside radius, inside map
                            if areaeffect(a).typ=1 then 'eartquake
                                if areaeffect(a).dur>0 then
                                    if x=awayteam.c.x and y=awayteam.c.y and rnd_range(1,6)+rnd_range(1,6)+player.science(1)>9 then
                                        dprint "A tremor",14
                                        if findbest(16,-1)>0 and rnd_range(1,6)+rnd_range(1,6)+player.science(1)>9 then dprint "Originating at "&areaeffect(a).c.x &":"&areaeffect(a).c.y,14
                                    endif
                                else
                                    areaeffect(a).dam=areaeffect(a).dam-distance(p1,areaeffect(a).c)
                                    if areaeffect(a).dam=0 then areaeffect(a).dam=0
                                    tmap(x,y)=earthquake(tmap(x,y),areaeffect(a).dam-distance(p1,areaeffect(a).c))                                                
                                    if planetmap(x,y,slot)>0 then planetmap(x,y,slot)=tmap(x,y).no
                                    if planetmap(x,y,slot)<0 then planetmap(x,y,slot)=-tmap(x,y).no
                                    if rnd_range(1,100)<15-distance(p1,areaeffect(a).c) then lavapoint(rnd_range(1,5))=p1
                                    if rnd_range(1,100)<3 then 
                                        lastlocalitem=lastlocalitem+1
                                        lastitem=lastitem+1
                                        li(lastlocalitem)=lastitem
                                        item(lastitem)=makeitem(96,-3,-3)
                                        item(lastitem).w.x=x
                                        item(lastitem).w.y=y
                                        item(lastitem).w.m=slot
                                    endif
                                            
                                    for b=1 to lastenemy
                                        if enemy(b).c.x=x and enemy(b).c.y=y then enemy(b).hp=enemy(b).hp-areaeffect(a).dam+distance(p1,areaeffect(a).c)
                                    next
                                    if x=awayteam.c.x and y=awayteam.c.y and areaeffect(a).dam>distance(p1,areaeffect(a).c) then 
                                        dprint "An Earthquake! "& damawayteam(awayteam,rnd_range(1,areaeffect(a).dam-distance(p1,areaeffect(a).c))),12
                                        player.killedby="Earthquake"
                                    endif
                                    areaeffect(a).dam=areaeffect(a).rad
                                endif
                                    
                            endif    
                        endif
                    endif
                next
            next
        endif

mst4k
Apr 18, 2003

budlitemolaram

oiseaux morts 1994 posted:

I had a look at the Prospector source and oh my god

Dammmnn. I've talked to that guy a few times and he's not really proud of his code but the game is still a lot of fun. My ultimate goal is combining the fun exploration of Prospector with the fun combat of DoomRL. I'm getting there..slowly. :)

o.m. 94
Nov 23, 2009

karma_coma posted:

Dammmnn. I've talked to that guy a few times and he's not really proud of his code but the game is still a lot of fun. My ultimate goal is combining the fun exploration of Prospector with the fun combat of DoomRL. I'm getting there..slowly. :)

Yeah, Prospector owns. But next time you speak to him, introduce him to the spacebar

taqueso
Mar 8, 2004


:911:
:wookie: :thermidor: :wookie:
:dehumanize:

:pirate::hf::tinfoil:

Thanks for posting prospector, I hadn't heard of it before and the concept sounds pretty fun.

steckles
Jan 14, 2006

I found some old plans I made for a vacuum chamber and decided to model it and render it with my ray tracer. This is the exploded view, I didn't actually design it to require floating bolts.


I finally implemented explicit direct lighting as well. This was something I'd been avoiding for some time for stupid ideological reasons.

YO MAMA HEAD
Sep 11, 2007

First time I've been fooled by one of your renders. Crazy good

Foiltha
Jun 12, 2008
That looks so good. My silly Whitted ray tracer with ambient occlusion looks like crap in comparison :(

Chopper
Feb 13, 2006

I was frantically trying to remove the dust from my screen. So good.

Bob Morales
Aug 18, 2006


Just wear the fucking mask, Bob

I don't care how many people I probably infected with COVID-19 while refusing to wear a mask, my comfort is far more important than the health and safety of everyone around me!

How come the nuts and bolts look so different?

Thermopyle
Jul 1, 2003

...the stupid are cocksure while the intelligent are full of doubt. —Bertrand Russell

steckles posted:

I found some old plans I made for a vacuum chamber and decided to model it and render it with my ray tracer. This is the exploded view, I didn't actually design it to require floating bolts.


I finally implemented explicit direct lighting as well. This was something I'd been avoiding for some time for stupid ideological reasons.

gently caress you for being so much more awesome than I.


Bob Morales posted:

How come the nuts and bolts look so different?

Because nuts go around bolts. They serve different purposes. :D

Adbot
ADBOT LOVES YOU

steckles
Jan 14, 2006

Thanks guys. Just for giggles, I re-rendered the image overnight but with the chamber made of plexiglass.

  • 1
  • 2
  • 3
  • 4
  • 5
  • Post
  • Reply