Jump to content
Sign in to follow this  
iceman11a

Convoy, Getting then in. ?

Recommended Posts

Z, You don't have to say sorry. I'm happy that your helping. That's why I wanted it in a script. That's easy to edit then sending the hole file and the script. I didn't under stand why it only work 1/2 way threw it. Like I said. I just didn't think it would be this hard.

See if I can get a better PC and a better video card. I'll just go back to ArmA II.

Share this post


Link to post
Share on other sites
Z, You don't have to say sorry. I'm happy that your helping. That's why I wanted it in a script. That's easy to edit then sending the hole file and the script. I didn't under stand why it only work 1/2 way threw it. Like I said. I just didn't think it would be this hard.

See if I can get a better PC and a better video card. I'll just go back to ArmA II.

Ok here is the new and improved version. In the getout part I miss-named the vehicles, like you did in yours. Thats why it didn't work for you.

http://www.mediafire.com/download/u5bdyi87mz12b2i/weed_kills.eden.zip

Scripting is pretty much the same from game to game. ARMA II has more commands which might make some things easier.

Vehicles in OFP have always been a pain, helos are even worse... :p

Edited by Zulu1

Share this post


Link to post
Share on other sites

Thanks Z, that works. I been adding on to it. I mite have a full SP mission soon, ? I hope. One question. How do I get nothing other then a player to trip a trigger. When the player enters the trigger The trigger trips and the script runs.

Ice

I all so some new commands in the scripts you made. I'll have to ask about them later on.

Share this post


Link to post
Share on other sites
Thanks Z, that works. I been adding on to it. I mite have a full SP mission soon, ? I hope. One question. How do I get nothing other then a player to trip a trigger. When the player enters the trigger The trigger trips and the script runs.

Ice

I all so some new commands in the scripts you made. I'll have to ask about them later on.

Group the trigger (F2) with the player.

Share this post


Link to post
Share on other sites

Z, Thanks. That works. How ever I still can't get some things to work. and I know I'm not doing it right. The idea is that when the player trips that trigger. The player and a man, Civilian have a chat with each other. I can get the sidechat to work for the player, Nothing seems to work for the Civilian, Here's my code below.

; *****************************************************
; ** Operation Flashpoint Script File
; *****************************************************

_Player = _this select 0
_SkoInformaer = _this select 1

;s1 sideChat "Blue squad On the way -out"
_Player sidechat "Ok, So what do you have for us."
~5
_SkoInformer globalChat "52 Miles East from here, There is a small house."
~5
_SkoInformer globalChat "You will find him there."
~5
_Player sidechat "What about guards and patrols."
~5
_SkoInformer globalChat "Very Heavy, and Armor."
~5
_Player sidechat "Thanks, For the info."
~5
_SkoInformer globalChat "Your welcome and good luck."
~10

OntheGo = true

exit

after the chat is done, The OntheGo trips a trigger and the men move out to a small house. I have it marked with a marker. The the other problem I have is there a way to mark the way the player goes. I need a way to show the player where to go when the get out of the hummer.

Thanks

Ice

Edited by iceman11a
Typing error

Share this post


Link to post
Share on other sites

Hi,

Here is a demo mission.

http://www.mediafire.com/download/tjudjujnp0bjd53/TalkDemo.zip

You really need to watch the spelling errors. (_SkoInformaer = _this select 1) :)

In cadet mode waypoint markers are available. When setting up the waypoint in the edititor the 3rd box down is "description". You can type in anything you want here as a message to the player. In the editor these waypoint markers will not be visible at first. You must save the mission to a game mission and play it once. Then you'll see the markers in the editor.

I set "Onthemove" to false in the init.sqs and it becomes true at the end of the talk.sqs. Also in the "TalkToInformer" waypoint the condition "True" was replaced with "Onthemove". The init.sqs is a file that the mission uses automaticly, so if there is anything you want to happen at the start of the mission you can put it here. Thats what I did with loading the units in vehicles in the last file I did.

btw; if you're making a script for a specific use in a mission you don't need to use variables (_skoinformer). You can just use the units or group names directly.

Varibles for Select 0, 1, 2, 3 are intended for general use scripts that can be used by anyone for any mission.

Edited by Zulu1

Share this post


Link to post
Share on other sites

Thanks Z, I didn't know that and I will try and watch my spelling. I tried downloading your sample and it doesn't seem to want to download. Any ideas.

Share this post


Link to post
Share on other sites
Thanks Z, I didn't know that and I will try and watch my spelling. I tried downloading your sample and it doesn't seem to want to download. Any ideas.

It d/l'ed for me. Try again, sometimes medaifire acts up.

Share this post


Link to post
Share on other sites

I did get the sample. and some questions. Was the problem my spelling or ?, any way it's Onthego = false not OntheMove. and I didn't know about the init.sqs file so thanks for telling me about that all so.

and last is that you put a civ1 globalchat "Hello My Friend"; in the init of the civilian and then called the script. Is there a reason for this. why not just put it in the script

civ1 globalchat "Hello My Friend"; [player, civ1] exec "talk.sqs";

Share this post


Link to post
Share on other sites

I don't know how you were using the script, but the spelling caused the informer lines not to show. True/False conditions should always be set to the default at mission start. (either true or false) You can't change conditions in midstream. My error, I ment to say Onthego.

I just threw that in,(seemed to fit) it could be in the trigger or script. I didn't change your script except to correct spelling error.

There are many ways to accomplish things in OFP. There is nothing wrong with using the init fields. It is easier to find errors in a .sqs file vs having to look in units, triggers and waypoints.

Edited by Zulu1

Share this post


Link to post
Share on other sites

Ok, thanks Z, I'll try and remember every thing have said. Does any one have some plans on making some samples. If you don't mined. I like to add the samples you gave me I would like to add them to my web site. and I would like to find some one to make some articles on tutorials on OFP too. So I can add them in all so. That way I'll have them.

Z, you been great. Thanks and I will need more help as time goes on.

---------- Post added at 01:51 PM ---------- Previous post was at 01:49 PM ----------

Oh, Z, I did forget one thing. Is there an option to add voices to my games. and not just text. Does OFP have a list of wave files used for voices and a sample on how to play them in missions.

Share this post


Link to post
Share on other sites

Iceman,

When you have lots of time on your hands here is the best editing tutorial around.

http://www.mediafire.com/download/8jjfrlhdjb4xkqz/UberEditorTutorial.zip

Some voices/sounds/music can be played from triggers and/or waypoints by using the effects button. You can also put text on the screen and have camera scenes in effects too.

Here is a good tute for sounds & music:

Music, Sound & Radio Tutorial

-----------------------------

By Navy_Seals

Very Important:

When converting music, the files recomended to be converted at Frequency 44100 hz max,

BitRate 128kbps, 16 bit, stereo, Encoding - Constant Bitrate.

(Note: 16 bit option is not included in dbPowerAmp, but don't worry about that)

For sounds, like speech: Frequency 44100 hz, 16 bit, mono, Bit Rate in ranges from 80 -

112kbps, Constant Bitrate.

Also very important thing. Don't use big names and upper case letters.

Try using one word for the name of ur song, like rock, u2, party, sunrise, etc... whatever

is in ur mind, otherwise if u'll have let's say for instance Red Hot Chilli Peppers or like

Eagle Eye Cherry, the game won't be able to read them, so try to keep it simple, but u can

write like this - RHCP or lets say Mick_Jagger, no spaces.

Ok and now it appears to be that the file size of the music file can be unlimited well

sorta, i dont think u gonna use 15 megs song or something like that.

Alright, let's see what we have got here...Let's move on.

-----------------------------------------------------------

Conversion Programs

-------------------

First what u need is a program to convert ur music to ogg.

U see the game doesn't support standard files like mp3 or wav, that's why we have to convert

them to be able to hear them ingame.

Also the advantage of ogg file is it's size, it can be the same quality as mp3 but the size

can be up to 2-3 times smaller, cool ah?!

Alright so here r the two proven and tested programs which u can download for free.

U can use either of them, but I recommend both, the choice is yours.

Here is the first one:

dBpowerAMP Music Converter grab it here -> http://www.dbpoweramp.com/bin/dMC-r11.exe

and an ogg plugin for it so u'll be able to convert ur music to ogg format ->

http://www.dbpoweramp.com/codecs/dBpowerAMP-codec-ogg.exe.

The second one:

GoldWave, u can grab it here ->:

For Win95/98/NT - http://www.goldwaving.com/downloads/gwave426.exe

For Win2000/XP/Me - http://www.goldwaving.com/downloads/gwave510.exe

also a ogg plugin for it over here -> http://www.goldwave.com/downloads/calogg00.zip

Ok so now u have ur programs on ur hard drive, install them where u want (C: D: E: don't

know what u got there).

Great so now u have ur progys installed.

What?! Tired?! hehe don't worry that's just the easy part.

Now im gonna explain how to use the first program dBpowerAMP Music Converter.

Will be working with music first, cos it's not so difficult as it seems to be, and will

move on to the sound later on.

-----------------------------------------------------------

Converting to Ogg

-----------------

Open the program and a window will pop-up asking u which file would u like to convert.

Choose the song u want and click Open, now u'll see another window which will show u the

list of file formats u have.

Choose ogg. Now pay attention cos its important!!!

U can leave the channels: stereo, Bit rate must be 128kbps-standard and BIS used it too,

Encoding should be Constant Bitrate (a must) and Frequency-44100hz.

Now choose the folder where u want to save ur file and click convert, simple as that.

Here im gonna tell u about GoldWave.

This is also a great program, it supports many formats and very useful.

I usually use it more for sounds and editing.

U can do a lot of things like noise reduction, shape volume (one of my favorites)

pitch, and many more!

But u can also use it for converting ur music.

So open the progy, a window will pop-up, don't really pay much attention to it unless u want

to, and click ok.

Then choose the file u want to convert and open it.

Then simply click file-> save as and choose ogg format and here we are!

(also I suggest unless u won't be doing anything with the sound like changing it or do some

editing I suggest u simply use the dBpowerAMP Music Converter , for ease of use)

So u have converted ur music into ogg, then create a folder in the mission where u r

currently working on, lets say:

E:\OperationFlashpoint\Users\Charlie\missions\assault.Eden and name the folder Music, this

is where we r going to store our converted music files.

Description.ext

---------------

So now we will create a description.ext file in a notepad.

U'll probably say, hey what a hell is this stuff?!

Description.ext is a special file created simply in notepad.

It contains all the info above; Extra information about the mission (weather, place,ect...)

Information about the player and other units (face, glasses, rank, type,ect...)

Weapons in the game and ammunition (also can be add-ons)

How to add sound or music in game! <- we'll be working with that part of file.

And many more...

Ok, now we know what a description.ext is, that means we can do some writing.

Create an empty file in notepad and write this down and then im gonna explain what

everything stands for, alright.

-----------------------------------------------------------

Music

-----

class CfgMusic

{

tracks[]=

{

jade, blink

};

class jade

{

name = "jade";

sound[] = {\music\jade.ogg, db+0, 1.0};

};

class blink

{

name = "blink";

sound[] = {\music\blink.ogg, db+0, 1.0};

};

};

Simple isn't it? Ok now lets' see what we got here.

First,

class CfgMusic

{

This defines a new class for all our music.

Brackets like these -> { } r very important when writing and defining classes, if u missed

one somewhere the whole file is not gonna work.

The syntax in OFP is very important so pay attention to it when creating files like this one

or scripts for example which we r not going to cover here.

Also semicolon is very important here, don't forget it to put it almost after each line

except when defining a class like class CfgMusic or class CfgSounds, etc...

Well in tracks[]= u simply define which tracks u have in ur Music folder.

Now lets' take a close look at the first class jade, shall we...

class jade <- here we define the new class for the song we specified in the tracks

{

name = "jade"; <- this is the name that will be displayed in the trigger-effects-music

drop down menu, but we'll talk about this later.

If u leave it blank then in the editor u'll see only an empty space.

sound[] = {\music\jade.ogg, db+0, 1.0}; <- this line tells the game which music is

going to be used. Don't forget that u have

placed ur music in the Music folder, that's

why we write \music\jade.ogg, db+0 is the

volume of the sound. If u leave 0 then it

will play at the volume u have specified in

the game options and 1.0 is a pitch of the

music.

}; <- and the closing brace with a semicolon showing that the definition of this class is

finished.

Now save this file as All files name it exactly description.ext.

The common problem is sometimes people give it the same name, but save it as text file,

which then creates a lot of problems for them.

And u know why? No?! Ooh come on that's so simple, its because the file appears to be

description.ext.txt which OFP will not read, that's all!!!

Well... looks like we have done the big and difficult part of the job, aren't we. Hehe,

probably u r tired of reading all that crap, sitting at ur home and saying, oh come on man

I wonna hear some music playing!!!

Well don't worry we r nearly there.

Playing the Music

-----------------

Now launch ur game and open ur mission editor(choose any island u want, I suggest desert

island cos it loads at no time).

Now a simple test, to see if ur music is working.

Place a unit- the player of course and put a trigger not far away from him in the trigger

choose activated by west and when present.

Then u'll see a button in the lower left corner called Effects.

Press it and a new window will appear.

Wow!!! Look at that we got so many different thing in here, but all we care about now is

music, so find the music drop down menu and got to the bottom until u find the name of ur

song.

Choose it and click ok, u'll return to trigger window again, don't change anything there,

just press ok and preview.

Now run in the direction of a trigger and...what looks like I hear something ain't I yeah

it's the music file which I have converted!!! Uuupii!!! I can hear it, I can hear it.

Well we all did have our moments of joy when after trying to do something difficult we

finally succeed.

Well u can take a big brake, and we'll be right back with editing sounds now, stay tuned.

-----------------------------------------------------------

Sounds

------

Now I assume that u know how to create description.ext files and how to get the music in

game.

Now we gonna work with sound files.

Later on u will see that sounds as speech play where important role in the game.

It creates a whole new atmosphere and this gives a game a big plus, especially using speech

during cutscenes.

So for this task I suggest u use the GoldWave as u can record ur voice through microphone

and it saves really good to wav file.

U'll probably ask me, why wav file I can save directly to ogg and don't bother myself with

that crap.

Wav2Lip

-------

Well u see why.

To be able to use speech in the game u need not only ogg files, but also lip files which

will make the mouth of the unit move.

So what u need is simple program wav2lip converter.

U can download this program here -> http://www.ofpec.com/editors/resource_view.php?id=352

Now here we go, open the GoldWave and create a new file.

Then record something using ur mic and save it as wav 16 bit mono, signed.

It will be set by default. Now locate the folder where u have saved ur wav file and copy it

by using Ctrl+C or better cut it with Ctrl+X and go to the folder where u have placed

wav2lip program.

Simply drop the wav file onto the program file and in few seconds it will create a lip file

with the same name.

Don't suggest u putting this program on desktop cos it won't work. Trust me.

Now u can open the dBpowerAMP Music Converter and convert the wav file to ogg or just use

GoldWave and save the file with the same name just in ogg format.

So now we r ready to go on with our tutorial.

cfgSounds

---------

U r already familiar with the description.ext so just open the one we have created before.

Done? Alright!!!

Now write this down after the class CfgMusic.

class CfgSounds

{

sounds[] =

{

speech1, speech2

};

class speech1

{

name = "speech1";

sound[] = {"\sounds\speech1.ogg", 1, 1.0};

titles[] = { };

};

class speech2

{

name = "speech2";

sound[] = {"\sounds\speech2.ogg", 1, 1.0};

titles[] = { };

};

};

Well difficult? Not at all! As u can see its almost the same as class CfgMusic expect here

we have this line: - titles[] = { };

It is used for stringtable.csv which we gonna cover a bit later, but u don't really need to

do stringtable.csv for sounds, its up to u.

So now we r set and ready to go.

Playing the Sounds

------------------

Put ur converted ogg files and lip files in the Sounds directory.

Open the editor and put a trigger again or use the existing one if u have saved the mission

about adding music.

Now do the same go to effects, but not music! But voices drop down menu.

At the bottom as well u'll see ur files. But we r not going to use triggers for speech.

U can either use waypoints if u have only one speech like man comes to the Officer and tells

him something.

That's all, in all other cases we use simple script and use the command line:

unitname say "speech1"

That's all, this simple.

-----------------------------------------------------------

Stringtable.csv

---------------

Since u already know how to create ur own speech, work with description.ext, etc... we just

gonna jump right down to the point of making everything look and sound good.

Ok lets say u already have a sound file which u recorded at 11025 - 44100Hz Frequency, 16

bit, mono, Constant or Average bitrate. (Note: the lower the settings the crappier the sound

will be, so feel free to tweak all the stuff)

Since now we have our ogg file we gonna use Excel a bit to create a stringtable.csv which is

also can be used for sounds, but the truth i never did it for sounds cos..... i just didn't

do it and it doesn't matter whether u have it or not the

choice is urs.

But anyways the stringtable should look like this:

Language English <- here we gonna write what every radio file

contains (BIS did the same for sounds,i don't)

Comment ---stuff---

STRD_D01v01 Butthead u dumbass <- write what the original radio file contains

STRD_D01v02 R u threatening me? <- same here

STRD_D01v03 Beavis, erh Beavis, shut up! <- same here

As u have noticed i began using the BIS stile which is better and more convinient for me and

i don't mix up anything like i did before.

STRD is simply an abriviation (string something...), u can write whatever u want but the

main body of the name in this case D01v01 should be the same as the ogg file in sound

directory which is d01v01.ogg.

Upper or lower case letters don't matter here, so don't worry much about it.

So for instance u can have charlie_Green01 or papaBear_Advise or anything u can think of,

any name as long as its easy and convinient for u.

(note: don't forget to save the file named as stringtable and from "Save As" drop down menu

choose CSV (Comma Delimited) and voila.

Ok then looks like we almost set, just few more tweaks with description.ext and we r ready

to Lock&Load.

-----------------------------------------------------------

Radio

-----

class CfgRadio

{

sounds[] =

{

R01v01, R01v02

};

class R01v01

{

name = "R01v01";

sound[] = {"R01v01.ogg", db+40, 1.0};

title = $STRD_R01v01;

};

class R01v02

{

name = "R01v02";

sound[] = {"R01v02.ogg", db+40, 1.0};

title = $STRD_R01v02;

};

};

Alright lets do it quickly, cos u r familiar with most of the stuff from music & sound

example.

sounds[] = {R01v01, R01v02}; <- radio sounds which we have

class R01v01 <- create class for the first radio file

{

name = "R01v01"; <- name...says it all

sound[] = {"\sounds\radio\R01v01.ogg", db+40, 1.0}; <- directory where file is,

its volume and pitch.

//note that u can create another folder in sound folder, called radio and place ur

radio files there or have them in the same folder with sounds, therefor u would

write: sound[] = {"\sounds\R01v01.ogg", db+40, 1.0};

title = $STRD_R01v01; <- for stringtable.csv to read

};

Ok so now we r done with description.ext, almost there, just few more tricks and u r set.

-----------------------------------------------------------

Extra Bits

----------

A lot of times people ask how to use Papa_Bear or Base or Airbase, well its simple and the

answer is right here.

This is what u have to do.

[west, "Base"] sideRadio "black_02";

[west, "HQ"] sideRadio "02r1"; <- HQ, Base and Papa_Bear no matter what u'll type u

will always get Papa_Bear radio message.

[west, "AirBase"] sideRadio "R01v02";

aP globalRadio "R01v01"; <- these r simple commands on how to make someone

speak on the radio.

aP sideRadio "R01v02"; <- same here, but side radio is only for units on ur

side, enemy units won't recieve it.

Well, well, well looks like u made and i guess i'll have to say that, thats it for today

folks.

Now u should have a strong background and knowledge on how use ur own music and sounds in

game, how to create description.ext and stringtable.csv, use programs like GoldWave and

dBpowerAMP or others if u don't feel comfortable with these onse.

Well guys to tell u the truth now I am tired like hell.

So here we r that concludes our tutorial for this time, hope u enjoyed it and happy

music and sound editing.

Thank you for reading this so called "trash" should i say have fun and ill see ya around,

cheers!

Looping

-------

Oh and here r just couple of tricks u can do with the sound and music.

;small script for looping music or sound

_i = 0

#loop

_i = _i + 1

playmusic "name of ur song"

~70 - the length of the song

? (_i <= 5): goto "end"

goto "loop"

#end

ForceEnd

If u want the music to come out of the radio or anything else u should make ur ogg file with

the same specs as u do for sound, then we place a radio in the editor and write:

this exec "music.sqs" and now we'll write a music.sqs file.

So lets say that the length of ur music file is 1:20, so u'll write in the notepad like

this:

#loop

_this say "name of ur song"

~120 - //the actual length of the song, we use it if u want the song to loop over

goto "loop"

Well that should bring some more fun to ur mission, well thats all, cheers.

Share this post


Link to post
Share on other sites

Z, Thanks for the info, How ever that link. The file that's attached to it. It only explains the mission editor. The problem I have is the scripts and my spelling. I download a crap load of scripts. Just nothing I can use. I'm sure I posted a message about wanting some samples and what I wanted. I wish I just had like 200 samples of scripts doing a little of every thing. With a good description at the top.

I have a lot of mission samples with scripts. I just don't under stand a lot of it. So if you guys can and have the time. It would be great if I could get my wish list. lol, Thanks again Z, If there's any thing I can do for you. Let me know.

Ice

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×