www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/02/25/20:00:54

From: Vic <tudor AT cam DOT org>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: DLL in djgpp???
Date: Wed, 25 Feb 1998 19:37:33 +0200
Organization: Communications Accessibles Montreal, Quebec Canada
Lines: 24
Message-ID: <34F456DD.21B8@cam.org>
References: <m0y6wML-000S2hC AT inti DOT gov DOT ar> <34F1C6C8 DOT 693E AT cam DOT org> <6cvneo$74q AT netnews DOT hinet DOT net>
NNTP-Posting-Host: dialup-509.hip.cam.org
Mime-Version: 1.0
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

Chris Bilson wrote:
> 
> I think the question here should be do we need to use DLLs in DOS. I think
> that the main reason DLLs were designed was that in Windows (or any other
> multitasking OS, really) you might have many different apps using the same
> functions and code. Instead of static linking everything, and having
> multiple copies of the same code in memory at any one time, we can put this
> stuff in DLLs and share it.
well there are cases (like mine :) where using a DLL would be useful.
Let's say I want to program a CRPG (actually a warcraft clone :)
Now I have the main engine, which gives me the sound, network, input,
graphics, pathfinding etc etc. It would be very useful if I could add a
new character without relinking the whole thing (like if I only
distribute the EXE and the user can add his own guys).
I could have something like a subdirectory with the charater's name and
in that subdirectory, have all the graphics, sounds etc and this little
file called behaviour.dll in which I would have all the functions for
that character. the character is attacked by someone, call a function in
the DLL. the time is 12 and the character set a timer for this hour,
send a message (call a function) to the DLL etc etc.
see what I mean? (of course I could use scripting, which is what I'm
looking at now, but a DLL is compiled code, therefore a lot faster...)
-- 
--> http://www.cam.org/~tudor <--

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019