Jump to content

Recommended Posts

Posted (edited)

##########
This engine should add a text system, such as
id  stringname  string
0    "a"        "aa"
1    "b"        "bb"
2    "c"        "cc"
3    "d"        "dd"
……
##########Folder directory
game/languages/en
game/languages/cn
……            
##########
when need ,can set lang directory = "./languages/en" or lang directory = "./languages/cn"
the string ID is not change
accord the string ID get the Localization string

menu_text =str_ID

label_text =str_ID

dialogue_text =str_ID

message_text =str_ID

The same string can be reused;
##########

Edited by Super-Fly-Eagle
Posted

we actually do have something along those lines. using head as an example:    

cliffsnotes:
set langTableMod for your over arching language table tracker
for a particular text element use textID for assignment
define a global variable matching it for a numerical reference

write your txt files in the form stringname string

Posted (edited)

@Azaezel

download the new source,success:

Prevent the refresh function from being deleted and add a new file  langs.tscript to refresh

@EMU35HYDU3S@3U2NLI74.png.428f11937b37ffaa4a4d7eeec2f47ffa.png

langs.tscript ——refresh

languageMap.tscript ——record str_id

?4.03 there is a problem :After change some tscript and recompile, the 4 main menus "single play","creat server", "join server", "options"not work

? Insert problem: when insert Chinese ,display garbled characters;chinese insert finish when press space or num ,not keydown

Edited by Super-Fly-Eagle

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...