![]() |
32*64 NPC's Full Tut - Printable Version +- Mirage Source (https://mirage-engine.uk/forums) +-- Forum: Mirage Source (Nostalgia) (https://mirage-engine.uk/forums/forumdisplay.php?fid=61) +--- Forum: Archive (2006-2011) (https://mirage-engine.uk/forums/forumdisplay.php?fid=18) +---- Forum: Resources (https://mirage-engine.uk/forums/forumdisplay.php?fid=49) +---- Thread: 32*64 NPC's Full Tut (/showthread.php?tid=362) |
32*64 NPC's Full Tut - DarkX - 14-10-2006 Tutorial by: DarkX Code tested on: MSE Ok I was looking over all the things that were missing on that version that William posted, which I guess was made by Sign, not really sure, but I wanted people to have the whole idea before they add it, here's my version of the tutorial. Ok this is all client side, let's start with this: Code: ' Blit out the npcs It should look like this: Code: ' Blit out the npcs top copy the entire sub. Then paste it below the first one and rename it, " Public sub BltNpcTop(byval MapNpcNum as long) " In bltNpcTop; replace This: Code: ' Check if its out of bounds because of the offset Code: ' Check if its out of bounds because of the offset Code: With rec Code: With rec Code: With rec Code: With rec Now that's still not all of it. Go into sub BltMapNpcName and replace This: Code: TextY = MapNpc(Index).y * PIC_Y + MapNpc(Index).YOffset - CLng(PIC_Y / 2) - 4 Code: TextY = MapNpc(Index).Y * PIC_Y + MapNpc(Index).YOffset - 50 '(or-4 - pic_y - pic_y/2) Make it's width 480 And it's height 960 And finally the LAST part. In modGameLogic find Sub NPCEditorBltSprite Once you've found it, replace the whole sub with this: Code: Public Sub NpcEditorBltSprite() Or just put this: *2 :After every PIC_Y. And that's the complete tutorial; have fun with it. - DarkX - 05-11-2006 I was looking over my code and it blt's correctly for me, it blts the players head over the npc's... Though I have to work on the part where it blts your feet over the npc's head. - Forte - 03-12-2006 Sorry for bringing back this old tut guys,but im Quake. Im new to VB and Mirage. I was testing out this tutorial and i thought i could help DarkX a bit. I hope you dont get offended if you think im trying to make my way look better im only trying to help ![]() Well, I placed Code: ' Blit out the npcs top AFTER Code: ' Blit out players By doing this, it makes the NPC tops over the players. Now for some reason this bit of code didnt work well for me Code: With rec So i just removed the * 2 after PIC_Y and it worked. I dont actually know what i did lol but it works. BTW nice tut i used it - Rezeyu - 16-04-2007 Not sure if I was the only one that got this error, but my NPc's kept showing up like this if the sprite number was odd: ![]() So I simply went into Sub NPCEditorOk() and changed this line: Code: Npc(EditorIndex).Sprite = frmNpcEditor.scrlSprite.Value * 2 And in Sub NPCEditorInit() Code: frmNpcEditor.scrlSprite.Value = Npc(EditorIndex).Sprite / 2 (At first I thought I need to double the editor's scroll value, but that wasn't the case.) - Tony - 16-04-2007 What font is that? And you better tell meh! - Matt - 16-04-2007 Looks like Arial. - Rezeyu - 16-04-2007 Tahomaz0rz - Tony - 17-04-2007 Rezeyu Wrote:Tahomaz0rz Whats the exacts?! Tahoma Bold, size? - Rezeyu - 17-04-2007 Code: ' Font variables No other variables changed. Except stroked. - Tony - 17-04-2007 Why the hell is your shit so smooth? - Rezeyu - 17-04-2007 Umm.. I dunno. When I added the stroked text, I sued Elysium's tut because I couldn't find the one I used from Mirage on my original source. (I think it was lost from the backups) Then I went into a tut request about text outline and I think I actually used YOUR modification to the code.. Code: Call TextOut(hdc, x + 1, y + 0, Text, Len(Text)) - Tony - 17-04-2007 I'm positive thats not it o.o I guess its gfx card concerns? - Rezeyu - 17-04-2007 Mehbeh.. I'm running on a 256MB ATI Radeon X1300 Pro, I needed a 256g= Meg card to run Vista. - Boo - 17-04-2007 Try chaning your resolution to like 16 Bit, see if that helps :o Re: 32*64 NPC's Full Tut - El_Dindonnier - 16-12-2007 Hello, i have a bug, look that : ![]() Can I help me please ? Thanks you in advance. Re: 32*64 NPC's Full Tut - Ramsey - 19-02-2008 Sorry for necroing but I just had to put up the bug fix. Refer to: ![]() This can easily be fixed by moving the: Code: ' Blit out the npcs top Under: Code: ' Blit out players Making it look like: Code: ' Blit out the npcs Solved. Re: 32*64 NPC's Full Tut - Rhyfelwr - 24-07-2008 That bug fix doesn't work for me.. I tried this out and I still get the doubled sprite.. Instead of getting the "top" sprite? Re: 32*64 NPC's Full Tut - DarkX - 24-07-2008 somewhere up above one of the guys posted a fix replace the * with a / Re: 32*64 NPC's Full Tut - Robin - 11-08-2008 Why do you need an algorithm? Code: For y = 0 to max_mapy Something like that should work. |