Jump to content

Functions that handle the game's mechanics


jeffnz
 Share

Recommended Posts

I'm not interested in specialised things like animation, graphics or ai. Where do I find the functions that are responsible for basic gameplay mechanics? I mean the functions that handle practical things, like unit creation/unit death, construction, and the in-game UI. What files should I look at? I can use ctrl + f in Visual Studio 2013 but it isn't very useful.

Link to comment
Share on other sites

Cool, 'spidermonkey' in sources is the one.

"spidermonkey: Mozilla's JavaScript engine written in C/C++. JavaScript is the game's scripting language of choice (game logic, AIs, random maps, etc)"

I'm so stupid I thought that Spidermonkey was written in javascript, but it's written in C/C++ and it handles javascript but it isn't javascript itself LOL

Update: what files are part of spidermonkey? Is it source\scriptinterface?

Update 2: "ScriptEngine scriptEngine" that looks like the initialisation of Spidermonkey and it's in main.cpp

Update 3: I searched the entire VS 'solution' for references to 'ScriptEngine' and 'scriptEngine' and couldn't find very many. It doesn't seem to lead me to anything that I was looking for.

Edited by jeffnz
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...