Apolyton Archive  |  Preserved copy of the Apolyton Civilization Site and its forums as they stood in September 2005. Read-only; nothing here can be posted to or replied to.  |  Forum index |  About this archive |  The 1998–2001 UBB forums
Today on Apolyton WARDELL INTERVIEW PROMO A.C.S. HISTORY CHAPTER 4 GET CIV4 /w FREE PLUS! A.C.S. PHOTO GALLERY GET A.O.M. V1.1
Apolyton Civilization Forums
main| civ2| civ3| civ4| smac| ctp2| ron| moo3| galciv| galciv2| alt| about|
ApolytonPLUS | register | search | faq | new posts | pm (-/-) | upload | members
hall of fame new! | civgroups | civgroups news | interviews | the column | radio | chat | directory | news | store | PLUS
Apolyton Civilization Forums : Powered by vBulletin version 2.0.3 Apolyton Civilization Forums > Miscellaneous > Archive > CtP2-Creation/AI/Mods/Scenarios-Archive > Alertbox question
Show a Printable Version | Email This Page to Someone! | Receive updates to this thread | Report this to Apolyton news!

bottom of page
  
Author
Thread    < Last Thread     Next Thread > Post New Thread     Post A Reply
mapfi is offline mapfi
Prince
Zurich, Switzerland
Jul 2002
time: 06:22
  Old Post 05-10-2002 21:30
Edit/Delete Message Reply w/Quote
#1 Report this post to a moderator
Alertbox question Avatar Enlargement: We've got the solution

Does an alertbox stop the game at the moment it's triggered for sure? The thing I'm interested in is the following: Let's say I call a message in an EventHandler which is set to 'pre'. Does that prevent the event of happening until the alertbox is closed? And in that example, does a return STOP in the messagebox code stop the event?

Pedrunn is offline Pedrunn
King
of Natal, Brazil
Jul 2001
time: 02:22
  Old Post 05-10-2002 22:54
Edit/Delete Message Reply w/Quote
#2 Report this post to a moderator
Avatar Enlargement: We've got the solution

I know where you are stuck at. I have been in a situation like yours before while doing the PBEM fix. But I really dont know the asnwer for it.
I just assumed that the asnwer was "no, it doesnt stop" without testing .
So i have managed a work around.
Still I would test it if i were you. But i believe the aswer really is no.
Here what i did to send proposal only after the consent of the player through alertbox:

code:
int_t CanSendProposal; HandleEvent(NewProposal) 'SaveProposalToPBEM' pre { if(CanSendProposal == 0) { message(player[0], 'PBEM_ProposalReady'); return STOP; } else{ CanSendProposal = 0; } } alertbox 'PBEM_ProposalReady' { Text(ID_WILL_YOU_SEND); Button(ID_YES){ CanSendProposal = 1; Event:NewProposal(player[0], player[1]); kill(); } Button(ID_NO){ kill(); } }


I hope the code is as clear as i think it is.

Last edited by Pedrunn on 05-10-2002 at 23:05

Martin Gühmann is offline Martin Gühmann
Emperor
Berlin, Germany
Mar 2001
time: 06:22
Post  Old Post 06-10-2002 16:04 Visit Martin Gühmann's homepage!
Edit/Delete Message Reply w/Quote
#3 Report this post to a moderator
Support Apolyton, buy Civilization 2

Unfortunatly the answer is no otherwise, the City Capture Option code what first ask you before the army enters the city, but before you can click anything the city is conquered. Maybe it could help to use the function: UseDirector() BUt from the discription I fear it is shown after the actual event.

-Martin

mapfi is offline mapfi
Prince
Zurich, Switzerland
Jul 2002
time: 06:22
  Old Post 06-10-2002 18:52
Edit/Delete Message Reply w/Quote
#4 Report this post to a moderator
Enter the AD-FREE zone

Thanks you guys. Yes, Pedrunn that makes sense. You might have guessed the problem - the reformation in our religion code. If you decide not to, or don't have enough money, I don't want the reformation event to finish.

Pedrunn is offline Pedrunn
King
of Natal, Brazil
Jul 2001
time: 02:22
  Old Post 06-10-2002 22:51
Edit/Delete Message Reply w/Quote
#5 Report this post to a moderator
Support Apolyton, buy Alpha Centauri

Actually i was suspicious about that.
This thought was in my mind.
Yet, I cant figure out why the simulation of the effects of reformation like i did in the code needs change?

mapfi is offline mapfi
Prince
Zurich, Switzerland
Jul 2002
time: 06:22
  Old Post 07-10-2002 01:08
Edit/Delete Message Reply w/Quote
#6 Report this post to a moderator
Tired of ads?

Actually it doesn't... as I later figured out.

New question:
Can I tell the game what size the messagebox should have?

Pedrunn is offline Pedrunn
King
of Natal, Brazil
Jul 2001
time: 02:22
  Old Post 07-10-2002 03:26
Edit/Delete Message Reply w/Quote
#7 Report this post to a moderator
Get a bigger avatar today!

quote:
Originally posted by mapfi
Actually it doesn't... as I later figured out.


quote:
Originally posted by mapfi
New question:
Can I tell the game what size the messagebox should have?

I dont think so
but messageboxes are bigger than alertbox though

mapfi is offline mapfi
Prince
Zurich, Switzerland
Jul 2002
time: 06:22
  Old Post 07-10-2002 22:32
Edit/Delete Message Reply w/Quote
#8 Report this post to a moderator
Support Apolyton, buy Call to Power 2

I just seem to recall that somewhere I read that it's possible to change messagebox sizes - but I can't find anything now... Oh well

Martin Gühmann is offline Martin Gühmann
Emperor
Berlin, Germany
Mar 2001
time: 06:22
Post  Old Post 07-10-2002 22:39 Visit Martin Gühmann's homepage!
Edit/Delete Message Reply w/Quote
#9 Report this post to a moderator
Support Apolyton, buy Call to Power 2

quote:
Originally posted by mapfi
I just seem to recall that somewhere I read that it's possible to change messagebox sizes - but I can't find anything now... Oh well


It is not impossible to change the message box sizes. Message boxes are part of the UI so the must be defined in the *.ldl files, too. Also alert boxes must be defined there, but Iactual I wasn't able to find any sign of the AlertBox in the ctp2.exe, so maybe these boxes are defined in the *.ldl files only.

-Martin

ahenobarb is offline ahenobarb
Prince

Nov 2001
time: 05:22
  Old Post 14-10-2002 09:25
Edit/Delete Message Reply w/Quote
#10 Report this post to a moderator
Re: Alertbox question Help yourself to an AD-FREE life

quote:
Originally posted by mapfi
Does an alertbox stop the game at the moment it's triggered for sure? The thing I'm interested in is the following: Let's say I call a message in an EventHandler which is set to 'pre'. Does that prevent the event of happening until the alertbox is closed? And in that example, does a return STOP in the messagebox code stop the event?


Mapfi, have you tried the suggestions here? Is it possible to stop the action with 'UseDirector();' or 'Return STOP;'?

UseDirector is just keyed to the animation isn't it? The Function Reference file indications that this command is useful to time the triggering of the messagebox (won't work with alertboxes according to the docs) with the animation. So, it sounds like 'return STOP;' would be the best option here.

Any dvelopments you can share?

mapfi is offline mapfi
Prince
Zurich, Switzerland
Jul 2002
time: 06:22
  Old Post 14-10-2002 13:50
Edit/Delete Message Reply w/Quote
#11 Report this post to a moderator
Support Apolyton buy from Amazon

I didn't need it after all - I think... kind of forgto...
Never used UseDirector() before - so can't help you there. Sorry

Locutus is offline Locutus
ACS CTP1/2 Manager & Civ4 Co-Manager
Hengelo, The Netherlands
Nov 1999
time: 06:22
  Old Post 19-10-2002 19:05 Visit Locutus<br><img src=/forums/images/staff-icon.gif>'s homepage!
Edit/Delete Message Reply w/Quote
#12 Report this post to a moderator
Got spare money?

About messagebox size: 'Messagebox' messages have a fixed size, which IIRC is set in the ldl files. 'Alertbox' messages have a dynamic size: they are as large as they need to be, depending on the amount of text and buttons that they have (there *is* a limit on the max size though, which appears to be hardcoded).

  < Last Thread     Next Thread > Post New Thread     Post A Reply
All times are GMT. The time now is 05:22.
Apolyton Time is 00:22.
    top of page
Rate This Thread:
archivepost
Forum Jump:
Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is ON
vB code is ON
Smilies are ON
[IMG] code is ON
 




Contact Us - Apolyton Civilization Site - Support Us!

Building a better Apolyton through better information. Click here and take our poll!
Non-US visitors, click here!

Powered by: vBulletin Version 2.0.3
Copyright ©2000, 2001, Jelsoft Enterprises Limited.

Page generated in 0.0429 seconds (89.59% PHP - 10.41% MySQL) with 31 queries
Page Loading Time:

Support Apolyton: Amazon USA | Amazon UK | Amazon DE | Amazon FR |
Support Apolyton and get FREE PLUS, Buy from Chips&Bits: Galactic Civilizations | Galactic Civilizations: Deluxe Edition | Call to Power 2 | Civilization: The Boardgame | GURPS/ Alpha Centauri | Alpha Centauri | Civilization IV | Civilization III: Complete |


Front Page | Civilization IV | Civilization III | Civilization II | Call to Power II | Alpha Centauri | Master of Orion III
Rise of Nations | Galactic Civilizations | Galactic Civilizations II | Misc
Alt.Civs | Civ I | C:CtP I | About | News | Directory | Apolyton Store | Forums | Chat | Columns | Interviews | Newsletter
Scenario League | CSC | Clash of Civs | Spanish Site | CtP Maps | Cradle of Civ | WesW's Ctp1/2 Site | Civ3 Haven

apolyton.net | apolyton.com | civilization2.net | civilization3.net | civilization4.net | civilizationiv.info | calltopower.net | galciv.net | galciv2.net | moo3.net