projects
/
carveJwlIkooP6JGAAIwe30JlM.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
fix null reference
[carveJwlIkooP6JGAAIwe30JlM.git]
/
world.c
diff --git
a/world.c
b/world.c
index 4f8cda2f165221c7e18ff4d70ed9fe0a0d1d6f1b..550ac508f0c894a64412a73923fe92cc3289068b 100644
(file)
--- a/
world.c
+++ b/
world.c
@@
-27,7
+27,7
@@
static void world_init(void)
}
static void world_switch_instance( u32 index ){
}
static void world_switch_instance( u32 index ){
-
assert( localplayer.subsystem == k_player_subsystem_walk )
;
+
localplayer.subsystem = k_player_subsystem_walk
;
if( index >= vg_list_size(world_static.instances) ){
vg_error( "Instance ID out of range (%u)\n", index );
if( index >= vg_list_size(world_static.instances) ){
vg_error( "Instance ID out of range (%u)\n", index );
@@
-44,8
+44,11
@@
static void world_switch_instance( u32 index ){
world_instance *current =
&world_static.instances[ world_static.active_instance ];
world_instance *current =
&world_static.instances[ world_static.active_instance ];
- if( index != world_static.active_instance )
+ if( index != world_static.active_instance )
{
v3_copy( localplayer.rb.co, current->player_co );
v3_copy( localplayer.rb.co, current->player_co );
+ skaterift_autosave(1);
+ }
+
v3_copy( new->player_co, localplayer.rb.co );
world_static.active_instance = index;
v3_copy( new->player_co, localplayer.rb.co );
world_static.active_instance = index;