Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Discussion / health HUD

Author
Message
ClearCoder
22
Years of Service
User Offline
Joined: 27th Feb 2003
Location: United Kingdom
Posted: 30th Jun 2003 16:23
is there any way in DB classic to make the hud do stuff like in real games when like the health you are on is flashing or getting big and small.

thx crystal

p.s. i through i would use red crosses to symbolise health any comments
Newbie Now; Expert Later
Current project:The Sorus
http://us.f1.yahoofs.com/users/8e2ce249/bc/logo.jpg?bc6XVw.ALSzFxXyM[/img]
John H
Retired Moderator
22
Years of Service
User Offline
Joined: 14th Oct 2002
Location: Burlington, VT
Posted: 30th Jun 2003 17:14
Very Possible. Just have a health sprite that you can stretch for health. If health<whatever then load in 2 new sprites and just switch between them for a flashing effect.

RPGamer

Current Project: Eternal Destiny
Questions? Comments? Suggestions? Go to the Eternal Destiny Forum!
Furiousuk
22
Years of Service
User Offline
Joined: 10th Jan 2003
Location: United Kingdom
Posted: 30th Jun 2003 17:15
Of course you can do this. DarkBASIC is really very flexible. Just update the image you are using for the health portion of your HUD, if you want it to flash when beneath a certain health level then you could use a subroutine like this (this would also work as part of a function to display your HUD) :

ClearCoder
22
Years of Service
User Offline
Joined: 27th Feb 2003
Location: United Kingdom
Posted: 30th Jun 2003 18:55
thank so far is there any way to hide a bit of a sprite and my sprite at the moment slows the game down by a lot of FPS why is that

Newbie Now; Expert Later
Current project:The Sorus
Blanka
22
Years of Service
User Offline
Joined: 26th Feb 2003
Location: United Kingdom
Posted: 1st Jul 2003 03:08
easier way. just draw a line from two points
eg

from 0-100 = full health (green bar)
from 0-75 = less heath (orange bar)
from 0-50 = low health (yellow bar)
from 0-10 = critical (red bar)

and no external media

Login to post a reply

Server time is: 2025-05-19 04:04:30
Your offset time is: 2025-05-19 04:04:30