Forum

> > Stranded II > General > how to add new animal,building,and item
Forums overviewStranded II overviewGeneral overviewLog in to reply

English how to add new animal,building,and item

20 replies
Page
To the start Previous 1 2 Next To the start

old how to add new animal,building,and item

joekirei
User Off Offline

Quote
im sorry if my english bad

i newbe in script stranded programing, i so confuse to add new animal, building and item in my stranded game, i have been download all model pack in this forum from all user,, example i have new animal, and building model, like deer, car, chair, zombie, and many more,, and in that model folder i always found notepad who has word " enjoy scripting ",, Please help me to add new models in stranded,, because i wanted to have more great animal, building and item in my game,

old Re: how to add new animal,building,and item

Assassin moder
User Off Offline

Quote
First place the .b3d or .3ds or .ms3d or .x file to gfx folder with icon .bmp
Next open sys folder and you see .inf files where add scripts and units etc.
Open units.inf or another .inf file for the add units,object,item
Here is models .inf files:
object_[class].inf - For all objects in game
units_[class].inf - For all Units in game
items_[class].inf - For all items in game

To add item,unit,object You can use this

>For unit!

∗###
id=          -Id of unit must be next from the latest
name=          -name of unit
group=          -group of unit
icon=gfx\.bmp     -icon of unit (default it in the gfx directory)
model=gfx\.b3d     -model of unit (default is gfx directory)
scale=          -scale of model
colxr=          -colision x
colyr=          -colision y
behaviour=     -behaviour of unit (normal, animal, fish, aircraft, watercraft, predatorfish, bird, landskybird, raptor, shy etc)
health=          -health of unit
speed=          -speed of unit
eyes=          -eyes? I don't know what is going on with it
turnspeed=     -turn speed of unit
attackrange=     -range of attack of unit
damage=     -damage causes for player
ani_idle1=     -animations idle 1-3
ani_move=     -animation when unit move
ani_die=          -animation when unit die
ani_attack=     -animation when unit attack player
sfx=          -sound pack (default .inf file in sfx directory)
rideoffset=     -when player ride on unit this set player y position
acceleration=     -acceleration when ride on unit
maxdepth=     -maximum of depth
loot=          -what unit drop (loot=ID,Amount)
script=start     -start script of unit
          -yours script
script=end     -end of script

I make for objects and items next day.

I tried help you!

old Re: how to add new animal,building,and item

joekirei
User Off Offline

Quote
thanks for your guide assasin, but i not understand to give value in that unit option


∗###
id= ??
name= ??
group= ??
icon=gfx\.bmp ??
model=gfx\.b3d ??
scale= ??
colxr= ??
colyr= ??
behaviour= ??
health= ??
speed= ??
eyes= ??
turnspeed= ??
attackrange= ??
damage= ??
ani_idle1= ??
ani_move= ??
ani_die= ??
ani_attack= ??
sfx= ??
rideoffset= ??
acceleration= ??
maxdepth= ??
loot= ??
script=start ??
-yours script ( What Script?? in this row )
script=end

however, please give example all of this value, example for animal like deer unit,,,,

ijm sorry i very blind of that script,
oh yeah thanks before for assasin and lion for reply my post, i very like all created model of you both,

old Re: how to add new animal,building,and item

Lion_Hearted
User Off Offline

Quote
First of all, what is your own language, I know how to read several languages and I might be able to explain this to you in your own language via PMs.

Secondly...

Here's my Deer script that I used in my mod, I'm going to just use it to explain certain things.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
### Deer
id=46
name=Deer
group=animal
icon=gfx\Lion_Hearted\Animals\Deer.bmp
model=gfx\Lion_Hearted\Animals\Deer.b3d
scale=0.7
behaviour=shy
health=100
speed=1.3
turnspeed=1
eyes=10
colxr=12
colyr=18
ani_idle1=31,47,0.1
ani_move=5,29,2
ani_die=47,95,0.8
loot=215,3
script=start

	//Kill
	on:kill {
		event "iskill_hunt","global";
			local $id,$x,$z;
			$x=getx("self");
			$z=getz("self");
			$id=create("object",227,$x,$z);
	}
script=end
loot=9,2
loot=96,1

That is the original code, now, I'm going to explain it... everything you see with // to the left of the text means I'm explaining it.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
### Deer
// The ### means that this is just a note to tell you what there is in the following script, this makes no difference in-game that I'm aware of. Its very possible that I'm wrong on this... When you add ### infront of something, the game ignores anything after the # sign.
id=46
// Id numbers are important in stranded 2, no unit or item, or object can have the same ID number, combination can have the same ID name, but that is prone to problems. Usually you would want to keep your IDs orderly, starting with ID number 2, and going from there... The player already uses ID number 1, and most likely there are animals that use ID 2. Make sure you do not have to animals, or objects or items with the same ID number, ever.
name=Deer
// This is the official name, this is the name that you will see ingame.
group=animal
// Groups are used in the editor and it making maps.
icon=gfx\Lion_Hearted\Animals\Deer.bmp
// This is where the icon graphic can be found, you have to tell the computer where to find the graphics to run, icon graphics are by default meant to be 40 by 40 pixels.
model=gfx\Lion_Hearted\Animals\Deer.b3d
// This is where the 3D model is found, same as the icon, you have to tell it where the model is. Note that when your playing around with units, you have to have animation codes, and stranded 2 as far as I know only accepts b3d animation, so you cannot use 3ds in the units, however 3ds works in the items, and the objects without problem.
scale=0.7
//This is the size of the model, often of my models I have to scale them up so that they appear right ingame. You want something to appear bigger ingame? Make this number larger, wanna make it smaller, make this number smaller.
behaviour=shy
//This is the behavior of the animal, shy means that it will run away from you should you approach it. On the other hand, raptor means that the animal will chase you and in the end try to kill you.
health=100
// Health is the amount of life an animal has, the higher this number goes, the longer it will take for you to kill the animal. The lower this number goes, the shorter the time it will take for you to kill the animal.
speed=1.3
// This is the speed of the animal, when it walks, it walks at a certain speed, if you want your animal to go faster, then increase this number, if you want it to go slower, then lower this number.
turnspeed=1
// This is the speed at which the animal turns, meaning. This is the speed that it take for it to turn around and start heading in a completely different direction. If you want to make the animal slow in turning around, lower this number, if you want to make it faster in turning around, raise this number.
eyes=10
// This is where the animals sees things, the higher the number, the higher off the ground is the view range of the animal.
colxr=12
// This is the collision radius of width. All animals have this command, the collision radius is necessary for arrows and other projectiles to hit the animal. Increase this number to make the animal easier to hit on the width angle.
colyr=18
// This is the collision radius of height. All animals have this command, the collision radius is necessary for arrows and other projectiles to hit the animal. Increase this number to make the animal easier to hit on the height angle.
ani_idle1=31,47,0.1
// This is an animation code. The name details what kind of animation it is, with it is a walking animation, a death animation, or an idle animation. The numbers after the = sign are separated by , there are three numbers. The first one is the starting frame, the second one is the stopping frame, and the third one is the speed at which the game processes the frames. You won't be playing with this until you learn how to animate most likely. This is the same explanation for the next three code lines.
ani_move=5,29,2
ani_die=47,95,0.8
loot=215,3
// Loot is what the animal drops on its death. The first number after the = sign is the ID of the item its supposed to drop, the second one is the number of items its supposed to drop. The loot command has to be repeated for every new item id.
script=start
// This signifies that there is supposed to be a script here. Scripts can do multiple things, to learn how to script, I recommend trying to understand some basic scripts, such as the eating script, (found in "items_edible.inf) you will learn how to make scripts by observing other scripts.

	//Kill
// This //Kill script is actually just a comment on what the following script is doing.
	on:kill {
// This starts up a script that happens only when you kill the animal. The bracket at the end of the command signifies that everything between the two brackets, (Opening and closing) pertains to this line of code.
		event "iskill_hunt","global";
// This is where you earn one hunting skill point every time you kill an animal.	
		local $id,$x,$z;
// This creates local variables, the variable names always has to start with $. And the variable names are separated by , . Local variables do not mess with other items or objects in the game, they are specific only to the object that they were activated in.
			$x=getx("self");
//This assigns the $x variable a value based on the x location of the animal.
			$z=getz("self");
//This assigns the $z variable a value based on the z location of the animal.
			$id=create("object",227,$x,$z);
//This makes the local variable $id, creating an object, with the id number 227, at the location of $x and $z.
	}
//This is the closing bracket that was opened on the "on:kill {" code. This signifies that everything that is supposed to happen on the death of the animal has happened.
script=end
//This means that the script has ended, and there is no more scripting for this unit.
loot=9,2
loot=96,1
// See the loot explanation above.



Now, I'm not a perfect scripter, and if someone else notices a flaw in my explanation please tell me. But that is a complete explanation of what my Deer script does.

Any further questions?

old Re: how to add new animal,building,and item

joekirei
User Off Offline

Quote
wow great,thanks aloot lion thats work, thats explainded i wanted and very helpfull to me,,

my own language is indonesia,,

hmmmm,, i have more question lion, can i place That Deer Unit into Adventure game,, we know only turtle, crab, butterfly, lion, fish, monkey, and many bird in that adventure game, and how can i added your model made, like standing plant tray, table, chair, cooking split, forge,and many your model made into my adventure game too, because thats model very usefull and make my game more realistic, , please give me your own script for that's all model, for now i trying learned script from you

i hope i can find more animal and buildings in that adventure,,
edited 1×, last 06.06.11 09:54:04 am

old Re: how to add new animal,building,and item

Lion_Hearted
User Off Offline

Quote
To add the deer to the adventure mode, your going to have to use the editor, the editor is pretty much self explanitory. A little tweaking around with it, and you'll learn all the interface options. To load the adventure map (Make sure you have a backup) go to the top left of the screen inside of the editor, and click the load map button, load a map inside the adventure folder, you're probably wanting map 2.




Double clicking on units, plants, objects, items, infos all give you different options.

As for placing the deer in your game, your going to want to use this script instead of the last script I gave you.

The last script required several models and items that you almost definitely don't have in your mod.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
### Deer
id=46
name=Deer
group=animal
icon=gfx\Lion_Hearted\Animals\Deer.bmp
model=gfx\Lion_Hearted\Animals\Deer.b3d
scale=0.7
behaviour=shy
health=100
speed=1.3
turnspeed=1
eyes=10
colxr=12
colyr=18
ani_idle1=31,47,0.1
ani_move=5,29,2
ani_die=47,95,0.8
script=start

	//Kill
	on:kill {
		event "iskill_hunt","global";
	}
script=end
loot=9,2
loot=96,1

And of course, make sure the graphics are exactly where the script says they are, or change the script to say they're somewhere else.


I do not make scripts for all my models, I have not make a script yet for the forge, the standing plant tray, chair, table, and many other models I've uploaded.

However, if you want to learn how to script, may I suggest implementing this tree to your game. look at the other tree scripts, and basically you could probably copy them, changing only a few ID numbers and of course the graphics path.

http://www.unrealsoftware.de/files_show.php?file=2692

Notice, that your going to have to use the "scale" command on your model...


That would be an easy way to start out.

Use the editor to check on your new tree, to see if its how you want it.

After that, come back to me, and I'll teach you how to added it to all the random maps.

old Re: how to add new animal,building,and item

joekirei
User Off Offline

Quote
wow,, your'e master,, i wanted that explained,, now i understand to add deer or other models in adventure mode,, thankss lion

well, if you dont know to use forge and other your uploaded, its bad, because i very like your model , and i hope to add chair, table, forge and all your model in my adventure mode

however,, in adventure mode i dont know how to go to maps 2, i always play in maps 1 , i try to swim for long time, but i dont found other island,,

random island?? what use? i never play game random island and survival mode

please teach me how to use mod(i dont know the name mod or patch),because i read in my downloaded mods,
like " fixed more z buffer errors ", " massive mods " ( i know thats fixed more bugs in game, but i dont know how to use,, give me explained master lion ,

old Re: how to add new animal,building,and item

Lion_Hearted
User Off Offline

Quote
Lol, I doubt I'm master


But anyways...


Its not that I don't know how to use the forge and other objects... I do know how to use them, I just haven't added them to my mod, and therefore, I haven't made a script yet that allows them to function correctly...

I have made the script for the spits, perhaps you should download my mod to see how they function, the link is in my signature, to install the mod, just put the Lion_Hearted folder in the gfx folder in the mod folder, and overwrite the original sys with the new sys in the download. Be sure to create a backup of your game though, just incase you don't like the new one.

In my mod, you'll have to play the random island, as I haven't yet made an adventure for my game.

In the original adventure mode, you have to build, take a stone, and a stick, combine them, and build things. Once you finish building the hut, you'll find a lock pick. Take that lockpick down to the box that you weren't able to open, the box is located right beside what to me always was called Turtle island, turtle island has a rock that holds water in the middle, and turtles love to spawn around there.

Use the lockpick to open that box, then just follow instructions from there.

As for massive mod, I don't know much about it, I played it, but that was a long time ago. As for stranded 2.5 mod, I can't play it because the maker of the mod edited the source code and I can't load in for some reason on my new computer.

I don't know much about the other mods either...


Whenever you get tired of playing the adventure mode, you can always play the random island mode, in this mode the island is always randomly generated, and its basically survival. Building yourself up to a point where you feel that you can take anything on...

You can also download maps that were made for the original stranded 2 here,

http://www.unrealsoftware.de/files_cat.php?cat=3&lan=2

Or you could make your own maps with the editor.


Also, to play your maps, go the the single island tab, you'll find any maps you "SAVED" there under the name you saved them as.

Also, when you download a map, take the content of the download and place it in the maps folder inside the mod/stranded2 folder...

old Re: how to add new animal,building,and item

joekirei
User Off Offline

Quote
yes your'e the master, because your can answered my question i wanted , and the explaination its correct,


ohh thats it, i made hut, and i get key, but i dont know what use that key,, i know turtlr island, because i kill all turtle in that island to get a loot big meat,, heheehhe

if i go to the map3,,can i back to map 2 (because i built great village in that map)

sounds its great ,, i will try random map next :),


however, i found some problem,,

why i dont meet my new add model ( deer) in my adventure game my own saved, but if i play new adventure game without load my saved game, i look the deer,, i so tired if i must play new game to look my n ew added model(deer),,,

old Re: how to add new animal,building,and item

Lion_Hearted
User Off Offline

Quote
You have to restart the adventure map to notice your changes, this is due to when your loading your save file, your actually loading a whole different map...

This has and will always be the case...

old Re: how to add new animal,building,and item

joekirei
User Off Offline

Quote
okay, i see that case,, thanks lion

can you explain how to remake skin of unit ???
i try recolored any units,(like human, lion, and bird) in paint/photoshop, but i have result, the units cause white( no skin,

what program to colored/edit skin ??
what program to making [example].b3d ??
and what program to animate that b3d ??

give me light master lion

old Re: how to add new animal,building,and item

Lion_Hearted
User Off Offline

Quote
To retexture any units or objects, you must make sure that the texture file you edited has the "EXACT" same name. When the model is created, its programmed into the model to search for that name in the folder that the model is in. It will ignore all other names.


Example... I want to change the parrot skin...

I'll find it here,
stranded 2/mods/stranded2/gfx/parrotskin.jpg

I take that skin, and edit it, and then export it to here...

stranded2/mods/stranded2/gfx/parrotskin.jpg

You will of course overwrite the original skin, and the game will read that skin instead.

However if you changed the .jpg to .bmp or some other format, then the game will ignore your newest texture. You have to have the exact same name, in the exact same folder, with the exact same extension.


I've found Wings3D to be extremely self explanatory on many of its modeling techniques, just right click and you can make anything. Its texturing tools are a bit tricky, but a breeze once you know how to use them. I made the deer, and all the other models in Wings3D. If you use wings3d, export to .3ds, stranded 2 will read those files just as good as b3d.


To size it all up...

To remake the skin of a unit, you have to overwrite the original texture meaning the new texture have exact same name and location that the old one did.

You can use any program in my experience to edit a skin, I personally use coral photopaint, however its something you'll have to buy. Regular windows paint should also work as well as long as you give it the exact same name.

Programs for making .b3d would be in my knowledge, Milkshape3D DeleD CE with a plugin, Blender3D with a plugin which can be found here
http://www.unrealsoftware.de/files_show.php?file=1575

However making .b3d isn't all its made out to be. Wings3D can export .3ds which stranded 2 handles without a problem, its free and easy to use.

What I use to animate my models is Anim8tor, I make the models in Wings3D, export them to .3ds already textured... then use anim8tor to animate them (Your gonna have to look at a tutorial for this) then export them to .an8 format, then use ani2pov
http://texel3d.free.fr/projets/ani2pov/ to translate the animations and the model to .ms3d format, then milkshape3D that translates the full and finished model to .b3d format.

And theres your animated model.

old Re: how to add new animal,building,and item

Lion_Hearted
User Off Offline

Quote
lol!


Is this a scripting questions thread now?


This thread should have been by default in the scripting area, if a moderator or someone from the staff moves it then sure, I'll answer your scripting question... Or of course, if you post your question in the scripting thread...


But, I'm gonna end this...

old Re: how to add new animal,building,and item

joekirei
User Off Offline

Quote
hi lion,, long time no chat ^^,, thanks a loot for your guide for making and texturing model,, its works, but i must learn more tuttorial to use that application ^^,,

however i have more question for you,, how i can play stranded 2.5 in windows 7 ?

before i play in windows xp, and its work without error, but i try play in windows 7, i meet some error,

like this >>
" Unable to initiale Graphics
Please check DirectX and GFX Drivers"

you know to solve the problem ??

i try ask this cuestion in other tread, but the answer is so simple and i dont understand waht they say,, i ask for you, because only your answer what i understand,,

please help me lion

old Re: how to add new animal,building,and item

joekirei
User Off Offline

Quote
this the answer, from user Hurri

have you tried to do what the error message told you? have you checked your drivers for an updated version?

usually the normal S2 runs fine on most win7/vista computers since DC compiled a new version of the game with an updated version of Blitz3d.
so that means if the exe of the S2.5 Mod wasnt compiled with the same version, this might cause problems on win7/vista.

, i can't understand it

old Re: how to add new animal,building,and item

Lion_Hearted
User Off Offline

Quote
Basically, it says that you need to address the maker of the mod with this problem.

This mod runs off an older version of the game which didn't support windows 7 or vista operating systems. The only way for it to work is if the mod maker adjusts his mod to work with the new update.

I'd suggest asking the mod maker to update his mod.
To the start Previous 1 2 Next To the start
Log in to replyGeneral overviewStranded II overviewForums overview