Jump to content
This site uses cookies! Learn More

This site uses cookies!

armedunity.com uses cookies to improve user experience.

By continuing to use this site, you agree to allow us to store cookies on your computer.

  • 0
Sign in to follow this  

Calling non-static function from a static function


Hi. So basically I want to call a non-static function from a static function. I have done that by creating a new instance of class named "TemporaryLink" and then calling my non-static function "AddToLink". 


I have a string a string in TemporaryLink class named "taskName" which has to stay the same after I call AddToLink function. Right now it creates a new instance of TemporaryLink and taskName is the same as if it was never changed. (taskName is being changed with textField in OnGUI function)


What should I do to fix this problem? Thank you :)

Please login or register to see this code.


Edited by CakeMonsTv

Share this post

Link to post
Share on other sites

1 answer to this question

Recommended Posts

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Create New...