Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon.

Pages: 1-

So yea.. Python

Name: Anonymous 2007-05-16 23:07 ID:E9N2jqNV

I thought I'd have a crack at this language.. and it is really, really weird. Probably one of the nicest things I've noticed so far is you do substrings like arrays. Which makes perfect sense and seems much more efficient. I've heard that people use Python to write games but ummm.. how? Can it interface with Direct X or something?

Oh and.. can anyone recommend some decent tutorials? I've been going through the one on the official site but pretty boring. It seems more like a list of features than a tutorial.

Name: Anonymous 2007-05-16 23:09 ID:E9N2jqNV

Oh yea, in before 'one word, forced indentation, thread closed' etc.

Name: Anonymous 2007-05-17 0:21 ID:XTmrVTc9

Hay guyz what do you think? XD this is my first program in Python:

forced = 'THE FORCED INDENTATION OF CODE'
for i in range(len(forced)):

    if i % 2:
        print forced[i]
       
    else:
        print ' '*4 + forced[i]

Name: Anonymous 2007-05-17 0:23 ID:I3T6v0a1

Name: Anonymous 2007-05-17 1:11 ID:7gZG8Te+

Most of the python tutorials I've seen are quite dull. It seems "pythonic" to take things too seriously...

The recommendation I hear the most, Dive into Python, is so full of shit and fail it's an insomnia cure.

Name: Anonymous 2007-05-17 1:16 ID:XTmrVTc9

http://docs.python.org/lib/lib.html
Thanks but this is exactly what I was reading and it's boring as shit.

http://www.google.com/search?q=python
OMG HOW DUZ I USE GOOGLE? LOL

Name: Anonymous 2007-05-17 1:21 ID:iazL1HBZ

I don't know about DirectX, but Python and OpenGL don't get along. Learn how to imbed C into a Python-program, to make your own back-end.

Name: Anonymous 2007-05-17 1:27 ID:xCo4ovfY

print '\n'.join('\n    '.join(t)
for f in ['THE FORCED INDENTATION OF CODE']
for t in zip(f[::2], f[1::2]))


>>5
Ever join #python on freenode? The topic says "NO LOL"...

Name: Anonymous 2007-05-17 1:28 ID:xCo4ovfY

Oh, and to answer the question, http://www.pygame.org/

Name: Anonymous 2007-05-17 3:20 ID:xwThPQ27

>>7
Uh? I've used Python with OpenGL (and wxPython) in a largish program. It worked really well.

Name: Anonymous 2007-05-17 6:01 ID:XTmrVTc9

The Pygame forum is so badly maintained. It's spammed to shit and no one posts in it. I never understood what the point is in that. Why is it spammers always turn up when no one uses a board anymore? And as if anyone is going to click on those links.. no matter how interesting they may seem. Good way to get your PC fucked.

Name: Anonymous 2007-05-17 7:40 ID:xCo4ovfY

>>11
Because if nobody posts, it's likely that moderators aren't watching it closely either. Spammers aren't looking for *people* to click on links; they're just looking for page rank.

Name: Anonymous 2007-05-17 8:13 ID:DTew2NE3

>>1
If strings behaving like lists that can be operated or used in against is surprising, wait till you see the rest, lots of features you'll learn to love - or hate.

Python is a general purpose dynamic language. It can be used for system scripting, web applications, desktop applications, network applications, games, scientific computing, and as an embedded scripting language. It's commonly used for system-related applications and scripts, as an embedded language, and for scientific computing, among others. There are interfaces to POSIX, Win32, SDL, OpenGL, DirectX, wxWindows and others.

For a tutorial, I recommend Guido's own from http://docs.python.org . If you're familiar with dynamic languages, you can go through it in two days and start reading and writing Python (with the help of the standard library documentation) right away.

Name: Anonymous 2007-05-17 14:08 ID:iazL1HBZ

>>10
I couldn't do texture-mapping, when I used wxPython. Well, my knowledge of OpenGL was a little sparse, when I wrote this demo:
http://python-forum.org/py/viewtopic.php?t=3757

What's the word on PyGame's upgrade for Python 2.5?

Name: Anonymous 2007-05-17 14:11 ID:I3T6v0a1

>>6

It's a fucking library reference.  Of course it isn't exciting.

Name: Anonymous 2007-05-17 14:15 ID:Heaven

>>14
Then maybe, just maybe, you shouldn't run around telling people that "Python and OpenGL don't get along" and advicing them to reinvent the wheel.

Name: Anonymous 2007-05-17 14:58 ID:iazL1HBZ

>>16
You win this round, motherfucker; but I've still got Togl refusing to compile with recent versions of Tkinter for no apparent reason! Haha! What have you to say, nao?

Now why won't the code I linked to work? Everyone I've shown it to says that the damn thing thing ought to give more than a white rectangle.

Name: Anonymous 2007-05-17 15:25 ID:8s1jJw9k

>>17
are you loading images with power-of-2 dimensions

Name: Anonymous 2007-05-17 16:01 ID:iazL1HBZ

>>18
128x128

I'm not THAT new.

Name: Anonymous 2007-05-17 16:34 ID:pzoVmfTa

python is so stupid, perl has existed for so long and works

Name: Anonymous 2007-05-17 20:48 ID:e4NIpVwN

>>20
yes because python and perl are trying to achieve the same things and have the exact same philosophy

Name: Anonymous 2007-05-17 21:49 ID:wmozUT3x

A blank instead of a texture may be OpenGL's way of saying that it doesn't recognize the texture format. It's the only thing I can see in your code that could possibly screw up.

Name: Anonymous 2007-05-17 22:31 ID:nZbNQh3J

fuck off python fags

Name: Anonymous 2007-05-17 23:02 ID:F/jsM9IB

>>23
How can we have a proper flamewar when you don't even tell us whether you're a Haskell fag, a LISP wanker, a VB tard, a Java loser or a real C programmer?
Fine, I'll just pick one for you; GTFO, you senile old fossil, and take your FORTRAN compiler with you!

Name: Anonymous 2007-05-18 1:50 ID:sDk6qVwo

>>20
perl is so stupid, lisp has existed for so long and works

Name: Anonymous 2007-05-18 2:27 ID:N9TSNmYz

>>22
I'm glad to see you say that. I've tried multiple formats, and nothing works. GLUT loads things finely.

I'll stick with my decision to return to C/++. How do I get Togl to work? I'm just curious, at this point.

Name: Anonymous 2007-05-18 6:32 ID:si6SqTY6

Name: Anonymous 2007-05-18 9:06 ID:gqBUIgSP

'LISP wanker' lopl

Name: Anonymous 2007-05-18 9:41 ID:c4v0ikeY

WANKAH

Name: Anonymous 2007-05-18 10:00 ID:Heaven

NO EXCEPTIONS

Name: Anonymous 2007-05-18 15:14 ID:RQbi+nCn

>>14
try using gluBuild2DMipmaps instead of glTexImage2D.

ACTUAL ADVICE ON 4CHAN? ITS MORE LIKELY THAN YOU THINK.

Name: Anonymous 2007-05-18 15:25 ID:BL7q4dG2

Anyone not stuck in the '90s is using ARB_texture_rectangle.

Name: Anonymous 2009-01-14 14:32

Can moderators ban this faggot?

Name: Sgt.Kabu齲哃kimanꦀ넩 2012-05-29 2:05

Bringing /prog/ back to its people
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy
All work and no play makes Jack a dull boy

Don't change these.
Name: Email:
Entire Thread Thread List