It is currently Wed Dec 02, 2020 10:02 am

All times are UTC [ DST ]




Post new topic Reply to topic  [ 13 posts ] 
Author Message
 Post subject: Set Base Name
PostPosted: Sun Sep 03, 2006 3:00 pm 
Offline
Original-War.Net Owner
Original-War.Net Owner
User avatar

Joined: Wed Jan 25, 2006 10:21 am
Posts: 2786
Location: Poland, Białystok
How to give the name to a base?
It's easy. I'll show you how to do this.

Extract file Texts\BNames.wri from Data1.owp or create your own in mod_directory\Texts. Now if you extracted the file, you can use one of examples but if not, you should write in your file:
Code:
             //keep first line empty
identifier   //identifier used in SAIL
  base name  //real base name (remember about 2 spaces before it)
             //the last line also should be empty


Note: Remember about empty lines between previous and next name. Remember that texts after // are only a comments, don't write them in real file.

Now you can use in SAIL following command:
Code:
SetBName(building identifier,'name identifier')


Where the "building name" is an identifier of depot and the "name identifier" is an identifier of name defined in BNames.wri.

-----------------------------
Polish:

Jak dać nazwę jakiejś bazie?
To proste. Pokażę wam, jak to zrobić.

Wypakuj plik Texts\BNames.wri z Data1.owp lub stwórz własny w folder_modu\Texts. Teraz jeśli wypakowałeś ten plik to możesz skorzystać z jednego z przykładów, jeśli nie to wpisz do swojego pliku coś takiego:
Code:
             //pozostaw pierwszą linię pustą
identyfikator//identyfikator do użycia w SAIL
  nazwa bazy //prawdziwa nazwa bazy (pamiętaj o dwóch spacjach przed nią)
             //ostatnia linijka też powinna być pusta


Uwaga: Pamiętaj o zostawianiu pustych linii między każdą kolejną nazwą. Pamiętaj, że teksty za // są tylko komentarzami, więc nie musisz ich przepisywać.

Teraz możesz uzyć w SAIL następującej komendy:
Code:
SetBName(identyfikator budynku,'identyfikator nazwy')


Gdzie "identyfikator budynku" to identyfikator do głównego składu tej bazy, a "identyfikator nazwy" to identyfikator do nazwy w pliku BNames.wri.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Sep 04, 2006 11:53 am 
Offline
Original-War.Net Owner
Original-War.Net Owner
User avatar

Joined: Wed Jan 25, 2006 10:21 am
Posts: 2786
Location: Poland, Białystok
updated


Top
 Profile  
 
 Post subject:
PostPosted: Sat Oct 07, 2006 2:41 pm 
Offline
Soldier level 1
Soldier level 1

Joined: Sat Sep 16, 2006 7:56 pm
Posts: 72
Location: Czech Republic, Kladno
Thx. I will test it and transfer it to czech language.

_________________
I am Admin of: OWAR Centre, Hrej.cz, OFP.info
Projects: First in Siberia


Top
 Profile  
 
 Post subject:
PostPosted: Sun Feb 11, 2007 6:33 pm 
Offline
Moderator
Moderator
User avatar

Joined: Fri Jan 13, 2006 6:20 pm
Posts: 2325
Location: Argentina
Maybe I will use it for the second mission of my mod. Maybe to call the main base with an interesing name. Thanks, your discoverings are very useful and applicable.

_________________
-Aleph.

THE Very active person

"You can only do well at something if you put the time in. Doesn't matter what subject it is. You can't make a master piece over night."
Wise man Stu-


Top
 Profile  
 
 Post subject:
PostPosted: Sun Feb 11, 2007 7:44 pm 
Offline
Soldier level 5
Soldier level 5
User avatar

Joined: Sun Sep 24, 2006 8:26 pm
Posts: 1015
Location: Łódź, Poland
Yes, this is quite important one, but I also think it is one of easier things. To gwren: please, don't call this base totally weird...

_________________
Who dares wins
www.bullets4u.org - site of {B4U} multigaming clan


Top
 Profile  
 
 Post subject: Re: Set Base Name
PostPosted: Thu Jan 01, 2015 9:03 pm 
Offline
Soldier level 0
Soldier level 0

Joined: Sat Dec 27, 2014 12:36 pm
Posts: 12
Hi, i have a problem...
i created the file ( BNames.wri) i wrote all the stuff but when im in game above my Deposit says "BNAME error"..


Please help me

thx


Top
 Profile  
 
 Post subject: Re: Set Base Name
PostPosted: Thu Jan 01, 2015 11:35 pm 
Offline
Moderator
Moderator
User avatar

Joined: Mon Mar 17, 2008 6:03 pm
Posts: 1130
Location: Denmark
That's because the identifier couldn't be recognized. Your bnames.wri could be in the wrong folder, use wrong encoding or contain illegal syntax. As Radzio says bnames.wri has to be in [mod folder]/Texts. About the encoding I always just borrow a file from an existing project and modify that. If you upload the file I can check for syntax errors.

_________________
I have an if that has an else, but that if has another if with an else inside... My question is... If an if has an else, if there is more than one line in that if, should it have a begin and an end?


Top
 Profile  
 
 Post subject: Re: Set Base Name
PostPosted: Fri Jan 02, 2015 4:04 am 
Offline
Soldier level 0
Soldier level 0

Joined: Sat Dec 27, 2014 12:36 pm
Posts: 12
well i have it in the right folder and the names in the folder are correct with all those spaces.. hmm i think i wrote something wrong in SAIL... could you give me the full code that im suposed to put in SAIL please?


Thx.


Top
 Profile  
 
 Post subject: Re: Set Base Name
PostPosted: Fri Jan 02, 2015 1:40 pm 
Offline
Moderator
Moderator
User avatar

Joined: Mon Mar 17, 2008 6:03 pm
Posts: 1130
Location: Denmark
There is only that function SetBName to call. E.g. if you have something like this in BNames.wri

Code:
theta
  Theta Base


and a depot with identifier "dep1" you would go

Code:
SetBName(dep1,'theta');


Btw remembered one more thing: There is a limit on the number of characters in the name identifier in BNames.wri. Can't remember exactly how many characters it is but it's around 8.

_________________
I have an if that has an else, but that if has another if with an else inside... My question is... If an if has an else, if there is more than one line in that if, should it have a begin and an end?


Top
 Profile  
 
 Post subject: Re: Set Base Name
PostPosted: Fri Jan 02, 2015 3:33 pm 
Offline
Soldier level 0
Soldier level 0

Joined: Sat Dec 27, 2014 12:36 pm
Posts: 12
This is how i did in sail:


Starting
Begin
SetBName(dep1,'theta');
End;



and in BNames.wri:

theta
Theta Base

"i have the BNames.wri in the right folder"
and it compiles but in game says "BNAME error"


Top
 Profile  
 
 Post subject: Re: Set Base Name
PostPosted: Fri Jan 02, 2015 6:41 pm 
Offline
Moderator
Moderator
User avatar

Joined: Wed Jun 11, 2014 6:14 pm
Posts: 17
Location: CZ Prague
There's no problem in SAIL, BNames.wri must be wrong.
Be sure you have first and last line empty and two spaces before base name.


Top
 Profile  
 
 Post subject: Re: Set Base Name
PostPosted: Fri Jan 02, 2015 9:14 pm 
Offline
Soldier level 0
Soldier level 0

Joined: Sat Dec 27, 2014 12:36 pm
Posts: 12
well i did... everything is correct i don't know what's wrong


Top
 Profile  
 
 Post subject: Re: Set Base Name
PostPosted: Fri Jan 02, 2015 11:16 pm 
Offline
Moderator
Moderator
User avatar

Joined: Mon Mar 17, 2008 6:03 pm
Posts: 1130
Location: Denmark
We can ping-pong back and forth forever like this. Could you upload your entire mod? If you don't feel like everyone seeing it then PM it to me.

_________________
I have an if that has an else, but that if has another if with an else inside... My question is... If an if has an else, if there is more than one line in that if, should it have a begin and an end?


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 13 posts ] 

All times are UTC [ DST ]


Who is online

Users browsing this forum: No registered users and 1 guest


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group

Original War is an RTS / RPG game by Altar Games
Original War Support is not part of Altar Games but is maintaining Original War for Altar Games

Privacy Policy