Wayback Machinekoobas.hobune.stream
May JUN Jul
Previous capture 13 Next capture
2021 2022 2023
1 capture
13 Jun 22 - 13 Jun 22
sparklines
Close Help
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
  • Asset Store
  • Get Unity

UNITY ACCOUNT

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account
  • Blog
  • Forums
  • Answers
  • Evangelists
  • User Groups
  • Beta Program
  • Advisory Panel

Navigation

  • Home
  • Products
  • Solutions
  • Made with Unity
  • Learning
  • Support & Services
  • Community
    • Blog
    • Forums
    • Answers
    • Evangelists
    • User Groups
    • Beta Program
    • Advisory Panel

Unity account

You need a Unity Account to shop in the Online and Asset Stores, participate in the Unity Community and manage your license portfolio. Login Create account

Language

  • Chinese
  • Spanish
  • Japanese
  • Korean
  • Portuguese
  • Ask a question
  • Spaces
    • Default
    • Help Room
    • META
    • Moderators
    • Topics
    • Questions
    • Users
    • Badges
  • Home /
avatar image
0
Question by Nine · May 10, 2014 at 05:23 PM · dllplaystationmissingmethodexception

PSM MissingMethodException in Sce.PlayStation.Core.dll

I just downloaded the new PSM Unity beta and the newest PSM sdk and have been trying to get code for input from the Vita to work. Everything builds fine in Mono but when I try and run the game in Unity, I get the following error:

MissingMethodException: Cannot find the requested method. Sce.PlayStation.Core.Input.GamePad.GetData (Int32 deviceIndex)

I have added the dll to my project and it is visible in both Unity and monodevelop. I have tried switching the API Compatibility Level from 2.0 Subset to 2.0 and renaming the dll but those attempts did nothing. I am not sure what else I should try.

Here is my code:

 using UnityEngine;
 using System.Collections;
 using Sce.PlayStation.Core.Input;
 
 public class ThirdPersonCamera : MonoBehaviour
 {
     void Start()
     {
         
     }
     
     void FixedUpdate ()
     {
         var gamePadData = GamePad.GetData(0);
         transform.position += transform.forward * 2f * gamePadData.AnalogLeftY;
     }
 }


The call to GamePad.GetData(0) is what cannot be found.

Thanks for any help!

Comment
Add comment · Show 2
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users
avatar image Graham-Dunnett ♦♦ · May 10, 2014 at 08:19 PM 0
Share

If you declare gamePadData to have type GamePadData does that help? I've not used PS$$anonymous$$ but wonder if it's just the compiler is confused looking for the right function.

avatar image Nine · May 10, 2014 at 08:51 PM 0
Share

No that didn't work.. $$anonymous$$aybe something is wrong with my environment...

1 Reply

· Add your reply
  • Sort: 
avatar image
0
Best Answer

Answer by Nine · May 12, 2014 at 02:05 PM

You can't use the PSM SDK libraries in Unity (like Sce.PlayStation.Core.Input etc), you have to use Unity's own Input class and the key and axis assignements here. So for your example you would set up the Y axis in the Unity Input Manager, give it a name, such as "LeftStickVitaY", then use:

 transform.position += transform.forward * 2f * Input.GetAxis("LeftStickVitaY");

As a side note, you possibly want to be doing movement stuff in Update() and multiplying by Time.deltaTime to get smooth motion, rather than using FixedUpdate().

Comment
Add comment · Share
10 |3000 characters needed characters left characters exceeded
▼
  • Viewable by all users
  • Viewable by moderators
  • Viewable by moderators and the original poster
  • Advanced visibility
Viewable by all users

Your answer

Hint: You can notify a user about this post by typing @username

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this Question

Answers Answers and Comments

21 People are following this question.

avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image avatar image

Related Questions

Azure AD B2C - MissingMethodException: string[] string.Split(char,System.StringSplitOptions) in Microsoft.Identity.Client on Android 0 Answers

Why can't I build Web Player in Unity while I have no problems with building standalone versions? 2 Answers

Equality and Inequality operators not found in DLL ??? 1 Answer

Custom DLL - MissingMethodException: string[] string.Split 3 Answers

'EventSystems' does not exist in the namespace 'UnityEngine'... 1 Answer


Enterprise
Social Q&A

Social
Subscribe on YouTube social-youtube Follow on LinkedIn social-linkedin Follow on Twitter social-twitter Follow on Facebook social-facebook Follow on Instagram social-instagram

Footer

  • Purchase
    • Products
    • Subscription
    • Asset Store
    • Unity Gear
    • Resellers
  • Education
    • Students
    • Educators
    • Certification
    • Learn
    • Center of Excellence
  • Download
    • Unity
    • Beta Program
  • Unity Labs
    • Labs
    • Publications
  • Resources
    • Learn platform
    • Community
    • Documentation
    • Unity QA
    • FAQ
    • Services Status
    • Connect
  • About Unity
    • About Us
    • Blog
    • Events
    • Careers
    • Contact
    • Press
    • Partners
    • Affiliates
    • Security
Copyright © 2020 Unity Technologies
  • Legal
  • Privacy Policy
  • Cookies
  • Do Not Sell My Personal Information
  • Cookies Settings
"Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
  • Anonymous
  • Sign in
  • Create
  • Ask a question
  • Spaces
  • Default
  • Help Room
  • META
  • Moderators
  • Explore
  • Topics
  • Questions
  • Users
  • Badges