1)is it possible to show the GameOver screen in a meelee match and all the game' scores in it, and how? sample on a basic galaxy script map?
i tried the "GameOver(1, c_gameOverVictory, true, true);" but where should this be placed for example to apear immidiatly after the game starts (just to see if its working). i opened a map F6 to edit the standar triggers and played arround in the intitMeele function but 0 results. nothing happend when i tested the map with the map editor.
2)is it possible to read a bank file every 1second and to get 1value from it and (for example show it in the game chat txt). but been in constant loop, so when i edit the bank file externally with an xml editor and change the value the next second the running map ingame will saw the new value?
(we are talking always about a single player map-offline map)
tnx a lot. if you could provide with basic script samples would be great ;-) to understand it better
1)
Afaik Score Screen doesn't appear when you just test map.
..
Do you mean you want to show it during the game? Without ending the game for the player? In this case you can only replicate the score screen using a ton of dialog items.
Otherwise - the score screen should always pop up after the game ends / a player leaves.
1)is it possible to show the GameOver screen in a meelee match and all the game' scores in it, and how? sample on a basic galaxy script map? i tried the "GameOver(1, c_gameOverVictory, true, true);" but where should this be placed for example to apear immidiatly after the game starts (just to see if its working). i opened a map F6 to edit the standar triggers and played arround in the intitMeele function but 0 results. nothing happend when i tested the map with the map editor.
Have an event "Upon melee initialization" and it should appear immediately after the game starts. Like s3rius said though, it wont show the score screen unless its not a test map.
I'll have to test out the bank thing before I can comment.
1)i want after the game finishes with vistory for example to get me to the score screen but this game its a map that i drag-drop into the sc2.exe so not actually a test map from the map it self, but again, it seems like it tries to open it i get a 1-2 second glistch there and boom straight to the main login again.
so i am wondering why the score screen is it only evalable mif you are online? if you play like guest you do get a score screen at the end! why cant we do the same in a custom map we drag from our desktop?
2)yes i know we are lloking onto a solution to by pass this "bug" limitation i dont know. the most annoying is that i cant even open my map again and if this not a bug then what! i tried to post it in official b.net forums forums in Eu where down! grrrrrrrrrr
scenario to test:
-open a bank
-write a value in a section-key
-save the bank
-open the bank
-read that value fromthe bank-> works
-close the bank from the cache (remove)
-open the bank again (seems to be -ok but)
-read the same value again as before! (ERROR!) the value is emtpy and the bank is not actually loaded or accessable!!!!!!
so blizzard allows as to load one bank only once in our sp games and give us a remove from cache fucntion for nothing??? wth is going on i have no idea!
any brainstorming is welcomed and possible work arrounds on that.
That would probably be due to having to pre-load banks.If you haven't got a pre-load bank then an open bank action every time you open the bank you will run into errors. However, you may then run into bugs whilst preloading each time.
I just tried without preloading it seems to work. But if the file is modified while the map is running, it doesn't seem to load. Its as if the bank is saved into memory or something.
I can delete the bank after its saved, and I can still read values from it.
But when I reload the map it fails (since it was deleted).
I tried not deleting and modifying the values as well. But it still reads the old values. When i try saving, it saves the old values into the bank.
Edit: Lol, I just noticed i have 404 posts xD
Edit: Ok the preload function seems to be a little retarded. It still works even when I disable the trigger function that holds it. So yes, you need to preload a bank apparently if you want to be able to read from it.
However, if the bank doesnt exist, then a preload is not required. It will automatically be created.
Edit3: Ok.. another finding..
If i just use BankLoad.. I can't read values from the bank. But if i use Preload, I can...
With just BankLoad, it detects the bank exists but can read nothing from it apparently..
Edit 4:
If i open a bank and read it. It works the first time.
Once I remove it from the cache and reopen it, the opened bank has 0 sections and 0 keys inside it.
Putting it simply. When attempting to read the same bank more than once after open/close cycles, it will fail to load properly. This is the debugger output.
I've also attached my testing files if you wanna check em out. Put the banks in the Starcraft II/Banks folder in your "my documents".
Summary of findings (According to my understanding):
If a bank does not exist, it will create the bank, load it into memory and into cache. (memory and cache are not the same!)
If it does exist, it must be *preloaded* (into memory) and *loaded* (into cache)
If you remove a bank from the cache and attempt to open it again, it will fail to open even though its still in the memory. (retarded right? i suspect this is a bug)
As long as the bank was preloaded to memory, it will be detected as "exists". But it cannot be read or written unless it is first loaded. *It can only be loaded ONCE, subsequent attempts will work if the cache is not cleared, but once the cache is cleared, its going to keep failing.*
It appears attempts to modify the bank outside the game will not register as it does not directly change the values in the cache/memory, where the banks are written/handled.
In conclusion... I'm sorry to say that in my opinion, I don't think it's possible to do constant bank reading. Even if they fix bank loading.. Theres no guarantee that it will be able to detect changes made to the bank externally. It might still load the thing from what was preloaded to memory.. And preloading only happens when the map is loading.. So yeah :| But don't give up hope.. If there's a will, theres a way. I wish you good luck finding it, as I don't think I can do anything further to help your cause.
if they fix this stupid bug i have a workarround for the looping reading but i came to the same results and this bug kills me right now i cant even find a way to report it
i cant believe i am stuck due to a random bug!!!!
for now...... >:)
oh btw guys any of you found why loading a bank by using a variable name doesnt work and the liter way works? there is no note like the preload that this needs literal string name and not variable.....hmmmmm weird......
hi guys 2 questions
1)is it possible to show the GameOver screen in a meelee match and all the game' scores in it, and how? sample on a basic galaxy script map? i tried the "GameOver(1, c_gameOverVictory, true, true);" but where should this be placed for example to apear immidiatly after the game starts (just to see if its working). i opened a map F6 to edit the standar triggers and played arround in the intitMeele function but 0 results. nothing happend when i tested the map with the map editor.
2)is it possible to read a bank file every 1second and to get 1value from it and (for example show it in the game chat txt). but been in constant loop, so when i edit the bank file externally with an xml editor and change the value the next second the running map ingame will saw the new value? (we are talking always about a single player map-offline map)
tnx a lot. if you could provide with basic script samples would be great ;-) to understand it better
none?
1)
Afaik Score Screen doesn't appear when you just test map.
..
Do you mean you want to show it during the game? Without ending the game for the player? In this case you can only replicate the score screen using a ton of dialog items.
Otherwise - the score screen should always pop up after the game ends / a player leaves.
2)
We talked about that^^
Have an event "Upon melee initialization" and it should appear immediately after the game starts. Like s3rius said though, it wont show the score screen unless its not a test map.
I'll have to test out the bank thing before I can comment.
1)i want after the game finishes with vistory for example to get me to the score screen but this game its a map that i drag-drop into the sc2.exe so not actually a test map from the map it self, but again, it seems like it tries to open it i get a 1-2 second glistch there and boom straight to the main login again.
so i am wondering why the score screen is it only evalable mif you are online? if you play like guest you do get a score screen at the end! why cant we do the same in a custom map we drag from our desktop?
2)yes i know we are lloking onto a solution to by pass this "bug" limitation i dont know. the most annoying is that i cant even open my map again and if this not a bug then what! i tried to post it in official b.net forums forums in Eu where down! grrrrrrrrrr
scenario to test:
-open a bank
-write a value in a section-key
-save the bank
-open the bank
-read that value fromthe bank
-> works-close the bank from the cache (remove)
-open the bank again (seems to be
-ok but)-read the same value again as before! (ERROR!) the value is emtpy and the bank is not actually loaded or accessable!!!!!!
so blizzard allows as to load one bank only once in our sp games and give us a remove from cache fucntion for nothing??? wth is going on i have no idea!
any brainstorming is welcomed and possible work arrounds on that.
tnx for your time
@vernam7: Go
That would probably be due to having to pre-load banks.If you haven't got a pre-load bank then an open bank action every time you open the bank you will run into errors. However, you may then run into bugs whilst preloading each time.
i thought preloading-synch was needed only in multyplayer
i am in sp offline still i would try it but i thing i allready have.
@wOlfLisK: Go
I just tried without preloading it seems to work. But if the file is modified while the map is running, it doesn't seem to load. Its as if the bank is saved into memory or something.I can delete the bank after its saved, and I can still read values from it. But when I reload the map it fails (since it was deleted).
I tried not deleting and modifying the values as well. But it still reads the old values. When i try saving, it saves the old values into the bank.
Edit: Lol, I just noticed i have 404 posts xD
Edit: Ok the preload function seems to be a little retarded. It still works even when I disable the trigger function that holds it. So yes, you need to preload a bank apparently if you want to be able to read from it.
However, if the bank doesnt exist, then a preload is not required. It will automatically be created.
Edit3: Ok.. another finding..
If i just use BankLoad.. I can't read values from the bank. But if i use Preload, I can... With just BankLoad, it detects the bank exists but can read nothing from it apparently..
Edit 4:
If i open a bank and read it. It works the first time. Once I remove it from the cache and reopen it, the opened bank has 0 sections and 0 keys inside it.
Putting it simply. When attempting to read the same bank more than once after open/close cycles, it will fail to load properly. This is the debugger output.
I've also attached my testing files if you wanna check em out. Put the banks in the Starcraft II/Banks folder in your "my documents".
Summary of findings (According to my understanding):
In conclusion... I'm sorry to say that in my opinion, I don't think it's possible to do constant bank reading. Even if they fix bank loading.. Theres no guarantee that it will be able to detect changes made to the bank externally. It might still load the thing from what was preloaded to memory.. And preloading only happens when the map is loading.. So yeah :| But don't give up hope.. If there's a will, theres a way. I wish you good luck finding it, as I don't think I can do anything further to help your cause.
if they fix this stupid bug i have a workarround for the looping reading but i came to the same results and this bug kills me right now i cant even find a way to report it
i cant believe i am stuck due to a random bug!!!! for now...... >:)
oh btw guys any of you found why loading a bank by using a variable name doesnt work and the liter way works? there is no note like the preload that this needs literal string name and not variable.....hmmmmm weird......
any idea guys on the loading from variable?
@vernam7: Go
It does mention on the trigger description that it only accepts literals. It's just built that way.
@FuzzYD: Go it says that only in the preload function not the load .... :(
@vernam7: Go
Hm.. I've no idea why it's that way then :|