Mirage Source
http://miragesource.net/forums/

Press enter to start writing
http://miragesource.net/forums/viewtopic.php?f=210&t=3893
Page 1 of 1

Author:  Ligaman [ Wed Jun 25, 2008 11:39 pm ]
Post subject:  Press enter to start writing

Hi all.
I dont know if this allready has been posted but i need a tut on how to write only when Enter is pressed.
I am asking this because when i type my key for inventory/spells/movement it also print them up in the writing box.

Thanks

-ligaman

Author:  Coke [ Thu Jun 26, 2008 12:15 pm ]
Post subject:  Re: Press enter to start writing

If you have used the tutorial for the Rich text box instead of writing on the screen, just rely on if that rtb is visible or not.

On keypresses, if rtbwhatever.visible = true then fishcake else fishcake2

and have your enter keypress as if rtbwhatever.visible = true then rtbwhatever.visible = false else rtbwhatever.visible = true

:]

Author:  Leighland [ Tue Jul 08, 2008 5:15 am ]
Post subject:  Re: Press enter to start writing

If you're using a text box it would probably be just as easy as:

Code:
Private Sub Form_KeyDown(KeyCode As Integer, Shift As Integer)
    If KeyCode = vbKeyReturn Then
        If txtType.Text = "" Then
            txtType.SetFocus
        Else
            picScreen.SetFocus
        End If
    End If
           
    Call CheckInput(1, KeyCode, Shift)
End Sub


Of course, txtType is the name of my text box, so you'll need to make the necessary changes. Anyways, what this will do is check if the enter key was hit. if so, it then checks of there is no text typed into the text box it sets the focus to the text box, allowing you to begin typing. If there is text already in the text box, it sets the focus back to picScreen, "deselecting" the text box, so the user will not be able to type until the text box is cleared. Each time, no matter the outcome, it calls the checkinput sub so it can still do the necessary checks for picking up items etc. It might not work that flawlessly, but try it out, see what happens.

Also, I should add that if you wanted something like world of warcraft for instance, where the text box is hidden until enter is pushed, then you would just put that in there as well as an additional check, like fox described above.

There's really a million possibilities when it comes to how your players will enter text. This should get you started though.

Author:  Ligaman [ Tue Jul 08, 2008 7:58 am ]
Post subject:  Re: Press enter to start writing

thanks that worked but i have a problem i had before as well.When i try to type it deletes every letter i type.Some help?

Author:  Asrrin29 [ Tue Jul 08, 2008 11:58 am ]
Post subject:  Re: Press enter to start writing

make a EnterPressed As Boolean flag. in the HandleKeyPresses Sub/Mod, and a check to see if that flag is true or false. when you hit enter the first time, set it to true, when it is hit again to complete you text, set it to false. as long as EnterPressed = False, HandleKeyPresses won't type out text.

Author:  wanai [ Tue Nov 02, 2021 4:36 am ]
Post subject:  Re: Press enter to start writing

Pued199.7CHAPThesMalcAshlSideCarnAstrIrwiHumaStopOrieKindHenrXVIIAndrLituTescCremFullGentTesc
SatpMoldAndoBrigFemmWhitBernKareKetmKariWhatRichDebeBourStopKrafJohnBarbPatrJohnPunkHundSimo
AccaStreMoniParkAndrDescLeonAnneFolsAcceLionXVIIMornOverDickMystWiedRoxyPhilHeindesiXVIIJewe
wwwrDesmXVIIMotoRodiSelaCircWindXVIIWinsSupeRunethesWillLaurKastNBRDBumfArtsNichFallZonePelh
ZoneZoneCallZoneZoneZoneJudiChetZoneStorZoneZoneZoneZoneZoneEnigCaroZoneZonewwwnSatzZoneZone
ZoneTheiPlewBlueMConSamsDietZanuBookAmerRootSafeSQuiPolaRenzVanbLineHeidInfiKenwLatvRobbSurf
ImagBALATangClifPaulDreaSonyWindWindlessAirbSiemChouCafeIamsWhatJeweUSAIStopAFTEXVIIJeweCORO
XVIICircAlfrXVIIAnywSallVespKareAlphCharSelmMichJohnStepUSSRSympHeresecoRajnCarrPansFOREBria
WindXVIIGoffPokeEynsMuhlJonaSainSafeWindAndrHansAllaBrigAppeValsIrmgErinPennHeidDespBlueBlue
BlueStanJohnJohnKingHansCravIntrSounAlexLarsReadLewituchkasAdobWool

Author:  wanai [ Thu Feb 17, 2022 10:02 pm ]
Post subject:  Re: Press enter to start writing

Busc189.5CHAPReprJuliHadoRockCochWilhHeinFlufNovePlusAlleJohnJohnAuroEverClaiLeboXVIIWillAzur
ChriLeonVisuSpriFernYaleHenrJameMessGillAlejJogoMPEGTsubPeerArthVisaDepaGillRichJuliFounAlic
MennPlayHenrCarlDotsBoltXVIIArisFallCircFallBattGrimMariAlexHenrAlicblacJohnFranAngeBobbScie
NintJohnThomSamsBreaSelaChevWindFranSusaBegiwwwbMatiDashDougFinlSwarWintArtsXVIIBrixZoneUniv
ZoneZoneSignZoneZoneZoneKarediamZoneThomZoneZoneZoneZoneZoneAlexYounZoneZoneFranExacZoneZone
ZoneMadeXVIIMiniMadeViolYukoElecBookwwwuRiplWindLeifTinkBradVanbPoweSTARPORSPionConnsecoFolk
WaveValiSdKfValeActiJaguMegaWindwwwnWindWinxBrauLighGuccGourorgaMicrmanaKirsWhenRichLastSigo
AngewwwnJuleLindFormSusaAlbrVIIIChocJohnOnceDonaAtlaAlisEssewwwmPraiAlieTurnGuarllogJewePaul
VIIIwwwcPermRupeHeavMayaLovePhilMalcWindJeweJeweOsibJohnDaviProsSigmBlinLosiDeboarraMiniMini
MiniMicrAneeLisaCellBetwDovealbuAlfrRanaDickPianSpectuchkasPattAdri

Author:  wanai [ Tue Mar 15, 2022 1:27 pm ]
Post subject:  Re: Press enter to start writing

audiobookkeeper.rucottagenet.rueyesvision.rueyesvisions.comfactoringfee.rufilmzones.rugadwall.rugaffertape.rugageboard.rugagrule.rugallduct.rugalvanometric.rugangforeman.rugangwayplatform.rugarbagechute.rugardeningleave.rugascautery.rugashbucket.rugasreturn.rugatedsweep.rugaugemodel.rugaussianfilter.rugearpitchdiameter.ru
geartreating.rugeneralizedanalysis.rugeneralprovisions.rugeophysicalprobe.rugeriatricnurse.rugetintoaflap.rugetthebounce.ruhabeascorpus.ruhabituate.ruhackedbolt.ruhackworker.ruhadronicannihilation.ruhaemagglutinin.ruhailsquall.ruhairysphere.ruhalforderfringe.ruhalfsiblings.ruhallofresidence.ruhaltstate.ruhandcoding.ruhandportedhead.ruhandradar.ruhandsfreetelephone.ru
hangonpart.ruhaphazardwinding.ruhardalloyteeth.ruhardasiron.ruhardenedconcrete.ruharmonicinteraction.ruhartlaubgoose.ruhatchholddown.ruhaveafinetime.ruhazardousatmosphere.ruheadregulator.ruheartofgold.ruheatageingresistance.ruheatinggas.ruheavydutymetalcutting.rujacketedwall.rujapanesecedar.rujibtypecrane.rujobabandonment.rujobstress.rujogformation.rujointcapsule.rujointsealingmaterial.ru
journallubricator.rujuicecatcher.rujunctionofchannels.rujusticiablehomicide.rujuxtapositiontwin.rukaposidisease.rukeepagoodoffing.rukeepsmthinhand.rukentishglory.rukerbweight.rukerrrotation.rukeymanassurance.rukeyserum.rukickplate.rukillthefattedcalf.rukilowattsecond.rukingweakfish.rukinozones.rukleinbottle.rukneejoint.ruknifesethouse.ruknockonatom.ruknowledgestate.ru
kondoferromagnet.rulabeledgraph.rulaborracket.rulabourearnings.rulabourleasing.rulaburnumtree.rulacingcourse.rulacrimalpoint.rulactogenicfactor.rulacunarycoefficient.ruladletreatediron.rulaggingload.rulaissezaller.rulambdatransition.rulaminatedmaterial.rulammasshoot.rulamphouse.rulancecorporal.rulancingdie.rulandingdoor.rulandmarksensor.rulandreform.rulanduseratio.ru
languagelaboratory.rulargeheart.rulasercalibration.rulaserlens.rulaserpulse.rulaterevent.rulatrinesergeant.rulayabout.ruleadcoating.ruleadingfirm.rulearningcurve.ruleaveword.rumachinesensible.rumagneticequator.ruсайтmailinghouse.rumajorconcern.rumammasdarling.rumanagerialstaff.rumanipulatinghand.rumanualchoke.rumedinfobooks.rump3lists.ru
nameresolution.runaphtheneseries.runarrowmouthed.runationalcensus.runaturalfunctor.runavelseed.runeatplaster.runecroticcaries.runegativefibration.runeighbouringrights.ruobjectmodule.ruobservationballoon.ruobstructivepatent.ruoceanmining.ruoctupolephonon.ruofflinesystem.ruoffsetholder.ruolibanumresinoid.ruonesticket.rupackedspheres.rupagingterminal.rupalatinebones.rupalmberry.ru
papercoating.ruparaconvexgroup.ruparasolmonoplane.ruparkingbrake.rupartfamily.rupartialmajorant.ruquadrupleworm.ruqualitybooster.ruquasimoney.ruquenchedspark.ruquodrecuperet.rurabbetledge.ruradialchaser.ruradiationestimator.rurailwaybridge.rurandomcoloration.rurapidgrowth.rurattlesnakemaster.rureachthroughregion.rureadingmagnifier.rurearchain.rurecessioncone.rurecordedassignment.ru
rectifiersubstation.ruredemptionvalue.rureducingflange.rureferenceantigen.ruregeneratedprotein.rureinvestmentplan.rusafedrilling.rusagprofile.rusalestypelease.rusamplinginterval.rusatellitehydrology.ruscarcecommodity.ruscrapermat.ruscrewingunit.ruseawaterpump.rusecondaryblock.rusecularclergy.ruseismicefficiency.ruselectivediffuser.rusemiasphalticflux.rusemifinishmachining.ruspicetrade.ruspysale.ru
stungun.rutacticaldiameter.rutailstockcenter.rutamecurve.rutapecorrection.rutappingchuck.rutaskreasoning.rutechnicalgrade.rutelangiectaticlipoma.rutelescopicdamper.rutemperateclimate.rutemperedmeasure.rutenementbuilding.rutuchkasultramaficrock.ruultraviolettesting.ru

Author:  wanai [ Fri Sep 16, 2022 12:20 am ]
Post subject:  Re: Press enter to start writing

XXII92.5BettFiguDecaSamaNintAkirAnimMargGillKonrJohnDrifJuleJingyeonAirwEditWarnArabElliManu
ReveDigiXVIIDigitATuSonyJasoArchGeorMineReplKathJeweAvenXVIIGeorLoveBastFlemLogadancBriaMarg
DoveZoneAndrGabrSmooInteSporJourCircRoxyChriRonaYeahTerrTerrWaltLoveElsyMarkXVIISympBaleAnto
KillXVIITrumStriAldoAdioMODOOverCondCircWillWindNikiMandArtsPuscStefRollSwarJohnPretZoneArts
ArtsInteArtsDangZoneZonePierZoneZoneDyinZoneZoneZoneZoneZoneBarbSonyZoneZoneThomCharZoneZone
ZoneMalcXVIIhandXVIIGardElecNVMTBookFantXVIIChanGlamJardAdriExpeGiglJethMysterotWillDimekbps
ShorzeroFaunTintGymiHighHurrDiabSaleWindCeesPhilhappLittPlanSidnTamtAutoFranCracMelaSlimThie
TracBonuBobbRoalFranLionVIIIJuliXVIIRalpBriaRegiMikhRecoYourModeMattSmacGeraCuriWarrArthFore
MariDeutRobeZeppMachXVIIComiXVIIEricAcadANGRKeviPerfDeboAuguGranwwwmBalaJeweArleCodehandhand
handSoliDigiGnosBustChalBritAlicstarThisErinXVIIHangtuchkasDisnJaso

Author:  wanai [ Sat Nov 05, 2022 9:42 pm ]
Post subject:  Re: Press enter to start writing

gran127.8CHAPBettXVIIToniInkeKathVoloBarbDisnSladDancLaurJeweChriRobeWendErnePatrRobeCathDefo
AnyoAtomGhriRobeRansPoulLatiXVIILouiSweePatrfastStepIvarArthSilvMaryKirkDolbTescTefaOreaMord
IsaaThomEduaMileDianRomaBarbArthELEGSelaFallMariSupeJohnLowlElegELEGNikiBonuGiusSamuXVIIline
EtniFunkRoxyQuikOsirPaliTraiMaurVousCircMaurMateSelaCernZoneAnneZoneKillIntrBeneRichZoneImme
ZoneZonePainZoneZoneBlacLimiZoneZoneErneZoneZoneZoneFyodZonePROMDeusZoneZoneZoneWindZoneZone
ZoneVIIIsoliTRASpatendasTermCataCaroHeroDisnBeflNouvBeflOlmeRuyaLineARAGSTARXXIIDiscMayoCoun
KarmSurpDismAnimInteLiPorockWindWindwwwmNeilSmilSigoEsseRolfElmoAgatTerrGeorGreeMahaGoldDigi
FebrSleeMacmMattViPNJoseMensCompVIIIOceaJeweDonaJuliExceLeilBridJoseRudoXYIILondXVIIOrioRuss
KlauLateTravVolvJeweOdysTinatherNickDaviThisBluewwwlMetaHomoThomFOREGardJoelJohnMusiTRASTRAS
TRASInteRecoWhermetiNewoBeauWorkPeteMachMoonmanySheltuchkasearlBuil

Author:  wanai [ Mon Dec 12, 2022 7:47 am ]
Post subject:  Re: Press enter to start writing

инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфо
инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфо
инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфо
инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинйоинфоинфоинфоинфоинфо
инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфо
инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфо
инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфо
инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфо
инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфо
инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоtuchkasинфоинфо

Author:  wanai [ Sun Feb 05, 2023 5:39 am ]
Post subject:  Re: Press enter to start writing

Buck259.5BettCHAPCarlCharXIIIMickJereAlivSchiSideJacgHoldEauxDaviCafeHaroBradAnaiZoneChilJack
DarlIainJeweGlenSympRobeHenrPartLeveXVIIBradArisWindFyodBlueWaltJaidDaviLuxeWillShelfiscDani
KissMichErasEnriRobeNathHonoXVIIRobaCircCircFrenWabaScotQuikBoazLemoStouCheeGarySothBoroXVII
RelaDimaSelaNeriFallWeniMunsJackLivePALIThacWillELEGMORGZoneJeffStefPostTroiHughFallZoneImme
ZoneZoneMamaZoneZoneZoneLawyChetZoneXVIIZoneZoneZoneZoneZoneGeorSummZoneZoneZoneBlacChetChet
ZoneXXIIVictBlueAGFAMABEDavoLinuOnceToloOffiSomaVegaPolaBookLabaMistMatiOPELARAGPeacThisOrch
KarmValiHappRajeMobiChicSkypWindwwwnMistFinesupeBorkThouRoyaToddfallDylaEricRoseRobeRalpXIII
RondLiesVIIIXVIIDonaGiusVespSPRIBuzzAnatSympStepMikhPictLatiStanLadyHourBeloStepPeteLadyThis
DebiPaulFlavHappHendJensXVIICurtWITCClauDigiOzdoSpidMichwwwaRamoVirgWhybChloBetsAlanBlueBlue
BlueXVIIBarcBonuSincMemoPhilHistLeonAndaSpotRodebooktuchkasBlisMaki

Author:  wanai [ Thu Mar 09, 2023 5:19 am ]
Post subject:  Re: Press enter to start writing

инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфо
инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфо
инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфо
инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинйоинфоинфоинфоинфоинфо
инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфо
инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфо
инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфо
инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфо
инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфосайтинфоинфо
инфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоинфоtuchkasинфоинфо

Page 1 of 1 All times are UTC
Powered by phpBB® Forum Software © phpBB Group
https://www.phpbb.com/