=md2_export.py small fix=
There was an integer division error in md2_export.py, where values were getting clamped to either 0 or 1. Fixed it by putting the appropriate vars in float(). Reported by deltab on IRC.
This commit is contained in:
@@ -1187,8 +1187,8 @@ def build_GL_commands(md2):
|
|||||||
cmd=md2_GL_command()
|
cmd=md2_GL_command()
|
||||||
s=md2.tex_coords[best_st[command_counter]].u
|
s=md2.tex_coords[best_st[command_counter]].u
|
||||||
t=md2.tex_coords[best_st[command_counter]].v
|
t=md2.tex_coords[best_st[command_counter]].v
|
||||||
cmd.s=s/md2.skin_width
|
cmd.s=s/float(md2.skin_width)
|
||||||
cmd.t=t/md2.skin_height
|
cmd.t=t/float(md2.skin_height)
|
||||||
cmd.vert_index=best_verts[command_counter]
|
cmd.vert_index=best_verts[command_counter]
|
||||||
num_commands+=3
|
num_commands+=3
|
||||||
cmd_list.cmd_list.append(cmd)
|
cmd_list.cmd_list.append(cmd)
|
||||||
|
|||||||
Reference in New Issue
Block a user