Forum

> > Stranded II > Scripts > how to make objects loadmap
Forums overviewStranded II overview Scripts overviewLog in to reply

English how to make objects loadmap

7 replies
To the start Previous 1 Next To the start

old how to make objects loadmap

Jawohl
User Off Offline

Quote
iv been trying to make a script that when you press E (or action button) on a object/unit so that it then loads to another map, well im having truble with the whole thing... please help me...

old Re: how to make objects loadmap

HudaJan
Super User Off Offline

Quote
loadmap 1,1,1,1;

or paly along with the numbers, but if you want only to keep your items, replace 1s with 0s except for the second 1

old Re: how to make objects loadmap

Jawohl
User Off Offline

Quote
user HudaJan has written
loadmap 1,1,1,1;

or paly along with the numbers, but if you want only to keep your items, replace 1s with 0s except for the second 1


thankyou a heap hudjan...

ok one more thing (last one i promise)
how do i make a script so when my character goes off a spesific map side that map loads a spesific map

old Re: how to make objects loadmap

HudaJan
Super User Off Offline

Quote
Not sure if I understand you properly, you mean if the player leaves the island in one direction, it would load different map, than if he leaves in other direction?

old Re: how to make objects loadmap

Jawohl
User Off Offline

Quote
yes basicly, north goes to Map1, south goes to Map2, east goes to Map3, west goes to Map4 however the corners dont load anything... but if you are in a corner
it loads the boundry your closest too...

old Re: how to make objects loadmap

DC
Admin Off Offline

Quote
you have to check the coordinates of the player.

untested
1
2
3
4
if (getx("unit",1)<0) { loadmap ...; }
if (getz("unit",1)<0) { loadmap ...; }
if (getx("unit",1)>mapsize()) { loadmap ...; }
if (getz("unit",1)>mapsize()) { loadmap ...; }

you probably have to multiply mapsize() with some value to make it work properly. I'm not sure. don't want to try it. or you could simply test it (print the return values of getx and getz to the console when reaching the end of the map) and insert these values instead of mapsize()
To the start Previous 1 Next To the start
Log in to reply Scripts overviewStranded II overviewForums overview