ComSer Forum
Welcome, Guest. Please login or register.
July 19, 2018, 01:11:59 PM

Login with username, password and session length
Search:     Advanced search
Registration of new members is disabled. Read the newspost.
8133 Posts in 708 Topics by 253 Members
Latest Member: Maxigenzztop
* Home Help Search Calendar Login Register
+  ComSer Forum
|-+  Gusanos Forum
| |-+  Gusanos Modding
| | |-+  help!
0 Members and 1 Guest are viewing this topic. « previous next »
Pages: [1] Go Down Print
Author Topic: help!  (Read 3524 times)
ninjaspud
Jr. Member
*

Karma: -1
Offline Offline

Posts: 25


View Profile
« on: December 04, 2009, 05:34:51 PM »

im new to modding nd i have no scripting knowledge aside from a weapon has to have the .wpn .obj and the sprite files but could sum1 explain the lines of script in a weapon or sumthin to help me
« Last Edit: December 04, 2009, 05:46:04 PM by ninjaspud » Logged
Feliz Lombriz
www.GusanosFiles.co.cc Admin
Member
**

Karma: 8
Offline Offline

Posts: 57



View Profile WWW
« Reply #1 on: December 05, 2009, 02:02:36 PM »

Take a look at the Gusanos FAQ under the heading Modding Docs. Quite a few things are explained there. I can't help more than that as I haven't ever tried my hand at modding. Glad you're interested, but I suggest you keep all of your similar questions in one topic instead of creating new topics for each question. Things get cluttered otherwise.
Logged

ˇHappy Worm!
ninjaspud
Jr. Member
*

Karma: -1
Offline Offline

Posts: 25


View Profile
« Reply #2 on: December 05, 2009, 09:19:42 PM »

ive read the modding docs nd i cant understand a word of it im a noob
Logged
Protoss Archon(GD)
Creator of Telek
Sr. Member
***

Karma: 5
Offline Offline

Posts: 131


Yeah, I'm back.


View Profile WWW
« Reply #3 on: December 07, 2009, 09:58:55 PM »

Well, you won't learn anything from the modding docs. I sure I didn't learn anything.
See back then, I made bad mods which were just pure experiments such as the KPOX mod with the nebulous idea of having 101 weapons.

This is going to be a slightly long tutorial, it'd probably take like a minute or two to briefly skim across this without tripping over and judging from your poorly written post, just take your time.

How I learnt modding, I simply experimented simple modifications and inaugurated the information from the experiments. For newcomer Modders, they make mods usually modification of the default weapons and add cliche annotations such as SUPER-SHOTGUN or MEGA-UZUMAKI.

If you're asking for an editor, there is non unless someone has the time or even knowledge to make an editor. The only way to mod is to use notepad.

To edit a weapon, first it would be smart to make a copy of your default folder (excluding the map folder, it's not necessary).

Go to the WEAPONS folder and right click "machinegun.wpn"
Click 'Open with...' in the drop down menu and run as notepad. Tick -always use this program-

Once complete.

The following should appear:

Code:
name = MACHINEGUN
ammo = 35
reload_time = 200

laser_sight {
range = 200
intensity = 0.3
}

on primary_shoot()
 show_firecone( firecone.png, 7, 5 )
 delay_fire(8)
 use_ammo(1)
 add_speed(-0.05)
 play_sound( shot.ogg, 100, 1, 0.05 )
 shoot_particles ( machinegun_bullet.obj , 1 , 1, 0, 0, 0, 6.6, 0, 7)
 shoot_particles ( shell.obj , 1 , 1, 0.3, 0.5, 0, 20, -105)

I'll run through the basics of what every function is performed in this file from top to bottom.

Code:
name = MACHINEGUN
Name is probably the most obvious, this will display the name of the weapon.

Code:
reload_time = 200
Don't use decimals for ammo this means that the reload time takes around 2 seconds to complete it's reload.
Reload time happens to run in miliseconds, when you run out of bullets, it will take however long you put it. Don't use decimals for reload time either.

Code:
laser_sight {
range = 200
intensity = 0.3
}
This is a rather useless function to me however. This is the basic format for the red lasersight for the machinegun.
The larger the range, the longer the laser sight is.

This image shows the laser sight intensity at 0.3


This image shows the laser sight intensity at 1

Code:
on primary_shoot()
This is a start of a function, simply in layman's term. When the fire button is held down, whatever is below is executed.

And the functions below which are executed are:
Code:
show_firecone( firecone.png, 7, 5 )
 delay_fire(8)
 use_ammo(1)
 add_speed(-0.05)
 play_sound( shot.ogg, 100, 1, 0.05 )
 shoot_particles ( machinegun_bullet.obj , 1 , 1, 0, 0, 0, 6.6, 0, 7)
 shoot_particles ( shell.obj , 1 , 1, 0.3, 0.5, 0, 20, -105)

Code:
show_firecone( firecone.png, 7, 5 )
The firecone function is simple to explain, it shows an image on the user who fires the weapon in this case.
firecone.png is the sprite it depicts whenever the weapon is fired, the number 7 onwards is how fast the firecone animates.

The final number indicates how far in from the user is the firecone displayed, using a negative number would make the image appear behind the user.

Code:
delay_fire(8)
Delay is a very simple function. Delay stops all functions in
on primary_shoot()
on primary_press()
until the delay countdown reaches 0, these two functions are able to execute once again.
Putting no delay (or simply delay_fire(0))causes the rate of fire to be extremely fast as shown below.




If the delay is  delay_fire( 8 )
Then the rate of fire will look suitable as the defualt mod.


Code:
play_sound( shot.ogg, 100, 1, 0.05 )
This function is simple, it plays the sfx "shot.ogg" from the defualt folder, sounds.
The value 100 volume of the sound, the lower, the harder it's to hear from a distance. It is not the volume of the sound but the distance it could be heard.

The next value which is '1' is the pitch of the SFX. The higher, the shorter and higher pitch the sound is. If the pitch was 5, it'd sound like clicking, if the pitch was 0.5, it'd sound like a carbine, try it.

The final value which is 0.05 is a pitch variation. For a small number, the variation is difficult to hear. If you put 1, than the variation is very noticeable when firing.

Code:
shoot_particles ( machinegun_bullet.obj , 1 , 1, 0, 0, 0, 6.6, 0, 7)
 shoot_particles ( shell.obj , 1 , 1, 0.3, 0.5, 0, 20, -105)
Lets just concentrate on the simple things and ignore 'shell.obj'.

Shoot particles is the most useful function, you will use it in probably almost every weapon. Shoot particles will create a particle and the numbers will affect the particle.

The machinegun_bullet.obj is located in the defualt - objects folder just so you know.

Whenever shoot particle is performed, it uses the object file's information of what the projectile does, but we'll ignore that for now.
The first number indicates how many particles are spawned when firing, if you put 10, than your weapon would look like a automatic wave cannon. Don't use decimals.
The second number indicates the speed of the bullet.
The third number indicates the variation speed of the first bullet, so that when you fire, the bullet sometimes may be slow, sometimes it may be faster.
The fourth number indicates movement inheritance. Your worm movement affects the direction and speed of the particle being spawned.
The fifth number is the variation of the movement inheritance, like the third number. (I'm not even sure if this works)
The sixth number is the spread of the weapon, the max which is 360, the smaller the number, the more accurate your weapon is. The larger, the less accurate your weapon is.
The seventh number is the angle of your particle being shot out.
The final number is the distance from the worm. If it's 10, than the bullet will appear in front of you, if it's 30, then it will appear furthur.

Images below will show you the effects of altering one or two digit as indicated in bold.

Quote
shoot_particles ( machinegun_bullet.obj , 10 , 1, 0, 0, 0, 6.6, 0, 7)


Quote
shoot_particles ( machinegun_bullet.obj , 10 , 5, 0, 0, 0, 6.6, 0, 7)


Quote
shoot_particles ( machinegun_bullet.obj , 10 , 1, 1, 0, 0, 6.6, 0, 7)


Quote
shoot_particles ( machinegun_bullet.obj , 10 , 1, 0, 1, 0, 6.6, 0, 7)


Quote
shoot_particles ( machinegun_bullet.obj , 10 , 1, 1, 0, 0, 360, 0, 7)


EDIT: (Sigh) I'm tired now, experiment the rest yourself.
« Last Edit: December 07, 2009, 10:04:17 PM by Protoss Archon » Logged

melons
ninjaspud
Jr. Member
*

Karma: -1
Offline Offline

Posts: 25


View Profile
« Reply #4 on: December 07, 2009, 10:06:51 PM »

thanks this explains a bit
so how would i create a sniper
and sniper bullet from scratch
Logged
Protoss Archon(GD)
Creator of Telek
Sr. Member
***

Karma: 5
Offline Offline

Posts: 131


Yeah, I'm back.


View Profile WWW
« Reply #5 on: December 07, 2009, 10:09:31 PM »

Please be a lot more clearer, the information your provided is vague.

And you're asking a hell alot, if you really want that much help, I suggest you add me on an instant messenger.
My email is rubyprojectgoblin@hotmail.com
Logged

melons
ninjaspud
Jr. Member
*

Karma: -1
Offline Offline

Posts: 25


View Profile
« Reply #6 on: December 07, 2009, 10:23:43 PM »

k just updatin msn messenger
Logged
Pages: [1] Go Up Print 
« previous next »
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.13 | SMF © 2006-2011, Simple Machines LLC Valid XHTML 1.0! Valid CSS!