| View previous topic :: View next topic |
| Author |
Message |
bis_senchi

Joined: 08 Jun 2004 Posts: 460 Location: Reims, France
|
Posted: Fri Jun 02, 2006 9:38 pm Post subject: That's a good think to know! |
|
|
Ok! I will work some more on the code... I've read on the wiki that the "show load menu" has been implemented but not officially.
Could somoene make a little guideline and explain how to use this command with tirgoviste? (Expect if a new version of the OhrRpgCe is going to be realeased within next month)
Thanks in advance! |
|
| Back to top |
|
 |
bis_senchi

Joined: 08 Jun 2004 Posts: 460 Location: Reims, France
|
Posted: Sun Jun 04, 2006 12:36 am Post subject: Next problem! |
|
|
Please do not pay attention to the previous because I got the piece of information I needed. Anyway here is another problem
I've changed my code a little bit so that the key is pressed became unactive will the tag is turned on but when I test it the player can still press the key. It seems that a end, else, begin would be appropriate but I don't know how to combine the commands
Does somoene has any idea why ?
| Code: |
if ( (key is pressed(key: r),and, (check tag (tag:keyboard locked)==ON) ) then, begin
my keyboard jump
end
#Key is pressed r pour sauter
|
As always thanks for the help! |
|
| Back to top |
|
 |
Mike Caron Technomancer

Joined: 26 Jul 2003 Posts: 889 Location: Why do you keep asking?
|
|
| Back to top |
|
 |
LeRoy_Leo Project manager Class S Minstrel

Joined: 24 Sep 2003 Posts: 2683 Location: The dead-center of your brain!
|
Posted: Mon Jun 05, 2006 7:49 am Post subject: |
|
|
We could disregard the first post, but we had to read it anyway, right?
Er- unless someone reads this topic backwards, the damage is done and ten seconds goes out the window... So next time, use the edit button, my good chum. ^^
I am glad you could resolve that issue. _________________ Planning Project Blood Summons, an MMORPG which will incinerate all of the others with it's sheer brilliance...
---msw188 ---
"Seriously James, you keep rolling out the awesome like gingerbread men on a horror-movie assembly line. " |
|
| Back to top |
|
 |
bis_senchi

Joined: 08 Jun 2004 Posts: 460 Location: Reims, France
|
Posted: Sun Jun 11, 2006 11:25 am Post subject: I've made some tests and... |
|
|
I've tried to change the tag ON to OFF but when I turn the tag on (using a text box and npc) the if key is pressed is still valid....
May be the code should be modified so that something happens if the first conditions are not valid.... Does somoene any suggestions for improvement? |
|
| Back to top |
|
 |
bis_senchi

Joined: 08 Jun 2004 Posts: 460 Location: Reims, France
|
|
| Back to top |
|
 |
Mike Caron Technomancer

Joined: 26 Jul 2003 Posts: 889 Location: Why do you keep asking?
|
Posted: Tue Jun 20, 2006 2:28 pm Post subject: |
|
|
That's easy. If you use "suspend box advance", suddenly the player can't press space to advance the text box anymore. Be sure to use "resume box advance" when you're done.
However, unless you know exactly what you're doing and/or getting into, do not have a script that does anything like this:
| Code: | suspend box advance
show text box(523)
wait for textbox |
It will freeze the engine, and prevent anything from doing anything.
(Actually, you could put this to effect, if you wanted the hero to walk around and do stuff while the text box was showing, and some other npc/script advances the text box, allowing the first script to continue. However, if any of this sounds confusing, then just don't do it.) _________________ I stand corrected. No rivers ran blood today. At least, none that were caused by us.
Final Fantasy Q
OHR Developer BLOG
Official OHRRPGCE Wiki and FAQ |
|
| Back to top |
|
 |
bis_senchi

Joined: 08 Jun 2004 Posts: 460 Location: Reims, France
|
Posted: Sun Jun 25, 2006 8:21 pm Post subject: Could somoene tell me how... |
|
|
Mike Caron wrote:
| Quote: |
suspend box advance
show text box(523)
wait for text box
|
I didn't know that it was possible to use the wait for text box command as the box advance is suspended. It's an interesting thing to know.
Could somoene tell me how to make disappear a text box from the screen using plotscripting. Here is what I would like to do
| Code: |
suspend box advance
show text box(523)
wait (3)
advance text box
show text box(526)
wait (3)
advance text box
show text box(531)
wait (3)
advance text box
resume box advance
|
In the example above, text boxes appears one after another but I would text box 531 not to be on screen anymore as the script ends.
So? How am I supposed to do that ?
As always thanks very much for the help! |
|
| Back to top |
|
 |
Mike Caron Technomancer

Joined: 26 Jul 2003 Posts: 889 Location: Why do you keep asking?
|
Posted: Mon Jun 26, 2006 3:59 am Post subject: |
|
|
Well, by "after the script ends", do you mean immediately after the "resume box advance"? Because, you'll have to add a wait(1) to do that. If you mean after the whole script it over and done with, then the script should work as is. _________________ I stand corrected. No rivers ran blood today. At least, none that were caused by us.
Final Fantasy Q
OHR Developer BLOG
Official OHRRPGCE Wiki and FAQ |
|
| Back to top |
|
 |
bis_senchi

Joined: 08 Jun 2004 Posts: 460 Location: Reims, France
|
Posted: Tue Jun 27, 2006 10:21 pm Post subject: buggie scripts... or may be not |
|
|
Thanks once more to Mike Caron for answering! I wanted the
text box to disappear after the "resume box advance", and wait(1)
was exactly what I needed.
Now that's turn to help or at least try to. As resquested in the
wiki chats, here are the scripts that make appears error "illegal wait statement #174"
| Code: |
#--------------------------------------------------------------------
script, launch game, begin
suspend player
suspend npcs
set hero picture (me, 0)
wait for hero (me)
teleport to map (20, 1, 2)
show backdrop (4)
lock hero(me)
wait (30)
show backdrop (3)
wait (35)
fade screen out (63,63,63)
show backdrop (2)
wait (35)
show text box (283)
fade screen in
resume player
resume npcs
end #end of plotscript
#-----------------------------------------------------------------------------
#In the script you can choose a new game... or not
script, new game2, begin
if (check tag (tag: new game)==ON) then, begin
#game start if there are no previous slots
fade screen out (0,0,0)
stop song
show backdrop (9)
wait (2)
introduction1
fade screen in
end
if (check tag (tag: new game)==OFF) then, begin
#game starts previous save slot loaded
show text box (283) # text box with option new game and continue
wait for text box
stop song
fade screen out (0,0,0)
#ILLEGAL WAIT STATEMENT #174 HERE #ILLEGAL WAIT STATEMENT #174 HERE.
load from slot (1)
#As James explained illegal wait #174 is linked with the
# load from slot command. That is why we can be sure the bug is here.
fade screen in
show map
resume player
resume npcs
unlock hero (me)
else, begin
wait(2)
end
end #end of the if check tag
end# end of the plotscript
#--------------------------------------------------------------
|
Good luck in solving bug #203 ! |
|
| Back to top |
|
 |
Battleblaze Warrior Thread Monk

Joined: 19 Dec 2003 Posts: 782 Location: IndY OHR
|
Posted: Thu Jun 29, 2006 10:47 am Post subject: |
|
|
Biz are you ever gonna make a game? You ask more plotscripting questions than anyone on the board. I just want to know what you have planned for thread after thread of hard work. _________________ Indy OHR! and National OHR Month Contest going on now!
"Aeth calls PHC an anti-semite; PHC blames anti-semitism"
-squall |
|
| Back to top |
|
 |
msw188
Joined: 02 Jul 2003 Posts: 1041
|
Posted: Fri Jun 30, 2006 10:11 am Post subject: |
|
|
Your 'end' commands near the bottom of the script are incorrectly placed. I have bolded and underlined (I think) the end that I believe should be moved:
| Code: |
if (check tag (tag: new game)==OFF) then, begin
#game starts previous save slot loaded
show text box (283) # text box with option new game and continue
wait for text box
stop song
fade screen out (0,0,0)
#ILLEGAL WAIT STATEMENT #174 HERE #ILLEGAL WAIT STATEMENT #174 HERE.
load from slot (1)
#As James explained illegal wait #174 is linked with the
# load from slot command. That is why we can be sure the bug is here.
fade screen in
show map
resume player
resume npcs
unlock hero (me)
#THE BOLD AND UNDERLINED (and BAD) END BELOW SHOULD BE HERE!!!!!!!
else, begin
wait(2)
end
[b][u]end #end of the if check tag[/u] [/b] #<--------------**BAD**
end# end of the plotscript |
This is because you have to end your 'if' block BEFORE you begin your 'else' block. Do you see?
PS: I'm not sure if this will fix the illegal wait problem, but it will make the compiler much happier, I believe.
EDIT: Okay, apparently the bold and underline don't work in the code part, so I put an arrow by that part as well. |
|
| Back to top |
|
 |
bis_senchi

Joined: 08 Jun 2004 Posts: 460 Location: Reims, France
|
Posted: Fri Jun 30, 2006 11:58 pm Post subject: Thanks! |
|
|
Thanks to Msw188 for highlighting the problem. Anyway I post the script to help to solve #bug 203 which I fortunatelly don't have anylonger in my games.
Feel free to use the code I've posted to try to produce an #illegal wait statement 174 and try to find a solution to this bug.
Why did I post the code here? Well my grammar is rather buggy and I didn't feel like posting it on bugzilla as I wasn't sure that It was a real bug.
Battleblaze said
| Quote: | | Biz are you ever gonna make a game? You ask more plotscripting questions than anyone on the board. I just want to know what you have planned for thread after thread of hard work. |
Well my game goes rather well. I'm actually working on the backdrops and the music. You can have info on my game at : http://sailormoon4eternity.site.voila.fr/
As I'm waiting for the "show load menu" command to be added in the plotscript dictionnary, the game won't be avialable for download for a certain time.
As always thanks for the help to everyone! Good luck on making your games! |
|
| Back to top |
|
 |
Mike Caron Technomancer

Joined: 26 Jul 2003 Posts: 889 Location: Why do you keep asking?
|
Posted: Sat Jul 01, 2006 8:35 am Post subject: Re: Thanks! |
|
|
| bis_senchi wrote: | Thanks to Msw188 for highlighting the problem. Anyway I post the script to help to solve bug 203 which I fortunatelly don't have anylonger in my games.
Feel free to use the code I've posted to try to produce an #illegal wait statement 174 and try to find a solution to this bug.
Why did I post the code here? Well my grammar is rather buggy and I didn't feel like posting it on bugzilla as I wasn't sure that It was a real bug. |
Yes, it'a bug. There should be no way to get an illegal wait statement error with any script, no matter how buggy. And, we already have a bug open for it.
| bis_senchi wrote: | Battleblaze said
| Quote: | | Biz are you ever gonna make a game? You ask more plotscripting questions than anyone on the board. I just want to know what you have planned for thread after thread of hard work. |
Well my game goes rather well. I'm actually working on the backdrops and the music. You can have info on my game at : http://sailormoon4eternity.site.voila.fr/
As I'm waiting for the "show load menu" command to be added in the plotscript dictionnary, the game won't be avialable for download for a certain time.
As always thanks for the help to everyone! Good luck on making your games! |
The show load menu command is in a nightly build (and has been for a great long while), and is in the plotscripting dictionary there. Feel free to use it at any point. _________________ I stand corrected. No rivers ran blood today. At least, none that were caused by us.
Final Fantasy Q
OHR Developer BLOG
Official OHRRPGCE Wiki and FAQ |
|
| Back to top |
|
 |
bis_senchi

Joined: 08 Jun 2004 Posts: 460 Location: Reims, France
|
Posted: Sun Jul 02, 2006 3:44 am Post subject: And once more... |
|
|
I am using the following script to try to make appear the load menu (the menu with 4 save slots that pops up when a game launch )
| Code: |
Global variable (16, show load menu)
#--------------------------------------------
define script, show load menu, begin
show load menu:=true
while (show load menu)do, begin
variable(slot)
slot:= show load menu
if(slot == -1) then, begin
#they canceled
end, else, begin
load from slot (slot)
#slot contains the save slot they chose.
end
show load menu:=false
wait (2)
end #end of the while loop
end #end of the plotscript
#--------------------------------------------
|
When I try it is as if I was using a simple load from slot command. Any suggestions and remarks are more than welcomed.
Anyway, Mike Caron wrote:
| Quote: |
The show load menu command is in a nightly build (and has been for a great long while), and is in the plotscripting dictionary there. Feel free to use it at any point. |
Could you give more details about how to use a nightly build?
Thanks as always from help and constructive criticism. Sorry for posting once more a message in a so little time. Feel free to tell me by posting on this forum if the code I've posted helps to reproduce the bug.
Good luck in making your games! |
|
| Back to top |
|
 |
|