playMaker

Author Topic: microphone api custom actions  (Read 12205 times)

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
microphone api custom actions
« on: June 16, 2012, 04:34:28 AM »
Hi,

 Ok, after a user request:
http://hutonggames.com/playmakerforum/index.php?topic=1739.msg7668#msg7668

 Please find a set of custom actions to work with the microphone right within playmaker.

 I have a sample ready, but can't sahre it for now, there are some issue with exporting events, so I will provide as soon as I have managed to create a proper package.

 I have also created actions to request web am and microphone access, mandatory to start using it, it's in the package.

I have also created an arrayMaker action to store the available devices in a list, download is separate, cause you will need arrayMaker installed, else it will throw errors.

Meanwhile, if you need help on how to set it up, don't hesitate, it's anyway very simple, provide an audio source, start recording, and it will create an audioclip automatically, then play the sound back as normal.

Bye,

 Jean

nilton_felicio

  • Playmaker Newbie
  • *
  • Posts: 16
Re: microphone api custom actions
« Reply #1 on: June 16, 2012, 07:18:26 AM »
Hello Jean.
When developing optimal actions.
Congratulations.

All custom actions could not be a single place such as in FogBugz. Organized as the official actions. I'm not saying to get together, I mean to have the same organization as that https://hutonggames.fogbugz.com/default.asp?W2. I'm just giving a suggestion. Would be easier to search organized by category.

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: microphone api custom actions
« Reply #2 on: June 16, 2012, 09:53:50 AM »
Hi,

 Custom actions are not official, some became oart of the official state tho, but for the rest, i think it should remain separated.

 You are correct tho for better organization, Infact i already started a wiki page to do just that, and simply never think of doing it straight away... My bad, will start doing so.
https://hutonggames.fogbugz.com/default.asp?W547

I do plan to gather actions and put them in that page. If you want participate, you are all welcome, this is a community wiki, so simply request access, and you'll be able to contribute. Currently, there is around 150 custom actions just in the dedicated forum section, so testing/validating them, and reference them is a involving task indeed.

It's been discussed anyway, so hopefully, fture version of playmaker could provide a convenient system right in the editor to search, and install custom actions and packs.

Bye,

Jean

nilton_felicio

  • Playmaker Newbie
  • *
  • Posts: 16
Re: microphone api custom actions
« Reply #3 on: June 16, 2012, 11:23:54 AM »
This is great.

I do not know where I could help.
But I would rather help.
150 custom actions organized this wiki as opposed to around the forum would be better. The search would be perfect.
Forum could stay for clarifications, questions the actions .....

cptsvim

  • Playmaker Newbie
  • *
  • Posts: 14
Re: microphone api custom actions
« Reply #4 on: July 04, 2012, 06:16:02 AM »
Hi there,

Thanks for those nice actions!

I´m trying to setup something like "talking tom"

Since I´m quite new to this it´s a bit hard.

I would be so happy if someone could help me out.

Best

Tony










jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: microphone api custom actions
« Reply #5 on: July 05, 2012, 04:12:56 AM »
Hi,

 check out the fully working sample here:

http://hutonggames.com/playmakerforum/index.php?topic=1886.msg8279#msg8279

Bye,

 Jean

rik

  • Full Member
  • ***
  • Posts: 246
Re: microphone api custom actions
« Reply #6 on: December 01, 2014, 06:01:36 AM »
Hi jean i tried to save record audio but i can record this but not able to save.
i have tested your demo record and play but does not make audio files
can you make this action that can be save audio file.

hope this will be modified according to the changes.

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: microphone api custom actions
« Reply #7 on: December 22, 2014, 03:52:10 AM »
Hi,

 it depends your targeted platform? are you going for mobile, web or desktop?

 Bye,

 Jean

rik

  • Full Member
  • ***
  • Posts: 246
Re: microphone api custom actions
« Reply #8 on: December 24, 2014, 11:21:32 AM »
hi i am working for mobile

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: microphone api custom actions
« Reply #9 on: January 19, 2015, 01:48:45 AM »
Hi,

 ok, Please bump this early february, I am going on holiday now, but I think it's important I address this indeed.  Mobile has unique ways to deal with file storage, so indeed a custom solution will need to be studied.

 Bye,

 Jean

Padenlee

  • Junior Playmaker
  • **
  • Posts: 63
  • You can't hit what you don't shoot for!
Re: microphone api custom actions
« Reply #10 on: January 01, 2017, 06:33:38 PM »
Hey Jean!

I'm bumping this thread.

The actions for Microphone Start/Stop recording are not working on iOS. The permissions dialog window does not appear, along with there not being a permission request in the iPhones Settings>Privacy>Microphone.

I have checked Prepare Microphone For Recording box, along with adding a Microphone Description.

The actions do work for PC though.

Thanks for the help in advance, I know you're super busy :)
-Paden Pierry
@padenpierry
Apple inc.'s first TV show, EP 1.
Game Dev since 2007
Coolest client: Bridgestone

Padenlee

  • Junior Playmaker
  • **
  • Posts: 63
  • You can't hit what you don't shoot for!
Re: Microphone api custom actions
« Reply #11 on: January 02, 2017, 03:03:34 PM »
[WORKAROUND]

I have a workaround for iOS to get the microphone recording.

I created a script that has 2 functions and 1 public audio clip variable. Use the action Send Message to send the function name RecordStart to the RecordMicrophone.cs script. After a Wait action for the record time wanted, transition to a new State. Then use another Send Message action to send the function name RecordStop to stop the recording.

Once RecordStop is called, it will add the recorded object audio file to a public variable. Now use Get Property to get the object audio clip from the script RecordMicrophone.cs

You'll also need to setup the Linker Wizard to make sure the Get/Set Property actions work on iOS.

This uses code to start, stop and save the audio file into something Playmaker can use. I'm really new to C# so the code might not be the best, but I wanted to help anyone that will read this thread in the future :)
-Paden Pierry
@padenpierry
Apple inc.'s first TV show, EP 1.
Game Dev since 2007
Coolest client: Bridgestone

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: microphone api custom actions
« Reply #12 on: January 09, 2017, 03:06:07 AM »
Hi,

 thanks for this!!

Bye,

 Jean

nuxvomo

  • Playmaker Newbie
  • *
  • Posts: 30
  • Indy based indie producer of Nights of Yore
    • Nights of Yore
Re: microphone api custom actions
« Reply #13 on: January 02, 2021, 12:03:57 AM »
Sorry to resurrect this old topic.
Is there an action similar to "Request Web Cam And Mic Access" that is just for Mic Access?
Or could somebody help me with moding this action's script or creating a new one for just Mic?
I don't need Cam for my project and would hate to freak out people with unnecessary permissions.
Developing for Mobile btw.
Thanks!
Producer of Nights of Yore, a streamlined tabletop role-playing game for Android and PC
http://nightsofyore.com/

Micah

  • Playmaker Newbie
  • *
  • Posts: 30
Re: microphone api custom actions
« Reply #14 on: January 11, 2021, 01:57:21 PM »
I'm still trying to get this to work but got these errors.

Assets\PlayMaker Custom Actions\Microphone\MicrophoneGetDevicestoArrayList1.cs(16,3): error CS0579: Duplicate 'ActionCategory' attribute

Assets\PlayMaker Custom Actions\Microphone\MicrophoneGetDevicestoArrayList1.cs(16,3): error CS0579: Duplicate 'ActionCategory' attribute

Assets\PlayMaker Custom Actions\Microphone\MicrophoneGetDevicestoArrayList1.cs(17,3): error CS0579: Duplicate 'Tooltip' attribute

Assets\PlayMaker Custom Actions\Microphone\MicrophoneGetDevicestoArrayList1.cs(30,24): error CS0111: Type 'MicrophoneGetDevicesToArrayList' already defines a member called 'Reset' with the same parameter types

Assets\PlayMaker Custom Actions\Microphone\MicrophoneGetDevicestoArrayList1.cs(37,24): error CS0111: Type 'MicrophoneGetDevicesToArrayList' already defines a member called 'OnEnter' with the same parameter types

I have array maker