Thread Rating:
  • 1 Vote(s) - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Menu Problems Halp
#1
Basically, I have a shoutcast overlay i want to reduce in size pending on what the DVAR ui_shoutcast_ax20 is set to... so it looks like this..

ITEM DEF

#define Shoutcast_text(dvar, height, dvarint) \
itemDef \
{ \
name "shoutcast_text" \
type ITEM_TYPE_TEXT \
rect SHOUTCAST_X height dvarint 19 HORIZONTAL_ALIGN_LEFT VERTICAL_ALIGN_TOP \
exp text( dvarstring( dvar ) ); \
textfont UI_FONT_DEFAULT \
textscale 0.25 \
textalign ITEM_ALIGN_MIDDLE_LEFT \
textstyle ITEM_TEXTSTYLE_SHADOWED \
style WINDOW_STYLE_FILLED \
visible when( dvarInt( "shoutlol" ) == 1 && dvarString(dvar) != "" ) \
forecolor 1 1 1 1 \
backcolor 0 0.2412 0 0.4975 \
border 1 \
bordersize 1 \
bordercolor CHOICE_BUTTON_BORDER_COLOR_UNSELECTED_RGBA \
}



ACTUAL ITEM

#undef SHOUTCAST_X
#define SHOUTCAST_X 10
Shoutcast_text("ui_shoutcast_ax0", 140, "ui_shoutcast_ax20")





It comes up with the following error though..


Menu load error: ui_mp/hud_spectator.menu, line 218: expected float but found ui_shoutcast_ax20

Menu load error: ui_mp/hud_spectator.menu, line 218: couldn't parse menu item keyword rect
Menu load error: ui_mp/hud_spectator.menu, line 218: couldn't parse menu keyword itemDef








If i change the dvar just to a number, it works, just wondering if there is a way around this at all?
Reply

#2
Does the height var work? try (dvar)
[Image: MaEIQ.png]
Reply

#3
nah doesnt matter thats just the variable name i think
Reply

#4
i liked the "halp" Troll
Reply

#5
we need a fuck off button next to the thank you button..
Reply

#6
met helped me out, nm guise.
Reply

#7
rect SHOUTCAST_X ( dvarInt ( height ) ) ( dvarInt ( dvarint) ) 19 HORIZONTAL_ALIGN_LEFT VERTICAL_ALIGN_TOP \

??
(08-10-2011, 12:58)Pozzuh Wrote:
Se7en Wrote:Stealed, from cod4 mod ...
look who's talking

[Release] Old School Mod v2.2
[Release] Scroll menu

Reply

#8
#define Shoutcast_text(dvar1, height1, dvarint1) \
itemDef \
{ \
name "shoutcast_text" \
type ITEM_TYPE_TEXT \
rect SHOUTCAST_X height1 0 16 HORIZONTAL_ALIGN_LEFT VERTICAL_ALIGN_TOP \
exp text( dvarstring( dvar1 ) ) \
exp rect W(dvarstring( dvarint1 )) \
textfont UI_FONT_DEFAULT \
textscale 0.18 \
textalign ITEM_ALIGN_MIDDLE_LEFT \
textstyle ITEM_TEXTSTYLE_SHADOWED \
style WINDOW_STYLE_FILLED \
visible when( dvarInt( "shoutlol" ) == 1 && dvarString(dvar1) != "" ) \
forecolor 1 1 1 1 \
backcolor 0 0.1512 0 0.6975 \
border 1 \
bordersize 1 \
bordercolor CHOICE_BUTTON_BORDER_COLOR_UNSELECTED_RGBA \
}



is right code
Reply



Possibly Related Threads…
Thread Author Replies Views Last Post
Question Help Admin menu koren30 4 5,159 10-07-2013, 20:17
Last Post: Yamato
  [Tutorial] How-To, Mod menu picture-REVISED/no iwifix needed rotceh_dnih 52 32,561 09-28-2013, 02:08
Last Post: Monkey Arms
  Help How do I open the admin menu for GeKKos QS Mod? conorr 1 3,103 08-15-2013, 13:52
Last Post: Yamato
  Trying to compile a modified menu DidUknowiPwn 7 5,745 07-05-2013, 21:55
Last Post: DidUknowiPwn
  Preview Admin / Mod Menu Hologramm 5 7,055 05-29-2013, 00:35
Last Post: sleepunknot
  Map Menu in Black Ops 1 EliTeEishiii 2 3,074 04-21-2013, 18:54
Last Post: Nekochan
  Menu base EliTeEishiii 1 2,897 04-17-2013, 16:10
Last Post: Nekochan
Rainbow [Release] [Contest] Scroll Menu iAegle 49 37,094 03-21-2013, 07:30
Last Post: jermC
  [Release] Mouse operated menu met94 18 13,812 03-06-2013, 10:27
Last Post: BHF98
  [Release] BO Simplest Admin Menu alistair3149 21 17,384 02-22-2013, 08:57
Last Post: ItsEffecT

Forum Jump:


Users browsing this thread:
1 Guest(s)

Forum Powered By MyBB, Theme by © 2002-2024 Melroy van den Berg.