Mirage Source

Free ORPG making software.
It is currently Sat Apr 27, 2024 3:56 pm

All times are UTC




Post new topic Reply to topic  [ 77 posts ]  Go to page Previous  1, 2, 3, 4  Next
Author Message
PostPosted: Sat Sep 06, 2008 3:17 pm 
Offline
Pro

Joined: Mon May 29, 2006 5:01 pm
Posts: 420
Location: Canada, BC
Google Talk: anthony.fleck@gmail.com
You still used a picture box and a timer though.

I want to do it without either :).


Top
 Profile  
 
PostPosted: Sat Sep 06, 2008 4:13 pm 
There's really no need for a loop on that part of the game as it's rarely used and only used for the person creating a character.


Top
  
 
PostPosted: Sat Sep 13, 2008 3:01 pm 
Offline
Knowledgeable
User avatar

Joined: Fri Sep 12, 2008 11:18 pm
Posts: 176
Location: England.
Well, anyone mind telling me what Class(i).Sprite is now?(I presume it was changed, I'm using DFA's 3.50)


Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 3:15 pm 
Mattyw wrote:
Well, anyone mind telling me what Class(i).Sprite is now?(I presume it was changed, I'm using DFA's 3.50)


Read the source?


Top
  
 
PostPosted: Sat Sep 13, 2008 5:07 pm 
Offline
Community Leader
User avatar

Joined: Sun May 28, 2006 10:29 pm
Posts: 1762
Location: Salt Lake City, UT, USA
Google Talk: Darunada@gmail.com
In VB6 you can right click on something and click "Definition" and it will pop you right there most of the time.

Class(i).sprite is defined in modTypes in the user defined type called ClassRec

_________________
I'm on Facebook! Google Plus LinkedIn My Youtube Channel Send me an email Call me with Skype Check me out on Bitbucket Yup, I'm an EVE Online player!
Why not try my app, ColorEye, on your Android devlce?
Do you like social gaming? Fight it out in Battle Juice!

I am a professional software developer in Salt Lake City, UT.


Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 5:16 pm 
Offline
Persistant Poster
User avatar

Joined: Tue May 30, 2006 2:07 am
Posts: 836
Location: Nashville, Tennessee, USA
Google Talk: rs.ruggles@gmail.com
Probably in the ClassRec somewhere. Not entirely sure where it's at in DFAs version though.

_________________
I'm on Facebook! Google Plus My Youtube Channel My Steam Profile

Image


Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 5:17 pm 
He change the system. Quite a bit.


Top
  
 
PostPosted: Sat Sep 13, 2008 5:45 pm 
Offline
Submit-Happy
User avatar

Joined: Fri Jun 16, 2006 7:01 am
Posts: 2768
Location: Yorkshire, UK
What?

_________________
Quote:
Robin:
Why aren't maps and shit loaded up in a dynamic array?
Jacob:
the 4 people that know how are lazy
Robin:
Who are those 4 people?
Jacob:
um
you, me, and 2 others?


Image


Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 6:07 pm 
Offline
Knowledgeable
User avatar

Joined: Fri Sep 12, 2008 11:18 pm
Posts: 176
Location: England.
Well for some reason I get a "Subscript Out of Range" error when I have "Class(i).Sprite = Val(Parse(n + 8))" not commented out & try to create a new character.

Then when it's commented out & stuff, Sprite won't show on creation of course & both Class Names say 4 for some reason on the Drop Down.

Here's all the code I have for this:

Code:
Sub SendNewCharClasses(ByVal Index As Long)
Dim Packet As String
Dim I As Long

    Packet = "newcharclasses" & SEP_CHAR & Max_Classes
    For I = 1 To Max_Classes
        Packet = Packet & GetClassName(I) & SEP_CHAR & GetClassMaxVital(I, Vitals.HP) & SEP_CHAR & GetClassMaxVital(I, Vitals.MP) & SEP_CHAR & GetClassMaxVital(I, Vitals.SP) & SEP_CHAR & Class(I).Stat(Stats.Strength) & SEP_CHAR & Class(I).Stat(Stats.Defense) & SEP_CHAR & Class(I).Stat(Stats.SPEED) & SEP_CHAR & Class(I).Stat(Stats.Magic) & SEP_CHAR & Class(I).Sprite
    Next I
    Packet = Packet & END_CHAR
   
    Call SendDataTo(Index, Packet)
End Sub
----------------------------------------------------------------------------------
Private Sub Timer_Timer()
    On Error Resume Next
    If optMale.Value = True Then
        'Call BitBlt(picpic.hdc, 0, 0, PIC_X, PIC_Y, picSprites.hdc, 0, Int(Class(cmbClass.ListIndex).Sprite) * PIC_Y, SRCCOPY)
    Else
        'Call BitBlt(picpic.hdc, 0, 0, PIC_X, PIC_Y, picSprites.hdc, 0, Int(Class(cmbClass.ListIndex).Sprite) * PIC_Y, SRCCOPY)
    End If
End Sub
----------------------------------------------------------------------------------
picSprites.Picture = LoadPicture(App.Path & "/gfx/sprites.bmp")
----------------------------------------------------------------------------------
            n = n + 1

            For i = 1 To Max_Classes
                Class(i).Name = Parse(n)
   
                Class(i).Vital(Vitals.HP) = Val(Parse(n + 1))
                Class(i).Vital(Vitals.MP) = Val(Parse(n + 2))
                Class(i).Vital(Vitals.SP) = Val(Parse(n + 3))
   
                Class(i).Stat(Stats.Strength) = Val(Parse(n + 4))
                Class(i).Stat(Stats.Defense) = Val(Parse(n + 5))
                Class(i).Stat(Stats.SPEED) = Val(Parse(n + 6))
                Class(i).Stat(Stats.Magic) = Val(Parse(n + 7))
                'Class(i).Sprite = Val(Parse(n + 8))
               
                n = n + 8
            Next i


I have to block out BitBlt also as you can see, don't know the conversion or so.

All help would be appreciated.


Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 6:12 pm 
Offline
Persistant Poster
User avatar

Joined: Thu Mar 29, 2007 10:30 pm
Posts: 1510
Location: Virginia, USA
Google Talk: hpmccloud@gmail.com
n = n + 8

Needs to be

n = n + 9

ALSO EDIT:

cmbClass.ListIndex

You need to do + 1 when you use that since it starts at 0.

_________________
Nean wrote:
Yes harold. Give it to me.

Image
Image


Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 6:15 pm 
Offline
Knowledgeable
User avatar

Joined: Fri Sep 12, 2008 11:18 pm
Posts: 176
Location: England.
I do that when the Sprite part is unblocked.

EDIT: When I unblock the BitBlt part, I can't compile.


Last edited by Mattyw on Sat Sep 13, 2008 6:16 pm, edited 1 time in total.

Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 6:15 pm 
Offline
Persistant Poster
User avatar

Joined: Thu Mar 29, 2007 10:30 pm
Posts: 1510
Location: Virginia, USA
Google Talk: hpmccloud@gmail.com
I made an edit in case you didn't catch it.

_________________
Nean wrote:
Yes harold. Give it to me.

Image
Image


Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 6:16 pm 
Offline
Knowledgeable
User avatar

Joined: Fri Sep 12, 2008 11:18 pm
Posts: 176
Location: England.
Edited my post.


Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 6:22 pm 
Offline
Knowledgeable
User avatar

Joined: Fri Sep 12, 2008 11:18 pm
Posts: 176
Location: England.
DFA wrote:
tell em its the same =(


Well it isn't. =-p

It won't compile.


Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 6:27 pm 
Offline
Knowledgeable
User avatar

Joined: Fri Sep 12, 2008 11:18 pm
Posts: 176
Location: England.
I'll try it then. :S

Code:
Private Sub Timer_Timer()
    On Error Resume Next
    If optMale.Value = True Then
        Call BitBlt(picpic.hdc, 0, 0, PIC_X, PIC_Y, picSprites.hdc, 0, Int(Class(cmbClass.ListIndex + 1).Sprite) * PIC_Y, SRCCOPY)
    Else
        Call BitBlt(picpic.hdc, 0, 0, PIC_X, PIC_Y, picSprites.hdc, 0, Int(Class(cmbClass.ListIndex + 1).Sprite) * PIC_Y, SRCCOPY)
    End If
End Sub
----------------------------------------------------------------------------------
            n = n + 1

            For i = 1 To Max_Classes
                Class(i).Name = Parse(n)
   
                Class(i).Vital(Vitals.HP) = Val(Parse(n + 1))
                Class(i).Vital(Vitals.MP) = Val(Parse(n + 2))
                Class(i).Vital(Vitals.SP) = Val(Parse(n + 3))
   
                Class(i).Stat(Stats.Strength) = Val(Parse(n + 4))
                Class(i).Stat(Stats.Defense) = Val(Parse(n + 5))
                Class(i).Stat(Stats.SPEED) = Val(Parse(n + 6))
                Class(i).Stat(Stats.Magic) = Val(Parse(n + 7))
                Class(i).Sprite = Val(Parse(n + 8))
               
                n = n + 9
            Next i


Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 6:29 pm 
Offline
Knowledgeable
User avatar

Joined: Fri Sep 12, 2008 11:18 pm
Posts: 176
Location: England.
DFA wrote:
you're full of shit =(


I'll remember that. =-p

Quote:
Microsoft Visual Basic

Compile error:
Method or data member not found


That's what I get.
EDIT: So ya know. ".hdc" is highlighted with that error.


Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 6:32 pm 
Offline
Community Leader
User avatar

Joined: Sun May 28, 2006 10:29 pm
Posts: 1762
Location: Salt Lake City, UT, USA
Google Talk: Darunada@gmail.com
what does it highlight?

_________________
I'm on Facebook! Google Plus LinkedIn My Youtube Channel Send me an email Call me with Skype Check me out on Bitbucket Yup, I'm an EVE Online player!
Why not try my app, ColorEye, on your Android devlce?
Do you like social gaming? Fight it out in Battle Juice!

I am a professional software developer in Salt Lake City, UT.


Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 8:45 pm 
Offline
Knowledgeable
User avatar

Joined: Fri Sep 12, 2008 11:18 pm
Posts: 176
Location: England.
Still no help? :S


Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 9:38 pm 
Offline
Submit-Happy
User avatar

Joined: Fri Jun 16, 2006 7:01 am
Posts: 2768
Location: Yorkshire, UK
GIEV US THAT ACUTLA LINE

_________________
Quote:
Robin:
Why aren't maps and shit loaded up in a dynamic array?
Jacob:
the 4 people that know how are lazy
Robin:
Who are those 4 people?
Jacob:
um
you, me, and 2 others?


Image


Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 9:42 pm 
Offline
Knowledgeable
User avatar

Joined: Fri Sep 12, 2008 11:18 pm
Posts: 176
Location: England.
Robin wrote:
GIEV US THAT ACUTLA LINE


Uh?... :S

BitBlt was removed from MS4. When I add it into modGameLogic.bas, still doesn't work.

Code:
Public Declare Function BitBlt Lib"gdi32" (ByVal hDestDC As Long, ByVal X As Long, ByVal Y As Long, ByVal nWidth As Long, ByVal nHeight As Long, ByVal hSrcDC As Long, ByVal xSrc As Long, ByVal ySrc As Long, ByVal dwRop As Long) As Long


Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 9:52 pm 
Offline
Persistant Poster
User avatar

Joined: Fri Aug 15, 2008 3:11 pm
Posts: 633
well we dont know how to use that part with it
so we tried to add bitblt still dont work
this is very confusing
worked better on ms 3.03

BltToDC dont work for me because i cant arrange it
Ive read the source like robin told me to do and i tried to put it like this
but i know its wrong cause i dont know how to do it
i tired it like this

Call Engine_BltToDC(DD_SpriteSurf, sRECT, dRECT, frmNpcEditor.picSprite)s

_________________
╔╗╔═╦═╦══╦═══╗
║║║║║║║╔╗║╔═╗║
║║║║║║║╚╝║║║║║
║╚╣║║║║╔╗║╚═╝║
╚═╩╩═╩╩╝╚╩═══╝


╔╦═╦╦════╦═══╗
║║║║╠═╗╔═╣╔══╝
║║║║║║║║╚═╗
║║║║║║║║╔═╝
╚═╩═╝╚╝╚╝ ?


Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 10:40 pm 
Offline
Community Leader
User avatar

Joined: Sun May 28, 2006 10:29 pm
Posts: 1762
Location: Salt Lake City, UT, USA
Google Talk: Darunada@gmail.com
Lea please <3

I'm going to rewrite this tutorial for MSE(latest)

So check back in a while for an update. Just undo anything you've done regarding this for now.

_________________
I'm on Facebook! Google Plus LinkedIn My Youtube Channel Send me an email Call me with Skype Check me out on Bitbucket Yup, I'm an EVE Online player!
Why not try my app, ColorEye, on your Android devlce?
Do you like social gaming? Fight it out in Battle Juice!

I am a professional software developer in Salt Lake City, UT.


Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 10:46 pm 
Offline
Knowledgeable
User avatar

Joined: Fri Sep 12, 2008 11:18 pm
Posts: 176
Location: England.
Lea wrote:
Lea please <3

I'm going to rewrite this tutorial for MSE(latest)

So check back in a while for an update. Just undo anything you've done regarding this for now.


Thanks. I got up to "Call Engine_BltToDC(DD_SpriteSurf, sRECT, dRECT, frmNewChar.picSprites)".

Completely failed!


Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 10:46 pm 
Offline
Persistant Poster
User avatar

Joined: Fri Aug 15, 2008 3:11 pm
Posts: 633
thank you
me and matt spent hours trying to make this to work

also can you make it do BltToDC

_________________
╔╗╔═╦═╦══╦═══╗
║║║║║║║╔╗║╔═╗║
║║║║║║║╚╝║║║║║
║╚╣║║║║╔╗║╚═╝║
╚═╩╩═╩╩╝╚╩═══╝


╔╦═╦╦════╦═══╗
║║║║╠═╗╔═╣╔══╝
║║║║║║║║╚═╗
║║║║║║║║╔═╝
╚═╩═╝╚╝╚╝ ?


Top
 Profile  
 
PostPosted: Sat Sep 13, 2008 10:50 pm 
Offline
Knowledgeable
User avatar

Joined: Fri Sep 12, 2008 11:18 pm
Posts: 176
Location: England.
doomteam1 wrote:
thank you
me and matt spent hours trying to make this to work

also can you make it do BltToDC


He is doing that. Since MS4 has that, it doesn't have the other(which is worse).

I spent almost 12 hours trying to get it to work. XD

doom spent maybe 8 hours. =-p(MAYBE)

Again, thanks. I would've learnt more if I wasn't doing 1 thing for 12 hours.


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

All times are UTC


Who is online

Users browsing this forum: No registered users and 16 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:  
Powered by phpBB® Forum Software © phpBB Group