Jump to content
The Dark Mod Forums

Kwazy Wabbit Ideas: Bot Spawning?


nbohr1more

Recommended Posts

I've been pretty well behaved these days and my foolish speculations have not veered too far into the twilight zone but I have recently become more interested in the topic of Symmetric Multi-Processing (SMP) and it's future implications for Id Tech 4.

 

From my understanding, The Dark Mod uses "Boost" libraries to take advantage of an existing body of work with regard to C++ library support. When I began to delve into some of the newer Boost features I stumbled upon "Boost.Thread" which is apparently a special case "Thread spawning library". This has sparked my curiosity about whether there is any way to "farm out" threads through invoking this library or invoking another DLL that contains this library.

 

After a little Doom3world searching, I came across an old thread where soon after Doom 3's release a modder had decided to "Fake Client Bots"

 

http://www.doom3world.org/phpbb2/viewtopic.php?f=56&t=9940&st=0&sk=t&sd=a

 

1) Is this still possible?

2) Could this "Bot spawning" be pinned to different CPU cores?

3) Is it even possible to use the Boost Thread library to avoid such a cumbersome workaround?

 

So... I'm probably so short of clues here that my progeny will be in "clue debt" long after my passing...

 

Commence with the scolding :laugh:

Please visit TDM's IndieDB site and help promote the mod:

 

http://www.indiedb.com/mods/the-dark-mod

 

(Yeah, shameless promotion... but traffic is traffic folks...)

Link to comment
Share on other sites

Rather than have the AI all sharing time-slices of the same CPU core, you might be able to grant Bots the same AI and have them run on separate CPU cores. They would access the game as if they were human players in a multi-player match.

 

(Edit: mangled sentence fragment...)

Edited by nbohr1more

Please visit TDM's IndieDB site and help promote the mod:

 

http://www.indiedb.com/mods/the-dark-mod

 

(Yeah, shameless promotion... but traffic is traffic folks...)

Link to comment
Share on other sites

That would be one of many questions...

 

The main one being, "Can a single-threaded application running in Windows call a DLL that spawns threads then returns the result "serialized" or does the core application always need to know how many threads are invoked (or some other syntax restriction that prevents parallel threads from touching a single threaded application)?

 

Would the above require another executable in addition to the DLL?

 

If it is possible to do such a thing but AI path-finding is buried in the closed source portion of the code, then could you bypass this path-finding and make the AI think they are seeing a simple path by externally solving the path-finding then modifying the AI path perception with the result?

 

If it's not possible to thread as above could you still create an external AI Bot that interacts with Doom 3's multi-player net-code and has all the capabilities of a native AI?

 

I have always thought that SMP was currently impossible but there a things like that D3W link that are making me reconsider my assumptions.

 

Just curiosity...

 

Edit:

 

This document makes it seem so tantalizingly possible...

 

http://www.boost.org/doc/libs/1_37_0/doc/html/thread/thread_management.html

Edited by nbohr1more

Please visit TDM's IndieDB site and help promote the mod:

 

http://www.indiedb.com/mods/the-dark-mod

 

(Yeah, shameless promotion... but traffic is traffic folks...)

Link to comment
Share on other sites

Yeah, the bot idea is probably too much work given how close GPL is.

 

That boost.thread thing OTOH, looks like it can obfuscate the threads in a function so the core executable won't even know it's calling threads:

 

This allows the details of thread creation to be wrapped in a function.

 

(there has to be some gotha to this though...)

Please visit TDM's IndieDB site and help promote the mod:

 

http://www.indiedb.com/mods/the-dark-mod

 

(Yeah, shameless promotion... but traffic is traffic folks...)

Link to comment
Share on other sites

We already use Boost.Threads internally as I understand it, also I think Doom 3 itself provides threading, for example in script functions. So I don't think whatever Massive Hidden Potential you're imagining really exists.

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.

  • Recent Status Updates

    • nbohr1more

      The FAQ wiki is almost a proper FAQ now. Probably need to spin-off a bunch of the "remedies" for playing older TDM versions into their own article.
      · 1 reply
    • nbohr1more

      Was checking out old translation packs and decided to fire up TDM 1.07. Rightful Property with sub-20 FPS areas yay! ( same areas run at 180FPS with cranked eye candy on 2.12 )
      · 3 replies
    • taffernicus

      i am so euphoric to see new FMs keep coming out and I am keen to try it out in my leisure time, then suddenly my PC is spouting a couple of S.M.A.R.T errors...
      tbf i cannot afford myself to miss my network emulator image file&progress, important ebooks, hyper-v checkpoint & hyper-v export and the precious thief & TDM gamesaves. Don't fall yourself into & lay your hands on crappy SSD
       
      · 7 replies
    • OrbWeaver

      Does anyone actually use the Normalise button in the Surface inspector? Even after looking at the code I'm not quite sure what it's for.
      · 7 replies
    • Ansome

      Turns out my 15th anniversary mission idea has already been done once or twice before! I've been beaten to the punch once again, but I suppose that's to be expected when there's over 170 FMs out there, eh? I'm not complaining though, I love learning new tricks and taking inspiration from past FMs. Best of luck on your own fan missions!
      · 4 replies
×
×
  • Create New...