Mirage Source

Free ORPG making software.
It is currently Thu Mar 28, 2024 5:55 pm

All times are UTC




Post new topic Reply to topic  [ 1148 posts ]  Go to page 1, 2, 3, 4, 5 ... 46  Next
Author Message
 Post subject: Updated: Sprite Preview
PostPosted: Mon Jan 01, 2007 6:42 pm 
Offline
Banned
User avatar

Joined: Mon Jun 05, 2006 9:22 pm
Posts: 394
Location: USA
I want to columns of items since if I kept extending my current one it would be too long for a lot of PCs. How/where should I begin editing to make this a reality?


Last edited by James on Tue Jan 02, 2007 2:14 am, edited 1 time in total.

Top
 Profile  
 
 Post subject:
PostPosted: Mon Jan 01, 2007 6:54 pm 
Offline
Pro

Joined: Mon May 29, 2006 2:15 am
Posts: 368
make sure the editor stores an x and y, and make sure the blt recs don't just use pic_x for left... check out one of the sources that have it if you need an example. I think Konfuze had that.

_________________
Image
Image
The quality of a man is not measured by how well he treats the knowledgeable and competent, but rather how he treats those less fortunate than himself.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jan 01, 2007 6:54 pm 
Offline
Submit-Happy
User avatar

Joined: Fri Jun 16, 2006 7:01 am
Posts: 2768
Location: Yorkshire, UK
Errrrm,,,,,, ones of those lists which has different thingys,,,,,

Ooooor add antoher list and have'

'if item>50 and <10e then
add to second list foo'!
'


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jan 02, 2007 2:17 am 
Offline
Banned
User avatar

Joined: Mon Jun 05, 2006 9:22 pm
Posts: 394
Location: USA
Fixed the itemset issue, now how about this.

I had an old code from GSD that showed a preview of the sprite when you made it. I have since changed to PNG graphics and that code is no longer usable. I made a timer on frmNewChar and then made a timer which is set at an interval of 50 and so it calls a duplicate of the BltNPC sub used for the NPC editor to blit the sprite into a picbox. Below are the ocdes for the timer and the sub. If anyone could tell me why it isnt working, please help!

Code:
Public Sub NewCharBltSprite()

    With rec
        If frmNewChar.optMale.Value = True Then
            .top = Int(Class(frmNewChar.cmbClass.ListIndex).Sprite) * PIC_Y
        Else
            .top = Int(Class(frmNewChar.cmbClass.ListIndex).Sprite + 1) * PIC_Y
        End If
        .Bottom = .top + PIC_Y
        .Left = 3 * PIC_X
        .Right = .Left + PIC_X
    End With
   
    With rec_pos
        .top = 0
        .Bottom = PIC_Y
        .Left = 0
        .Right = PIC_X
    End With
   
    If DD_SpriteSurf Is Nothing Then
    Else
        DD_SpriteSurf.BltToDC frmNewChar.picpic.hDC, rec, rec_pos
    End If
    frmNewChar.picpic.Refresh
End Sub


and the timer

Code:
Private Sub timerSprite_Timer()
    Call NewCharBltSprite
End Sub


I've discovered this is because InitDirectX and InitSurfaces hasn't been called yet, but I can't call them until after this done because it calls up frmMirage, is there any way to edit this so frmMirage doesn't appear until afterwards?

New Update: Now with Dave it will show the very first sprite and second when u hit female, but it wont change the sprite, even when i move the Call NewCharBltSprite to the cmbClass_Click sub.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jan 02, 2007 4:35 am 
Offline
Banned
User avatar

Joined: Mon Jun 05, 2006 9:22 pm
Posts: 394
Location: USA
Okay, by calling those things before hadn it works, somewhat. It only shows Sprite 1 and 2 when I click female (Class Sprite + 1 = Female Sprite on the sprite sheet) but it wont change when everything else changes. here are the subs:

Code:
Private Sub cmbClass_Click()
    lblHP.Caption = STR(Class(cmbClass.ListIndex).HP)
    lblMP.Caption = STR(Class(cmbClass.ListIndex).MP)
    lblSP.Caption = STR(Class(cmbClass.ListIndex).SP)
   
    lblSTR.Caption = STR(Class(cmbClass.ListIndex).STR)
    lblDEF.Caption = STR(Class(cmbClass.ListIndex).DEF)
    lblSPEED.Caption = STR(Class(cmbClass.ListIndex).SPEED)
    lblMAGI.Caption = STR(Class(cmbClass.ListIndex).MAGI)
    Call picpic.Refresh
    Call NewCharBltSprite(cmbClass.ListIndex)
End Sub


Code:
Private Sub cmbClass_Change()
    Call NewCharBltSprite(cmbClass.ListIndex)
End Sub


Code:
Public Sub NewCharBltSprite(ByVal ListIndexSprite As Long)
With rec
        If frmNewChar.optMale.Value = True Then
            .top = Int(Class(ListIndexSprite).Sprite) * PIC_Y
        Else
            .top = Int(Class(ListIndexSprite).Sprite + 1) * PIC_Y
        End If
        .Bottom = .top + PIC_Y
        .Left = 3 * PIC_X
        .Right = .Left + PIC_X
    End With
   
    With rec_pos
        .top = 0
        .Bottom = PIC_Y
        .Left = 0
        .Right = PIC_X
    End With
   
    If DD_SpriteSurf Is Nothing Then
    Else
        DD_SpriteSurf.BltToDC frmNewChar.picpic.hDC, rec, rec_pos
    End If
End Sub


So, right now, it shows well, Sprite 0 technically, and when I click female, it does change, however when I change the cmbClass the stats change, but the sprite does not, and I am unsure why.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jan 02, 2007 6:29 am 
Offline
Banned
User avatar

Joined: Mon Jun 05, 2006 9:22 pm
Posts: 394
Location: USA
Error found.

I = Idget. Sorry.


Top
 Profile  
 
PostPosted: Wed Dec 01, 2021 12:13 pm 
Offline
Mirage Source Lover

Joined: Sun Jul 04, 2021 4:04 am
Posts: 456192
сайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайт
сайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайт
сайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайт
сайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайт
сайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайт
сайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайт
сайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайт
сайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайт
сайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтсайтsemiasphalticfluxсайтсайтсайт
сайтсайтсайтсайтсайтсайтhttp://taskreasoning.ruсайтсайтсайтинфосайтсайтtuchkasсайтсайт


Top
 Profile  
 
PostPosted: Sun Jan 23, 2022 9:39 am 
Offline
Mirage Source Lover

Joined: Sun Jul 04, 2021 4:04 am
Posts: 456192
Kbit


Top
 Profile  
 
PostPosted: Sun Jan 23, 2022 9:41 am 
Offline
Mirage Source Lover

Joined: Sun Jul 04, 2021 4:04 am
Posts: 456192
163.4


Top
 Profile  
 
PostPosted: Sun Jan 23, 2022 9:42 am 
Offline
Mirage Source Lover

Joined: Sun Jul 04, 2021 4:04 am
Posts: 456192
Bett


Top
 Profile  
 
PostPosted: Sun Jan 23, 2022 9:43 am 
Offline
Mirage Source Lover

Joined: Sun Jul 04, 2021 4:04 am
Posts: 456192
Bett


Top
 Profile  
 
PostPosted: Sun Jan 23, 2022 9:44 am 
Offline
Mirage Source Lover

Joined: Sun Jul 04, 2021 4:04 am
Posts: 456192
Cudd


Top
 Profile  
 
PostPosted: Sun Jan 23, 2022 9:45 am 
Offline
Mirage Source Lover

Joined: Sun Jul 04, 2021 4:04 am
Posts: 456192
Pict


Top
 Profile  
 
PostPosted: Sun Jan 23, 2022 9:46 am 
Offline
Mirage Source Lover

Joined: Sun Jul 04, 2021 4:04 am
Posts: 456192
Noth


Top
 Profile  
 
PostPosted: Sun Jan 23, 2022 9:47 am 
Offline
Mirage Source Lover

Joined: Sun Jul 04, 2021 4:04 am
Posts: 456192
Wend


Top
 Profile  
 
PostPosted: Sun Jan 23, 2022 9:48 am 
Offline
Mirage Source Lover

Joined: Sun Jul 04, 2021 4:04 am
Posts: 456192
Jere


Top
 Profile  
 
PostPosted: Sun Jan 23, 2022 9:49 am 
Offline
Mirage Source Lover

Joined: Sun Jul 04, 2021 4:04 am
Posts: 456192
John


Top
 Profile  
 
PostPosted: Sun Jan 23, 2022 9:51 am 
Offline
Mirage Source Lover

Joined: Sun Jul 04, 2021 4:04 am
Posts: 456192
Hits


Top
 Profile  
 
PostPosted: Sun Jan 23, 2022 9:52 am 
Offline
Mirage Source Lover

Joined: Sun Jul 04, 2021 4:04 am
Posts: 456192
Atom


Top
 Profile  
 
PostPosted: Sun Jan 23, 2022 9:53 am 
Offline
Mirage Source Lover

Joined: Sun Jul 04, 2021 4:04 am
Posts: 456192
Atla


Top
 Profile  
 
PostPosted: Sun Jan 23, 2022 9:54 am 
Offline
Mirage Source Lover

Joined: Sun Jul 04, 2021 4:04 am
Posts: 456192
Atla


Top
 Profile  
 
PostPosted: Sun Jan 23, 2022 9:55 am 
Offline
Mirage Source Lover

Joined: Sun Jul 04, 2021 4:04 am
Posts: 456192
Mark


Top
 Profile  
 
PostPosted: Sun Jan 23, 2022 9:56 am 
Offline
Mirage Source Lover

Joined: Sun Jul 04, 2021 4:04 am
Posts: 456192
Quat


Top
 Profile  
 
PostPosted: Sun Jan 23, 2022 9:57 am 
Offline
Mirage Source Lover

Joined: Sun Jul 04, 2021 4:04 am
Posts: 456192
XVII


Top
 Profile  
 
PostPosted: Sun Jan 23, 2022 9:58 am 
Offline
Mirage Source Lover

Joined: Sun Jul 04, 2021 4:04 am
Posts: 456192
Deko


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 1148 posts ]  Go to page 1, 2, 3, 4, 5 ... 46  Next

All times are UTC


Who is online

Users browsing this forum: No registered users and 8 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group