General > Developers Corner

How to make a ULX convar

(1/1)

XxLMM13xX:
Ok so i searched the website for "make convar" and found nothing... how would i make a convar like ulx_votekickSuccessratio

What file would i put this in so i can make a convar like ulx_voterestartSuccessratio

Thanks!

JamminR:
https://github.com/Nayruden/Ulysses/blob/a72cb4dfc6a91c25d53baf7bd59da0f06caa5553/ulx/lua/ulx/base.lua#L21
ulx.convar
You can also search the repo for various convars in our code to find out how we set them.

Aaron113:
I must be blind... I never realized you could search the repository on github until now.

JamminR:
It's a pain to search sometimes because it strips punctuation like periods and other common non-alphanumeric characters, which comprise a huge chunk of variable and function names in almost any code, not just Lua.
But, it's better than trying to find just the needle in the haystack.

Navigation

[0] Message Index

Go to full version