ID:148715
 
I am having a problem with my HUD... Both Leftley and RaeKwon, so far has tried to help but not really solved my problem.

So, here goes.

I have my HUD coded as follows:

obj/HUD
say
layer = MOB_LAYER + 100
icon = 'HUD.dmi'
normal
icon_state = "Say"
Click()
icon_state = "Say Over"
var/T = input("Say")as null|text
if(!T)
return
else
view(6) << "[usr] says: [html_encode(T)]"
sleep(50)
icon_state = "Say"

New(client/C)
screen_loc = "1,1"
C.screen += src


Client/New()
..()
new/obj/HUD/say(src)


I login to my game and the HUD is not displayed at all. Leftley sugesting lowering the MOB_LAYER, so I did. As to my surprise, the problem is still there.

RaeKwon told me that only one Client/New() is aloud in a game. So he asked if I used Deadrons characterhandling as he said that had one. So, in turn. I took out the Client/New() in my coding and embedded the 'new/obj/HUD/say' into Deadrons Client/New(). Still the problem occurs.

So I ask of all who is out there or even one of you who knows anything about HUDs, please, could you lend me a helping hand?

--Lee
Mellifluous wrote:
I am having a problem with my HUD... Both Leftley and RaeKwon, so far has tried to help but not really solved my problem.

So, here goes.

I have my HUD coded as follows:

> obj/HUD
> say
> layer = MOB_LAYER + 100
> icon = 'HUD.dmi'
> normal
> icon_state = "Say"
> Click()
> icon_state = "Say Over"
> var/T = input("Say")as null|text
> if(!T)
> return
> else
> view(6) << "[usr] says: [html_encode(T)]"
> sleep(50)
> icon_state = "Say"
>
> New(client/C)
> screen_loc = "1,1"
> C.screen += src
>
>
> Client/New()
> ..()
> new/obj/HUD/say(src)
>

I login to my game and the HUD is not displayed at all. Leftley sugesting lowering the MOB_LAYER, so I did. As to my surprise, the problem is still there.

RaeKwon told me that only one Client/New() is aloud in a game. So he asked if I used Deadrons characterhandling as he said that had one. So, in turn. I took out the Client/New() in my coding and embedded the 'new/obj/HUD/say' into Deadrons Client/New(). Still the problem occurs.

So I ask of all who is out there or even one of you who knows anything about HUDs, please, could you lend me a helping hand?

--Lee

Try
client
New()
new/obj/whatever(src)
..()


RaeKwon
In response to RaeKwon
Along with the lowercase client, you should also use the /say/normal path since you haven't overridden New() for just /say.

client/New()
new/obj/HUD/say/normal(src)
..()
Mellifluous wrote:
I am having a problem with my HUD... Both Leftley and RaeKwon, so far has tried to help but not really solved my problem.

So, here goes.

I have my HUD coded as follows:

> obj/HUD
> say
> layer = MOB_LAYER + 100
> icon = 'HUD.dmi'
> normal
> icon_state = "Say"
> Click()
> icon_state = "Say Over"
> var/T = input("Say")as null|text
> if(!T)
> return
> else
> view(6) << "[usr] says: [html_encode(T)]"
> sleep(50)
> icon_state = "Say"
>
> New(client/C)
> screen_loc = "1,1"
> C.screen += src
>
>
> Client/New()
> ..()
> new/obj/HUD/say(src)
>

I login to my game and the HUD is not displayed at all. Leftley sugesting lowering the MOB_LAYER, so I did. As to my surprise, the problem is still there.

RaeKwon told me that only one Client/New() is aloud in a game. So he asked if I used Deadrons characterhandling as he said that had one. So, in turn. I took out the Client/New() in my coding and embedded the 'new/obj/HUD/say' into Deadrons Client/New(). Still the problem occurs.

So I ask of all who is out there or even one of you who knows anything about HUDs, please, could you lend me a helping hand?

--Lee


Lee! How could you miss it!

The obj is being added because you have the wrong type, you have a directory after say going normal so it should be,

client/New()
new/obj/HUD/say/normal(src)
..()

That should relieve of problems!
In response to RaeKwon
RaeKwon wrote:
Try
> client
> New()
> new/obj/whatever(src)
> ..()

RaeKwon


Still not working :S
In response to Super16
Super16 wrote:
Mellifluous wrote:
I am having a problem with my HUD... Both Leftley and RaeKwon, so far has tried to help but not really solved my problem.

So, here goes.

I have my HUD coded as follows:

> > obj/HUD
> > say
> > layer = MOB_LAYER + 100
> > icon = 'HUD.dmi'
> > normal
> > icon_state = "Say"
> > Click()
> > icon_state = "Say Over"
> > var/T = input("Say")as null|text
> > if(!T)
> > return
> > else
> > view(6) << "[usr] says: [html_encode(T)]"
> > sleep(50)
> > icon_state = "Say"
> >
> > New(client/C)
> > screen_loc = "1,1"
> > C.screen += src
> >
> >
> > Client/New()
> > ..()
> > new/obj/HUD/say(src)
> >

I login to my game and the HUD is not displayed at all. Leftley sugesting lowering the MOB_LAYER, so I did. As to my surprise, the problem is still there.

RaeKwon told me that only one Client/New() is aloud in a game. So he asked if I used Deadrons characterhandling as he said that had one. So, in turn. I took out the Client/New() in my coding and embedded the 'new/obj/HUD/say' into Deadrons Client/New(). Still the problem occurs.

So I ask of all who is out there or even one of you who knows anything about HUDs, please, could you lend me a helping hand?

--Lee


Lee! How could you miss it!

The obj is being added because you have the wrong type, you have a directory after say going normal so it should be,

client/New()
new/obj/HUD/say/normal(src)
..()

That should relieve of problems!

Oh yea... Stupid me needs a slap!

Thanks Super16! Well, Thanks to everyone!

--Lee