dubiousintent Posted June 14, 2020 Share Posted June 14, 2020 If that was your entire script, then I'm amazed it "saved" (compiled) at all. No wonder you were not understanding the Tip about "Blocks". Your script doesn't have any. (Don't feel bad about this. It just means you are missing some fundamentals and need to learn a few more things.) Start by reading the "Scripting for Beginners" wiki article. [Edit: fixed wiki link.] Then look more closely at everything in the beginning of the "Scripting" section of the wiki "Getting started creating mods using GECK" article before the first "Tip". Those are all tutorials on various aspects of creating scripts (in alphabetical order). It is intended that you will pick and choose which seems more relevant to your situation at the moment; not that you read them from the first to the last. But it is essential to understand that "coding" is all about precision. A computer is both every dumb and very fast. It's only as clever as it's programming. It will do exactly what you tell it to do, very quickly, and without question. But if you are not crystal clear (using the terminology of the programming environment you are using, which in this case is the "GECK") about what you tell it to do, then it will still attempt to do what you told it, exactly as you told it. The results (and failures) are all down to how clearly you expressed your desires. (There is a reason the "Scripting" section is the largest in that wiki article.) Code instructions are performed sequentially, one at a time, one after the other. Sometimes those instructions need to "pause" to branch depending upon "conditional tests" the results of which determine which set of instructions it takes next. This requires that more than one pass through that section of code is needed. For this reason the code is grouped into "blocks" of instructions, and each block is processed in a single pass (frame) at a time, but some portions may be temporarily suspended between one pass and the next to await the results of some things occurring/processed in the previous pass/frame and require multiple "passes/frames" to process completely. At this point I'm going to direct you to the previously linked article. Feel free to ask questions about anything which is not clear. -Dubious- Link to comment Share on other sites More sharing options...
UnvalidUserName Posted June 14, 2020 Share Posted June 14, 2020 In GECK all script, except queststage results script, start with begin command and take a blocktype as argument, then end with end command. Your script is missing those. The links provided by dubious should help you learn how to choose the blocktype you need. Link to comment Share on other sites More sharing options...
Deltagamer163 Posted June 23, 2020 Author Share Posted June 23, 2020 dubious, your scripting for beginners link just takes me to a mod. I appreciate the help, though! Link to comment Share on other sites More sharing options...
Mktavish Posted June 23, 2020 Share Posted June 23, 2020 In GECK all script, except queststage results script, start with begin command and take a blocktype as argument, then end with end command. Your script is missing those. The links provided by dubious should help you learn how to choose the blocktype you need. Why do you even try anymore ? You always get at least one point wrong. quest stage the only place for result script ??? Hehe haha ... Your vigor is great ... but you are defined by knowing just enough to be dangerous.Hence the Homer avatar , if it's on purpose ? Link to comment Share on other sites More sharing options...
Mktavish Posted June 23, 2020 Share Posted June 23, 2020 dubious, your scripting for beginners link just takes me to a mod. I appreciate the help, though! I tried sorting your problem , and I concluded I need you to re affirm if there is a chance to help you.Because there is no point in me dribbling on unless it is helping you. And trust me ... I can dribble.Cuz then next thing ya know we'll be talking about your aunt and her tea parties in a tower looking over Venice , while fisherman hurriedly bring their catch to market. Link to comment Share on other sites More sharing options...
dubiousintent Posted June 23, 2020 Share Posted June 23, 2020 dubious, your scripting for beginners link just takes me to a mod. I appreciate the help, though!Sorry about that. Don't know what happened, but the link is fixed now. -Dubious- Link to comment Share on other sites More sharing options...
UnvalidUserName Posted June 23, 2020 Share Posted June 23, 2020 Mktavish the only place where you can get a script to run without a begin command is in the result script section of a quest. Link to comment Share on other sites More sharing options...
Deltagamer163 Posted June 24, 2020 Author Share Posted June 24, 2020 So what would I place in the begin code? The script is written in a terminal, so I had assumed it would begin when the button was clicked. Link to comment Share on other sites More sharing options...
dubiousintent Posted June 25, 2020 Share Posted June 25, 2020 (edited) Have you seen the "How to make a terminal in Fallout 3 DO something" tutorial?Edit: Also "GECK Tutorial - Terminals" video. -Dubious- Edited June 25, 2020 by dubiousintent Link to comment Share on other sites More sharing options...
UnvalidUserName Posted June 25, 2020 Share Posted June 25, 2020 (edited) Well. Going all the way back to your original problem. I don't see why this script wouldn't work assuming it's on the item result script section of your terminal.You shouldn't need a blocktype there, I'm sorry if we mislead you.However what I would try changing is the following.Try with an integer instead of a float AND try doing the division before attempting to add the chips.In my experience, GECK sometimes has a hard time interpreting inline mathematical operations. Edit: What I mean by that: long RoomChipCountlong ChipPayout set RoomChipCount to (Player.GetItemCount RoomChip)set ChipPayout to (RoomChipCount / 10) Player.AddItem TheTopsChip ChipPayoutPlayer.RemoveItem RoomChip RoomChipCount Edited June 25, 2020 by UnvalidUserName Link to comment Share on other sites More sharing options...
Recommended Posts