Graal Forums  

Go Back   Graal Forums > Development Forums > NPC Scripting > NPC Server
FAQ Members List Calendar Today's Posts

 
 
Thread Tools Search this Thread Rate Thread Display Modes
  #1  
Old 05-11-2001, 01:30 PM
KJS KJS is offline
The one, The only -
KJS's Avatar
Join Date: Apr 2001
Location: USA, Minnesota
Posts: 1,012
KJS is on a distinguished road
Send a message via AIM to KJS
Thumbs down

I am use setimg function and stuff that make it so it can be a health bar.
But like when I goto a different level then the level with that weapon on it. then it disapears when the guy gets hurt. I am wondering if there is any way around that... Because that makes it look really bad when I reshow it once it disapears (like you can see the whole image then it resizes it).
well basically I am saying when I use showimg
and I get hurt then my images hide and I am wondering if there is a way around that...
__________________
Thanks,
-KJL
  #2  
Old 05-11-2001, 01:35 PM
Cyboars Cyboars is offline
Registered User
Cyboars's Avatar
Join Date: Mar 2001
Location: Everwhere.
Posts: 209
Cyboars will become famous soon enough
Send a message via AIM to Cyboars Send a message via Yahoo to Cyboars
NPC Code:

if (playerishurt) {healthbarscripthere;}
if (playerdies) {healthbarscripthere;}
if (playertouchesother){healthbarscript here;}


that or
NPC Code:

if (weaponfired){healthbarscript;timeout=0.05;}
if (timeout){healthbarscript;}


__________________


Returned to Graal 2/1/02
  #3  
Old 05-11-2001, 01:37 PM
KJS KJS is offline
The one, The only -
KJS's Avatar
Join Date: Apr 2001
Location: USA, Minnesota
Posts: 1,012
KJS is on a distinguished road
Send a message via AIM to KJS
Cool I know

I know I can do that
but I was wondering if like there is a way around that... Like if it is a glitch that they disapear or something when you get hurt?
because when I do it that way it like shows the whole big image again and like looks bad for a few seconds... like it will show the huge image then take a second to resize it again...
__________________
Thanks,
-KJL
  #4  
Old 05-11-2001, 01:49 PM
Cyboars Cyboars is offline
Registered User
Cyboars's Avatar
Join Date: Mar 2001
Location: Everwhere.
Posts: 209
Cyboars will become famous soon enough
Send a message via AIM to Cyboars Send a message via Yahoo to Cyboars
use timeouts, it should work perfectly..it can set your sword to 61(-1) and wont flash or change back, unless you do somthing bad to it.
__________________


Returned to Graal 2/1/02
  #5  
Old 05-11-2001, 01:58 PM
KJS KJS is offline
The one, The only -
KJS's Avatar
Join Date: Apr 2001
Location: USA, Minnesota
Posts: 1,012
KJS is on a distinguished road
Send a message via AIM to KJS
Cool well the thing that happens

the thing that happens is that it has to reload
state.png
(for my timevar)
my timevar also disapears when you get hit...
but for my health bar it works fine pretty much but it blinking...

but like the timevar part is the biggest thing is how it has to reput on state.png and makes it so you see that image like 6 times on the screen then it resizes its self.
__________________
Thanks,
-KJL
  #6  
Old 05-11-2001, 08:32 PM
Admins Admins is offline
Graal Administration
Join Date: Jan 2000
Location: Admins
Posts: 11,693
Admins has much to be proud ofAdmins has much to be proud ofAdmins has much to be proud ofAdmins has much to be proud ofAdmins has much to be proud ofAdmins has much to be proud of
showimgs are automatically hidden
when you are hurt,
you should do the showimg commands
all 0.05 seconds
  #7  
Old 05-11-2001, 08:37 PM
KJS KJS is offline
The one, The only -
KJS's Avatar
Join Date: Apr 2001
Location: USA, Minnesota
Posts: 1,012
KJS is on a distinguished road
Send a message via AIM to KJS
Cool thanks

thank you for all your help you guys...
__________________
Thanks,
-KJL
  #8  
Old 05-12-2001, 11:54 PM
Loriel Loriel is offline
Somewhat rusty
Loriel's Avatar
Join Date: Mar 2001
Posts: 5,059
Loriel is a name known to allLoriel is a name known to allLoriel is a name known to allLoriel is a name known to all
Why are they hidden, Stefan? That sucks....
  #9  
Old 05-16-2001, 11:00 AM
Er1c Er1c is offline
Registered User
Er1c's Avatar
Join Date: Mar 2001
Location: Chicago, IL
Posts: 791
Er1c is on a distinguished road
How to get showimg with layer 4 to work correctly

I had the same problem you do a while back. What is wrong with your script is that the part that shows the images should NOT be in the timeout loop. You still DO need a timeout loop so that the server recognises the NPC, but don't have the showimg part in that loop.
__________________
Eric Kraft
  #10  
Old 05-18-2001, 03:04 AM
TB3 TB3 is offline
Registered User
TB3's Avatar
Join Date: May 2001
Location: US of A State of VA
Posts: 658
TB3 is on a distinguished road
Send a message via Yahoo to TB3
ACK You People Lag Things!

ACK that makes it lag making graal show that image over and over if u know its not going to change unless u are hurt or something do this......

This should work im not sure im doing alot ....

if (playerenters) {this.oldheart=playerhearts;timeout=.5;}

if (timeout) {
if (!playerhearts=this.oldheart) {this.oldheart=playerhearts;this.mode=1}
if (this.mode=1) {yourscripthere;this.mode=0}

timeout=.05;
}
__________________

To the sun of your age, I arise
 


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 10:51 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.