newbie question

B

bektek

I heard that python or other script languages can be used as game scripting..
Actually It's so hard to understand what that means for newbies like me?

What's mean being used as game script?
Could show me simple example like 'hello world'?

I'll be appreciated..
 
L

Lonnie Princehouse

What is usually meant when Python is mentioned in the context of game
scripting is that it's relatively easy for a game's developers to embed
a Python interpreter into the game. Python would then be used to
control higher-level gameplay elements like artificial intelligence
while the game's native language (probably C) handles the heavy lifting
(e.g. rendering, collision detection, etc).

This does /not/ mean that you will be able to use Python to modify your
favorite game, unless it happens to already have an interpreter
built-in. Maybe some resident gamers here can list some games that use
Python for user-accessible scripting; I don't know of any.
 
T

Tiziano Bettio

Just a few days earlier someone posted me the link to panda3d
(www.panda3d.org)
This is actually a gamengine/renderingengine on which u can develop
games in python.

If u want to achieve high performance you'd rather use c++ and directly
access libs like nvidias cg, ms directx or opengl...

for a "hello world", understanding how the 3d enviroment works and so on
panda3d is a really good start.

cheers

tc
 
M

M.E.Farmer

You might want to look at PyGame.
http://pygame.org/

Newbies can go far using PyGame but the maths can be a bit complex no
matter what language or package you use.
For an alternative try Blender 3d.
http://blender.org
Blender is a 3d suite that can do it all and then some , it's free ,and
it uses Python for it's scripting. You can create a game and never
touch a piece of code if you use the builtin actuators and sensors, or
you can script with Python.
hth,
M.E.Farmer
 
C

Cameron Laird

.
.
.
If u want to achieve high performance you'd rather use c++ and directly
access libs like nvidias cg, ms directx or opengl...
.
.
.
Yes. Well, maybe. Python-coded programs, even graphically-intense
games, *can* exhibit good performance, and there are numerous
anecdotes about applications LOSING speed on conversion to C++ from
Python. Moreover, there's no inherent conflict between C++ and
Python; some successful applications use both.

My summary: it's a subtler matter than, "for performance, abandon
Python on favor of C++". I think you know that, but I want to make
it explicit for less-experienced readers.
 
T

Tiziano Bettio

Cameron said:
.
.
.


.
.
.
Yes. Well, maybe. Python-coded programs, even graphically-intense
games, *can* exhibit good performance, and there are numerous
anecdotes about applications LOSING speed on conversion to C++ from
Python. Moreover, there's no inherent conflict between C++ and
Python; some successful applications use both.

My summary: it's a subtler matter than, "for performance, abandon
Python on favor of C++". I think you know that, but I want to make
it explicit for less-experienced readers.
yeah well, i didn't intended to say it in this specific way. tough to be
more exact: for a game you can realize up to 95% in python without
losing the needed performance. but there's almost always a little part
where u really need to get even the last bit of performance out of the
hardware or where nobody has already ported the lib you need into
python, where c++ comes in rather handy.

I didn't ment to offend any pythonian (wouldn't want to offend
myself...), but i think we all agree that sometimes all of us have seen
or even programmed something in c++ (or other languages) what could come
in really handy for a project one is working on.

so again, didn't ment to say that it's a performance matter (there are
thousands of bad c++ programmers out there which are hiding behind
compiled code...) :)

cheers tc
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,235
Messages
2,571,181
Members
47,818
Latest member
KazukoXea6

Latest Threads

Top