Ulysses Stuff > General Chat & Help and Support

Server Gravity

(1/1)

darkdeath:
ok i made up alot of configurations in your mod.
but now i am currently wan't to set up gravity!
ive got a new menu like this:

--- Quote ---1client
2admin
3map
4weapons
5client limits
6other

0quit

--- End quote ---
i have in other
some gravity settings but...
it must always be 0. (i found out) like this example below:

--- Quote ---      if _GetConVar_Bool( "sv_gravity" ) then
         addOption( userid, "Very Hig Gravity Off", "sv_gravity 0", ACCESS_CVAR )   
      else
         addOption( userid, "Very Hig Gravity On", "sv_gravity 1200", ACCESS_CVAR )   
      end
--- End quote ---
as u can see "sv_gravity 0" the gravity is 0 becouse otherwise it won't work if u make it 600 of it then it won't work. But if u match it with the text what i wan't it to be it won't fit :P... if u adjust 0 to 600 then the text will be correct!

AND MY QUESTION IS WHY it always have to be 0?
AND HOW TO CHANGE IT ?

Megiddo:

--- Code: ---if _GetConVar_Bool( "sv_gravity" ) then
--- End code ---

You're checking if it's 0

darkdeath:
so when i say this:

--- Quote ---      if _GetConVar_Bool( "sv_gravity 600" ) then
         addOption( userid, "Very Hig Gravity Off", "sv_gravity 600", ACCESS_CVAR )   
      else
         addOption( userid, "Very Hig Gravity On", "sv_gravity 1200", ACCESS_CVAR )   
      end
--- End quote ---
it should work ?

Megiddo:

--- Code: ---      if _GetConVar_Float( "sv_gravity" ) == 1200 then
         addOption( userid, "Very Hig Gravity Off", "sv_gravity 600", ACCESS_CVAR )   
      else
         addOption( userid, "Very Hig Gravity On", "sv_gravity 1200", ACCESS_CVAR )   
      end

--- End code ---

darkdeath:
thank u alot :)  ;D
i LOVE YOU :) (no just kidding)

Navigation

[0] Message Index

Go to full version