cvarTest



cvarTest works like ownerdrawflag.
It is used to display items only when a certain condition is met.

example: an item that shows only for unranked games (instagib or practice)
itemDef{
visible 1
rect 300 200 100 100
text "This is an unranked match"
cvarTest "sv_ranked"
showCvar {"0"} // 1=ranked match, 0 = unranked
}

As you can see, you also need showCvar. It indicates what value of the variable makes the item show. In the example the item only shows if "ranked" is false.


For a list of cvars go to http://www.holysh1t.net/quake-live-commands-list/

0 comments: