Hi, is there an instruction manual for learn how to write code for the script?
Thanks.
Posted 23 October 2023 - 06:26 PM
Posted 24 October 2023 - 01:57 PM
Take a look at the file vbsdoc_outdated.html which is the explanations of the calls to the core.vbs. Even if it is called "outdated" it is very very useful.
Also take a look at the CommandReference.txt for all the extra vbscript commands VPX understands.
The files are available in the vpx zip file.
If you want to check my latest uploads then click on the image below:
Next table? A tribute table to Stern's Foo Fighters
Posted 25 October 2023 - 09:51 PM
Thanks. But let me to say, it is not so good.
Anyway, let me to know if I've understood one thing.
In the script there are only sub.
These sub are called when an event happens (i.e. a target is hit)
So, with the sub we can manage, the sound, the score and the rules of the game.
Am I correct?
If I am, which is the file where these sub are called?
Thanks.
Edited by boriskarloff, 25 October 2023 - 10:56 PM.
Posted 26 October 2023 - 12:16 PM
Thanks. But let me to say, it is not so good.
Anyway, let me to know if I've understood one thing.
In the script there are only sub.
These sub are called when an event happens (i.e. a target is hit)
So, with the sub we can manage, the sound, the score and the rules of the game.
Am I correct?
If I am, which is the file where these sub are called?
Thanks.
They could be files located in a specific folder, but generally they almost never are,
Images and sounds are imported within VP into the Image and Sound Manager.
In the case of VPinMame tables the scripts connect the mechanical and electrical part created in the VP editor with the ROM,
acting as an interface between VP and the emulator,
the ROM manages sound effects, scores, rules, display/DMD, lights, flippers, solenoids...
Instead, in the case of the original or electromechanical tables, the scripts manage every aspect, sounds, scores, rules, lights, etc.
Posted 26 October 2023 - 08:16 PM
Maybe what you ask is how the script works, and maybe you need and introduction to VBScript, since that is the programming language VPX uses for the scripts. Something like here:
VBScript Tutorial (tutorialspoint.com)
VBScript was designed to used with Internet Explorer and the Office programs, so the tutorials used to have a lot of display thing we don't use in VPX. Still it is good to go though a VBScript tutorial, just to learn the basics. Then VPX has a lot of extra commands to handle all the ball hit events, and also to handle to communications with a rom, as there are tables using a rom and tables which do not use a rom (the so called originals and/or EM tables).
If you want to check my latest uploads then click on the image below:
Next table? A tribute table to Stern's Foo Fighters
Posted 26 October 2023 - 10:26 PM
Thanks, maybe I try to ask in another way.
In your Ghostbusters pinball script there is: Sub RealTime_Timer (or any other Sub, i.e. sw1_Hit() )
Who calls this Sub? Where is the file calls this Sub?
Thanks.
the timer itself calls the sub, as long as the timer is enabled
If you feel the need to empty your wallet in my direction, i don't have any way to receive it anyways
Spend it on Hookers and Blow
Posted 27 October 2023 - 08:26 AM
Thanks, maybe I try to ask in another way.
In your Ghostbusters pinball script there is: Sub RealTime_Timer (or any other Sub, i.e. sw1_Hit() )
Who calls this Sub?
Thanks.
Or within another subroutine there is the call that activates the timer.
RealTime.Enabled = 1
Sw1 could be a switch (rollover, optocoupler, target), and it is activated when the ball hits it.
Posted 27 October 2023 - 08:42 AM
in VPX terms, sw1 is a table object that is collidable and is set to have a hit event.
can be a wall or a switch or a target or a kicker or bumper etc
objects can also have an objectname_unhit event
useful for like a kicker, where the ball may sit there for a time
can also be useful for switches, if they are tracking the existence of a stationary ball, but usually a kicker is used for that to prevent a ball that is constantly bobbling around
but could be used to check what position a captive ball is in, as those balls are not locked. Like in big bang bar
slingshots have an event but it is objectname_slingshot
which is more useful since a slingshot generally only has an event when it is hit hard enough to trigger it
Edited by wiesshund, 27 October 2023 - 08:45 AM.
If you feel the need to empty your wallet in my direction, i don't have any way to receive it anyways
Spend it on Hookers and Blow
Posted 28 October 2023 - 01:53 PM
Posted 28 October 2023 - 02:54 PM
Edited by Fusionwerks, 28 October 2023 - 02:56 PM.
Visual Pinball →
Visual Pinball →
Detecting Uninitialized UserValueStarted by Two , 08 May 2025 |
|
||
Visual Pinball →
Visual Pinball →
Set DOF Intensity using Table Script?Started by Ltek , 04 Jun 2024 |
|
||
Visual Pinball →
Visual Pinball →
Let's fix PizzaTime!Started by gamerplayer861 , 13 Mar 2024 |
|
||
Visual Pinball →
VP Help Center →
How to change a drop targets state in scriptStarted by Jackmc7r , 12 Mar 2024 |
|
||
Visual Pinball →
Visual Pinball →
Shader::CompileGLShader@1113 error at any table i try to runStarted by SingingCoyote13 , 12 Mar 2024 |
|