Jump to content

How to test my script...


guix

Recommended Posts

Yes, it is.

Run multiple clients

There are times you need more than 1 person to test your script. An example would be team game menus that react differently once another person has joined. It is a luxury to get someone to hang around and test while you debug even part of the time. What you can do is use a virtual machine...

Switch user (Tested on Win7 Ultimate / nvidia 9800 GTX / MTA 1.0.4 only!)

You can run GTASA/MTASA from multiple Windows accounts and log them into the same server using 127.0.0.1 ... just setup another user account and use switch user, DO NOT use log off. This seems to lead to network trouble in my testing, but you can still use it for script testing with full frame rate.

Switch user not working in 1.0.5 for unknown reasons

Virtual Machines

The Short Answer:

You need to use VirtualBox (free software) and follow the instructions HERE.

p.s. You cannot connect locally to 127.0.0.1 as your virtual machine has its own virtual loopback for that address referring to itself. On your actual machine do start>run>ipconfig and use your router address in the virtual machine. Ex: 192.168.0.102 22003 ... alternatively if this does not work you can try your ISP IP. Goto whatismyip and use that address in the virtual machine. Ex: 73.114.81.112 22003

p.p.s. People with nVidia cards using 260.xx drivers: Do not enable 2D and 3D acceleration at the same time or you will run into THIS BUG ... for MTA you only need 3D acceleration. If you really want both, revert to 259.xx nVidia drivers.

p.p.p.s. Make sure you turn the GFX settings to minimal, especially draw distance. Note very low frame rate can mess up shooting sync.

The Long Answer:

The two big virtual machine softwares are vmware (most popular and not free) and virtualbox (open source and free).

  • VMWare (Tested on VMware Workstation 7.1.2 build-301548 / Host Machine: Win7 Ultimate / Virtual: WINXP SP3 / nvidia 9800 GTX / MTA 1.0.4)
    From my testing, vmware will flicker and freeze on 1 frame of the MTA menu and black screen ingame. It works with GTASA but not MTASA. From my VMWare research this problem is related to refresh rates and emulating vsync (a physical monitor property). If you do start>run>dxdiag, display tab, "Test Direct3D" the spinning DirectX cube will be going insanely fast. This should not happen.
  • VirtualBox (Tested on 4.0.4 r70112 / Host Machine: Win7 Ultimate / Virtual: WINXP SP3 / nvidia 9800 GTX / MTA 1.0.4)
    I tested it in the same manner as above. The dxdiag "Test Direct3D" will show a DirectX cube spinning at normal speed. A drawback I have noticed is that VMWare was running GTASA at a better framerate than VirtualBox could. However, VMWare will not work for MTA as explained above. VirtualBox will work fine.

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...