Page 1 of 1
2 quick questions
Posted: Thu Apr 29, 2004 12:24 am
by fuhrer
1)
im using mohradiant and im missing textures in breakthrough, how can i rectify that?
2)
and when i use iprintln and i use a number with decimals i.e. "3.555 " how can i make it only print the number before the decimals?
i tried using int after reading the references but it only prints 0
Posted: Thu Apr 29, 2004 2:10 am
by blue60007
Well I don't know if BT textures show in radiant, I think they do work in the SH SDK though...
well the 3.555 is a float. Are you using a number or printing a variable? For numbers you can do:
for variables (and Im not sure):
Code: Select all
iprintln (int "level.yourvariable") "Blah"
not sure if that will work, but give it a try.
int
Posted: Thu Apr 29, 2004 2:14 am
by tltrude
This is how you do the integer thing.
(int(3.555)) = 3
If you are using a variable for the 3.555, make sure it is that number by using "iprintln (level.number)" because the integer of 0 is 0.
I don't understand #1.
Posted: Thu Apr 29, 2004 2:18 am
by blue60007
ah, but what about casting a variable? Like I did it?
Um I think he means the bt textures are not showing in radiant?

bt
Posted: Thu Apr 29, 2004 2:29 am
by tltrude
If you made a map with the SDK and then moved it to MOHradiant, the textures from SH and BT will not show up because the path to the textures has changed.
Posted: Thu Apr 29, 2004 3:28 am
by lizardkid
well, MOHScript is based of C++/Java/Basic so it stands to reason....
iprintln ("float level.myvariable")
(i almost put printf!!!)
because int (integer) is used for whole numbers and negatives. oh wait, i tested on this, ahah, i fogot it.
i wish someone would post a sticky on what subsets of real numbers (think Algebra people) variables take.
Posted: Thu Apr 29, 2004 5:39 am
by fuhrer
i made the map purely in mohradiant not spearhead sdk, and he i loaded the map in bt some of the textures loaded funny..
as for the print thing i was using
if the speed was at 3.555 it would print that i just need the 3
tltrude i tried what u said it prints 0
Posted: Thu Apr 29, 2004 5:40 am
by fuhrer
i made the map purely in mohradiant not spearhead sdk, and he i loaded the map in bt some of the textures loaded funny..
as for the print thing i was using
if the speed was at 3.555 it would print that i just need the 3
tltrude i tried what u said it prints 0
speed
Posted: Thu Apr 29, 2004 7:18 pm
by tltrude
If this line prints 0, it is because level.speed is 0 (or less than 1) and not 3.555.
iprintln "speed: " (int(level.speed))
Try this.
level.speed1 = 3.555
iprintln "speed1: " (int(level.speed1))
"level.speed" is probably not a good variable name because "speed" is a command word.