mirror of
https://github.com/scp-fs2open/fs2open.github.com.git
synced 2026-11-09 13:01:29 -10:00
Use change_ship_class rather than straight variable set (this is the proper way)
This commit is contained in:
1 parent
d760c85ae9
commit
a67ab3b802
1 file changed
+2
-1
+2
-1
@@ -4829,7 +4829,8 @@ ADE_VIRTVAR(Class, l_Ship, "shipclass", "Ship class")
|
||||
ship *shipp = &Ships[objh->objp->instance];
|
||||
|
||||
if(ADE_SETTING_VAR && idx > -1)
|
||||
shipp->ship_info_index = idx;
|
||||
change_ship_type(objh->objp->instance, idx, 1);
|
||||
//shipp->ship_info_index = idx;
|
||||
|
||||
if(shipp->ship_info_index < 0)
|
||||
return ade_set_error(L, "o", l_Shipclass.Set(-1));
|
||||
|
||||
Reference in new issue
Block a user