Original Post
can someone explaing to me scripting and the benefits and common tasks one would use scripting for in terms of game development (preferable something simple like pong or breakout) thanks.
Quote:
Original post by evolutional
In terms of pong and breakout... You'd create your game 'engine' which is capable of creating sprites and drawing them, it can load and play sounds and do all other actions you'd expect a game to do. However, if you were scripting it you wouldn't have any mention anywhere about the pong or breakout terminology. Instead you'd program scripts for your games to capture the logic and tell the sprites where to be drawn and what to do when they collide.
Bear in mind though that there are also different levels of scripting. Some games, such as Half-Life used scripting to say "if player is here, play this cutscene or awaken this enemy". The core game logic would still be in C++ code, just special events are scripted. However with the likes of Unreal, more and more is scripted in the game meaning that the core engine doesn't really have much to do with game logic at all, instead it just obeys what the scripts tell it to do.
If you're interested, look at my gmSDL 0.1 preview which is simply an executable that contains bindings for SDL to GameMonkey Script. The script itself handles the movement and creation of sprites, SDL just displays them. I will shortly release pong, pacman and probably breakout coded in nothing but script with this binding. Pacman is almost complete now.
Quote:
Original post by baker
oic, scripting enables a developer to control the aspects of the game at a much higher level of design.
Quote:
so if i am creating a breakout game, when the ball hits a blocks, i can have a script to say "when block and ball collide, play block destruction animation" etc...
so basically that script would somehow link directly to c++ function call? or have an alias of somesort?
in a script, i can call that c++ function to play whatever animation script i want at what action performed?
if (class == scout) Bind("x", thrust);else Bind("x", fire);This topic has been locked by a moderator. New replies are not allowed.
With your permission, GameDev.net uses analytics cookies to understand how people use the platform. You can accept analytics or continue with necessary cookies only. Learn more