why does this not work
Moderators: jelco, bert_the_turtle
why does this not work
### start of the game
EnterLocation zime
CamMove start 7
Say intro_1
Waitsay
CamBuildingFocus 15 200 75
Say mission_1
WaitSay
WaitCam
CamMove start 5
WaitCam
CamReset
i have no idea why this does not work
this is the game.txt file
Locations_StartDefinition
# Id Avail mapFile missionFile
# ==================================================================
0 1 map_zime.txt mission_zime.txt
Locations_EndDefinition
Buildings_StartDefinition
# Id teamId locId type link online
# =======================================
Buildings_EndDefinition
Research_StartDefinition
Research Darwinian 0 2
Research Officer 0 2
Research Squad 0 2
Research Laser 0 2
Research Grenade 0 2
Research Rocket 0 2
Research Controller 0 2
Research AirStrike 0 2
Research Armour 0 2
Research TaskManager 0 2
Research Engineer 0 2
CurrentResearch Squad
CurrentPoints 0
Research_EndDefinition
Event AlwaysTrue
Action RunScript intro_start.txt
End
Events_StartDefinition
Events_EndDefinition
please help me
EnterLocation zime
CamMove start 7
Say intro_1
Waitsay
CamBuildingFocus 15 200 75
Say mission_1
WaitSay
WaitCam
CamMove start 5
WaitCam
CamReset
i have no idea why this does not work
this is the game.txt file
Locations_StartDefinition
# Id Avail mapFile missionFile
# ==================================================================
0 1 map_zime.txt mission_zime.txt
Locations_EndDefinition
Buildings_StartDefinition
# Id teamId locId type link online
# =======================================
Buildings_EndDefinition
Research_StartDefinition
Research Darwinian 0 2
Research Officer 0 2
Research Squad 0 2
Research Laser 0 2
Research Grenade 0 2
Research Rocket 0 2
Research Controller 0 2
Research AirStrike 0 2
Research Armour 0 2
Research TaskManager 0 2
Research Engineer 0 2
CurrentResearch Squad
CurrentPoints 0
Research_EndDefinition
Event AlwaysTrue
Action RunScript intro_start.txt
End
Events_StartDefinition
Events_EndDefinition
please help me
- trickfred
- level5
- Posts: 1691
- Joined: Sat Jul 24, 2004 5:01 am
- Location: The Great White North, Eh?
- Contact:
If you're going to post code, you should put it in between code tags to make it easier to read.
I assume the script at the beginning is intro_start.txt? Really, it's a bad idea to send someone into a level via a script as soon as they load a mod - better to let them enter the first level, and then call the script via an 'always' scripttrigger.
You can't CamMove to the 'start' camera, as that's where the camera already is when the level starts - better to either move the start camera away from where you want the camera to first move to and place another one there, or (a better solution) create a second camera somewhere else, use CamCut to move to it at the beginning of the script, then CamMove back to start.
Nothing else immediately jumps out at me as being wrong/problem causing, maybe your problem might lie in the map or mission file?
By the way, have you read through the guides on Icepick's site?
I assume the script at the beginning is intro_start.txt? Really, it's a bad idea to send someone into a level via a script as soon as they load a mod - better to let them enter the first level, and then call the script via an 'always' scripttrigger.
You can't CamMove to the 'start' camera, as that's where the camera already is when the level starts - better to either move the start camera away from where you want the camera to first move to and place another one there, or (a better solution) create a second camera somewhere else, use CamCut to move to it at the beginning of the script, then CamMove back to start.
Nothing else immediately jumps out at me as being wrong/problem causing, maybe your problem might lie in the map or mission file?
By the way, have you read through the guides on Icepick's site?
It would be interesting to know what isn't working.
• Is the script simply not running?
Make sure your spelling is correct -- i.e. that the file name is intro_start.txt, and not intro_strat.txt or something. Also, make sure that the script is in the scripts/ directory of your mod.
• Is the camera doing something funky after entering the level?
As trickfred said, there is no point to having your first command be to move the camera to start. It is already there. If you try to move the camera to a position where it already is, Darwinia can behave strangely. You should remove that line.
• Does the script not relinquish control to the user?
Add a line to the end of the script. Darwinia looks for a blank line at the end. It will skip over the last line if there is no blank line at the end.
If it is not one of those three behaviours, could you be a bit more clear, please? What, exactly, is not working? Remember, more information is always better than less -- it is like the teachers I work with:
"My email isn't working!"
"Well, what's wrong with it?"
"It doesn't work!"
"What is it doing?"
"I don't know!"
"... Okay... I'll be over in a minute..."
And it turns out that their email isn't working because they can't find the stupid GroupWise icon on their desktops...
xander
• Is the script simply not running?
Make sure your spelling is correct -- i.e. that the file name is intro_start.txt, and not intro_strat.txt or something. Also, make sure that the script is in the scripts/ directory of your mod.
• Is the camera doing something funky after entering the level?
As trickfred said, there is no point to having your first command be to move the camera to start. It is already there. If you try to move the camera to a position where it already is, Darwinia can behave strangely. You should remove that line.
• Does the script not relinquish control to the user?
Add a line to the end of the script. Darwinia looks for a blank line at the end. It will skip over the last line if there is no blank line at the end.
If it is not one of those three behaviours, could you be a bit more clear, please? What, exactly, is not working? Remember, more information is always better than less -- it is like the teachers I work with:
"My email isn't working!"
"Well, what's wrong with it?"
"It doesn't work!"
"What is it doing?"
"I don't know!"
"... Okay... I'll be over in a minute..."
And it turns out that their email isn't working because they can't find the stupid GroupWise icon on their desktops...
xander
ok i got the black screen problem fixed, but now i cant get the text to start for m_1 here is my game.txt file and the script file, oh and also when it reaches the end of the script it does not return control to the player
Code: Select all
Locations_StartDefinition
# Id Avail mapFile missionFile
# ==================================================================
0 1 map_zime.txt mission_zime.txt
1 0 map_zhub.txt mission_zhub.txt
Locations_EndDefinition
Buildings_StartDefinition
# Id teamId locId type link online
# =======================================
Buildings_EndDefinition
Research_StartDefinition
Research Darwinian 0 2
Research Officer 0 2
Research Squad 0 2
Research Laser 0 2
Research Grenade 0 2
Research Rocket 0 2
Research Controller 0 2
Research AirStrike 0 2
Research Armour 0 2
Research TaskManager 0 2
Research Engineer 0 2
CurrentResearch Squad
CurrentPoints 0
Research_EndDefinition
Events_StartDefinition
Event AlwaysTrue
Action RunScript intro_start.txt
End
Events_EndDefinition
Code: Select all
### start of the game
EnterLocation zime
CamMove intro1 7
Say intro_1
Waitsay
CamBuildingFocus 15 200 200
Say m_1
WaitSay
WaitCam
CamMove intro1 5
WaitCam
CamReset
cro5point wrote:ok i got the black screen problem fixed, but now i cant get the text to start for m_1 here is my game.txt file and the script file, oh and also when it reaches the end of the script it does not return control to the player
For the first question, what does your strings_default.txt file look like? You should have a line in there that reads something like this:
Code: Select all
m_1 Here is the text that will be shown with the "Say m_1" command
And, to quote myself:
xander wrote:• Does the script not relinquish control to the user?
Add a line to the end of the script. Darwinia looks for a blank line at the end. It will skip over the last line if there is no blank line at the end.
Also, what is going on with your intro1 camera positions? The camera automatically starts at the position called "start" every time the level is loaded. Thus, the camera position marked "start" should probably be somewhere reasonable. Second, when you give camera control back to the user, it is generally advisable (though not necessary) to give them control at the start positon. Thus, I might write a camera movement script that looks something like this (assuming that the script is triggered upon entering the level, or that a script brings one into the level; also, please note the blank line at the end):
Code: Select all
CamCut position01 #this instantly moves the camera to position01
CamMove position02 10 #take 10 seconds to move to position02
WaitFade #this causes the game to wait for the level to fade up before doing anything else
Say foo01
Say foo02
Say foo03 #says some stuff
WaitSay
WaitCam #wait for the text and camera
CamMove start 10 #take 10 seconds to move to start
Say foo04
Say foo05
Say foo06 #says some more stuff
WaitSay
WaitCam #wait for the text and camera
CamReset
xander
thank you so much so far
there is only one thing left that is wrong, the text for m_1 is not working it text that is ment to play when the cam moves to the trunk port, here is the text script
there is only one thing left that is wrong, the text for m_1 is not working it text that is ment to play when the cam moves to the trunk port, here is the text script
Code: Select all
### z
### =
# Intro
intro_1 Oh my god im glad i got hold of you, the viruses have returned but this time it had nothing to do with the darwinians, before i could fix the security of the drawinians world some one has hacked into the system and uploaded the virus again, im not sure who is doing it but im working to find out who it is and why they have done this, i need you do again stop the virus spread seeing as you were so good at it last time, im counting on you again.
# mission1
m_1 Ok you are going to have to get this trunk port going so you can get to the zhub and gain access to the other islands, this is you first mission, good luck.
I think it might be the way you told it what camera...it should look like this...
### start of the game
EnterLocation zime
CamMove camintro1 7
WaitCam
Say intro_1
Waitsay
CamBuildingFocus 15 200 200
Say m_1
WaitSay
WaitCam (...remove this WaitCam)
Wait 2 (if you want a pause after speaking...)
CamMove camintro1 5
WaitCam
CamReset
Change what is in yellow. Always use the wait cam right after the move command, if you use it at all. After saying CamMove remember to say cam in front of the camera name.
See if that helps it kick in.
### start of the game
EnterLocation zime
CamMove camintro1 7
WaitCam
Say intro_1
Waitsay
CamBuildingFocus 15 200 200
Say m_1
WaitSay
WaitCam (...remove this WaitCam)
Wait 2 (if you want a pause after speaking...)
CamMove camintro1 5
WaitCam
CamReset
Change what is in yellow. Always use the wait cam right after the move command, if you use it at all. After saying CamMove remember to say cam in front of the camera name.
See if that helps it kick in.
cro5point wrote:i tryed that it does make it look better but the error is still there it will not work it moves to the all the cams the only thing it will not do is play the m_1 text, i have no idea what is going on
Ahh... that is in your Strings Default and Scripts listings.
How is m_1 listed inside your strings file? It should see it and play the text.
this is my strings file im pretty sure its right
oh and reloading the level did not work the m_1 file is still the only thing that is not working
Code: Select all
intro_1 Oh my god im glad i got hold of you, the viruses have returned but this time it had nothing to do with the darwinians, before i could fix the security of the drawinians world some one has hacked into the system and uploaded the virus again, im not sure who is doing it but im working to find out who it is and why they have done this, i need you do again stop the virus spread seeing as you were so good at it last time, im counting on you again.
m_1 Ok you are going to have to get this trunk port going so you can get to the zhub and gain access to the other islands, this is you first mission, good luck.
oh and reloading the level did not work the m_1 file is still the only thing that is not working
Who is online
Users browsing this forum: No registered users and 13 guests