vbGore Free Online RPG Engine

Revolutionizing Visual Basic ORPG Development
It is currently Mon May 20, 2013 2:00 pm

All times are UTC - 8 hours




Post new topic Reply to topic  [ 12 posts ] 
Author Message
 Post subject: Problem with Status Window
PostPosted: Thu Feb 05, 2009 12:57 am 
Lucky Number 7

Joined: Thu Feb 05, 2009 12:53 am
Posts: 7
Hi, i've done the Tutorial for the Status Window and now i tryed to add the playername and lvl but it dont work. Can any 1 plz help? I got everytime Variable not declared error -.-'. and how can i let them show my Lvl after the Char name?

my code so far:
Code:
        Case StatusWindow
            With GameWindow.Status
       

                Engine_Render_Grh .SkinGrh, .Screen.X, .Screen.Y, 0, 1, True, GUIColorValue, GUIColorValue, GUIColorValue, GUIColorValue
               
               
'### NAME & LVL ANZEIGE ###
                Engine_Render_Text , CharList(CharIndex).Name, .Screen.X + 10, .Screen.Y + 14, -1
'### LEBEN LEISTE ###
                Engine_Render_Rectangle .Screen.X + 40, .Screen.Y + 30, (BaseStats(SID.MinHP) / ModStats(SID.MaxHP)) * 141, 11, 1, 1, 1, 1, 1, 1, 0, 0, 1, -2818048, -2818048, -2818048, 0, False
                Engine_Render_Text Font_Default, BaseStats(SID.MinHP) & "/" & ModStats(SID.MaxHP), .Screen.X + 46, .Screen.Y + 28, D3DColorARGB(255, 0, 0, 0)
                Engine_Render_Text Font_Default, "HP:", .Screen.X + 10, .Screen.Y + 28, -1
'### MANA LEISTE ###
                Engine_Render_Rectangle .Screen.X + 40, .Screen.Y + 46, (BaseStats(SID.MinMAN) / ModStats(SID.MaxMAN)) * 141, 11, 1, 1, 1, 1, 1, 1, 0, 0, 1, -16776961, -16776961, -16776961, 0, False
                Engine_Render_Text Font_Default, BaseStats(SID.MinMAN) & "/" & ModStats(SID.MaxMAN), .Screen.X + 46, .Screen.Y + 44, D3DColorARGB(255, 0, 0, 0)
                Engine_Render_Text Font_Default, "MP:", .Screen.X + 10, .Screen.Y + 44, -1
'### ERFAHRUNGS LEISTE ###
                Engine_Render_Rectangle .Screen.X + 40, .Screen.Y + 62, (BaseStats(SID.EXP) / BaseStats(SID.ELU)) * 141, 11, 1, 1, 1, 1, 1, 1, 0, 0, 1, -200, -200, -200, 0, False
                Engine_Render_Text Font_Default, BaseStats(SID.EXP) & "/" & BaseStats(SID.ELU), .Screen.X + 46, .Screen.Y + 60, D3DColorARGB(255, 0, 0, 0)
                Engine_Render_Text Font_Default, "EXP:", .Screen.X + 10, .Screen.Y + 60, -1
      End With



Top
 Profile  
 
 Post subject: Re: Problem with Status Window
PostPosted: Thu Feb 05, 2009 1:08 am 
Slave to the BB

Joined: Sat May 12, 2007 6:20 am
Posts: 3842
Location: Behind you!
Replace:
Code:
Engine_Render_Text , CharList(CharIndex).Name, .Screen.X + 10, .Screen.Y + 14, -1

With:
Code:
Engine_Render_Text Font_Default, CharList(CharIndex).Name, Screen.X + 10, .Screen.Y + 14, -1


Last edited by notexistant on Thu Feb 05, 2009 1:22 am, edited 1 time in total.

Top
 Profile  
 
 Post subject: Re: Problem with Status Window
PostPosted: Thu Feb 05, 2009 1:11 am 
Lucky Number 7

Joined: Thu Feb 05, 2009 12:53 am
Posts: 7
I've done this but i get still the "Variable not Defined" Error :(


Top
 Profile  
 
 Post subject: Re: Problem with Status Window
PostPosted: Thu Feb 05, 2009 1:12 am 
Slave to the BB

Joined: Sat May 12, 2007 6:20 am
Posts: 3842
Location: Behind you!
Run the client in vb6 and tell us what variable it says is not defined.


Top
 Profile  
 
 Post subject: Re: Problem with Status Window
PostPosted: Thu Feb 05, 2009 1:14 am 
Bit Baby

Joined: Tue Sep 02, 2008 12:33 pm
Posts: 382
Location: United Kingdom
Well since you want level as well, just use something like this to display both:

Code:
Engine_Render_Text Font_Default, "Name: " & UserName & " Level: " & BaseStats(SID.ELV), .Screen.X + 10, .Screen.Y + 14, -1


Hope this helps :)


Top
 Profile  
 
 Post subject: Re: Problem with Status Window
PostPosted: Thu Feb 05, 2009 1:16 am 
Lucky Number 7

Joined: Thu Feb 05, 2009 12:53 am
Posts: 7
THX DarkSummon, this worked :D

do u know why my mousewheel not more work in vb6?


Top
 Profile  
 
 Post subject: Re: Problem with Status Window
PostPosted: Thu Feb 05, 2009 1:17 am 
Slave to the BB

Joined: Sat May 12, 2007 6:20 am
Posts: 3842
Location: Behind you!
Chain wrote:
THX DarkSummon, this worked :D

do u know why my mousewheel not more work in vb6?



Never has...

BTW your original problem was that you used CharIndex instead of UserCharIndex and you forgot to put Font_Default.


Top
 Profile  
 
 Post subject: Re: Problem with Status Window
PostPosted: Thu Feb 05, 2009 1:28 am 
Bit Baby

Joined: Tue Sep 02, 2008 12:33 pm
Posts: 382
Location: United Kingdom
No Probs Chain :)

In the VB6 IDE your scroll wheel wont work (yes i know, a very annoying feature ^^). What i do is just run a small app before i develop with VB6, which is called:
VB6ScrollwheelFix

Which you can get here:
http://tinyurl.com/ceb5vb

Happy coding ^^


Top
 Profile  
 
 Post subject: Re: Problem with Status Window
PostPosted: Thu Feb 05, 2009 1:29 am 
Lucky Number 7

Joined: Thu Feb 05, 2009 12:53 am
Posts: 7
notexistant wrote:
Chain wrote:
THX DarkSummon, this worked :D

do u know why my mousewheel not more work in vb6?



Never has...

BTW your original problem was that you used CharIndex instead of UserCharIndex and you forgot to put Font_Default.


thx, now i know it and dont do it again ;D


Top
 Profile  
 
 Post subject: Re: Problem with Status Window
PostPosted: Thu Feb 05, 2009 2:10 am 
Slave to the BB

Joined: Sat May 12, 2007 6:20 am
Posts: 3842
Location: Behind you!
:P np


Top
 Profile  
 
 Post subject: Re: Problem with Status Window
PostPosted: Thu Feb 05, 2009 10:06 am 
Aleron Coder

Joined: Fri Jan 05, 2007 5:36 am
Posts: 2964
Location: Germany
DarkSummon wrote:
No Probs Chain :)

In the VB6 IDE your scroll wheel wont work (yes i know, a very annoying feature ^^). What i do is just run a small app before i develop with VB6, which is called:
VB6ScrollwheelFix

Which you can get here:
http://tinyurl.com/ceb5vb

Happy coding ^^

theres a fix? i love you xD


Top
 Profile  
 
 Post subject: Re: Problem with Status Window
PostPosted: Thu Feb 05, 2009 10:38 am 
Bit Baby

Joined: Tue Sep 02, 2008 12:33 pm
Posts: 382
Location: United Kingdom
Zanval wrote:
DarkSummon wrote:
No Probs Chain :)

In the VB6 IDE your scroll wheel wont work (yes i know, a very annoying feature ^^). What i do is just run a small app before i develop with VB6, which is called:
VB6ScrollwheelFix

Which you can get here:
http://tinyurl.com/ceb5vb

Happy coding ^^

theres a fix? i love you xD


haha your welcome ^^


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 12 posts ] 

All times are UTC - 8 hours


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

Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group