?? build2.txt
字號:
// "Build Engine & Tools" Copyright (c) 1993-1997 Ken Silverman// Ken Silverman's official web site: "http://www.advsys.net/ken"// See the included license file "BUILDLIC.TXT" for license info.BUILD engine Notes (7/24/96):BUILD programmed by Ken SilvermanBUILD.TXT CONTINUED... (BUILD.TXT WAS GETTING TOO BIG!!!)哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪8/12/95 - Added parameter to initmultiplayers to allow who becomes master at the start of a multiplayer game. - Added parallaxyscale variable to BUILD.H which control the ratio at which the parallaxing skies scroll in relation to the horizon. Default is 65536. With lower values, you don't need as much artwork and can look higher, but I like 65536 because it is the correct projection.哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪8/13/95 - Had MAJOR bug with my searchmap function. If you use it, please re-copy from my game.c哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪8/14/95 - Fixed some EVIL bugs with Rt.ALT sector copying. It shouldn't screw up your maps anymore! And if you have maps that were screwed up with it, you can try my new map correcting key, L.Ctrl+L.Shift+L.Enter. This key will not affect an already perfect map. However it can SOMETIMES clean up a map that was screwed up. I take no responsibility if it screws up your map even more, so please check them before saving!哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪8/16/95 - Added error correction to mmulti.obj. Mmulti.obj is like multi.obj but it is made to work with Mark's real mode multiplayer driver that he calls COMMIT. MMULTI.OBJ vs. MULTI.OBJ: * initmultiplayers is the same, but the parameters are ignored * uninitmultiplayers can be called but does nothing. * sendlogon can be called but does nothing. * sendlogoff sends packet 255 to everybody else. It does not need to be called any more. * sendpacket and getpacket are the same. * connecthead, connectpoint2[], numplayers, myconnectindex are the same. They can be externed just like before. * getoutputcirclesize always returns 0. It is not needed. * setsocket does nothing. The socket is now in commit.dat. * crctable can still be externed. * syncstate can still be externed but is not used. * Do not use the option[4] variable. Initmultiplayers will always return a valid number in numplayers from 1-16. You can link mmulti.obj in place of multi.obj and use commit.dat as the setup file for multiplayer options. There are 2 ways you can run your game through commit: 1. Set the launch name (usually game.exe) in commit.dat and type something like "commit map01 /asdf" 2. Type "commit launch game map01 /asdf". This method is easier if you want to use the debugger with commit since you won't have to change commit.dat constantly. Ex: "commit launch wd /tr=rsi game map01 /asdf" I have not tested mmulti.obj with my BUILD game yet because I have been using 2DRAW as my test program. I may put up a new version of mmulti.obj with better error correction for extremely error-prone lines soon. - Kgroup can now accept a parameter as a filename with a list of files to be put into the group file. Ex: "kgroup @filelist.txt"哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪8/18/95 - Found a way to greatly reduce slave "hitching" on multiplayer games for faketimerhandler style communications. It's pretty simple. Step 1: In the beginning of faketimerhandler, change ototalclock = totalclock; TO: ototalclock += TICSPERFRAME; This makes the timing of the game more constant and to never miss ticks. I should have done this in the first place all along. Step 2: In getpackets, (for slaves only) count the number of times movethings is called. Normally, movethings should be called exactly once for every time getpackets is called inside faketimerhandler. The hitching is because movethings is called in a 0-2-0-2-0-2 cycle instead of the standard 1-1-1-1-1-1 cycle. This happens because the timers of the 2 computers are aligning in such a way that the slave is receiving the master's packets at nearly the same time as it calls getpackets. To correct the problem, if movethings is called an even number of times, I randomly add or subtract (TICSPERFRAME>>1) to ototalclock. Throw this code at the end of getpackets: Beginning of getpackets: movecnt = 0; Where slave receives buffer in getpackets, next to movethings: movecnt++; End of getpackets: if ((myconnectindex != connecthead) && ((movecnt&1) == 0)) { if (rand()&1) ototalclock += (TICSPERFRAME>>1); else ototalclock -= (TICSPERFRAME>>1); } - Found a way to interpolate anything using the doanimations code for faketimerhandler style multiplayer games. It's not as hard as I thought it would be (and it doesn't waste too much memory!) To smooth out doanimations, since there's no temporary variables that can be thrown away like with tsprite, the current doanimations positions must be backed up at the beginning of drawscreen and restored at the end of drawscreen. If you want smooth up&down doors, do this: Global declaration: static long oanimateval[MAXANIMATES]; Beginning of drawscreen: for(i=animatecnt-1;i>=0;i--) { oanimateval[i] = *animateptr[i]; //Backup doanimations interpolation j = *animateptr[i]; if (j < animategoal[i]) j = min(j+animatevel[i]*(totalclock-gotlastpacketclock),animategoal[i]); else j = max(j-animatevel[i]*(totalclock-gotlastpacketclock),animategoal[i]); *animateptr[i] = j; } End of drawscreen: //Restore doanimations interpolation for(i=animatecnt-1;i>=0;i--) *animateptr[i] = oanimateval[i];哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪8/19/95 - Added global invisibility variable. Initengine sets it to 0 by default. If you set global invisibility to 1, then all sprites with the invisible bit set (sprite[].cstat&0x8000) will be shown. This is useful for editing invisiblie sprites. - Made the hitscan blocking bit for sprites be the bit checked when using cliptype 1 instead of the blocking bit. Before I was accidently using the clipmove blocking bit on sprites with cliptype 1. I should have done it this way in the first place. I hope you haven't "built" around this bug too much! Here's how everything works now: Clipmove blocking bits: Which bits: wall[].cstat & 1 sprite[].cstat & 1 Used in these cases: clipmove when cliptype = 0 getzrange when cliptype = 0 Hitscan blocking bits: Which bits: wall[].cstat & 64 sprite[].cstat & 256 Used in these cases: clipmove when cliptype = 1 getzrange when cliptype = 1 hitscan always哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪8/20/95 - Reduced some overhead memory by combining 2 large internal arrays which were used in different parts of the engine. This is a total savings of about 90K.哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪8/24/95 - Changed the way 'E' mode works on ceiling and floor textures. 64*64 and 128*128 textures are the same as before so I think this won't screw up your existing maps. (But I can never be sure) Now, 'E' mode always smooshes the texture size by 2 for any size texture.哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪哪8/29/95 - 苒壙壙圮 壙 苒壙壙圮 苒壙壙圮 苒壙壙圮 苒壙壙圮 壙 壙 壙 壙 壙 壙
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -