wiki.sine.space | sinespace

Difference between revisions of "Scripting/SUserProfile"

From wiki.sine.space
Jump to: navigation, search
(Added and defined all members (13) of SUserProfile)
 
(Added simple examples to 12 members in SUserProfile)
Line 2: Line 2:
  
  
{{ScriptFunction|string|About|{ get; }|Get player profile's About|5= <pre></pre>}}
+
{{ScriptFunction|string|About|{ get; }|Get player profile's About|5= <pre>onAuthSuccess = function()
 +
profile.LoadProfile(onProfileLoad)
  
{{ScriptFunction|string|City|{ get; }|Get player profile's City|5= <pre></pre>}}
+
end
  
{{ScriptFunction|string|Country|{ get; }|Get player profile's Country|5= <pre></pre>}}
 
  
{{ScriptFunction|string|Gender|{ get; }|Get player profile's Gender|5= <pre></pre>}}
+
onProfileLoad = function(SUserProfile)
 +
Space.Log(profile.ActivePlayerProfile.About)
 +
Space.Log(SUserProfile.About)
 +
--both ways work
 +
end
  
{{ScriptFunction|string|Interests|{ get; }|Get player profile's Interests|5= <pre></pre>}}
 
  
{{ScriptFunction|string|RealName|{ get; }|Get player profile's Real Name|5= <pre></pre>}}
+
profile = Space.Profile
 +
profile.Authorize(onAuthSuccess)
 +
</pre>}}
  
{{ScriptFunction|string|Since|{ get; }|Get player profile's Since|5= <pre></pre>}}
+
{{ScriptFunction|string|City|{ get; }|Get player profile's City|5= <pre>onAuthSuccess = function()
 +
profile.LoadProfile(onProfileLoad)
  
{{ScriptFunction|int|SocialFlower|{ get; }|Get player profile's Flower count|5= <pre></pre>}}
+
end
  
{{ScriptFunction|int|SocialGold|{ get; }|Get player profile's Gold Badge count|5= <pre></pre>}}
+
 
 +
onProfileLoad = function(SUserProfile)
 +
Space.Log(profile.ActivePlayerProfile.City)
 +
Space.Log(SUserProfile.City)
 +
--both ways work
 +
end
 +
 
 +
 
 +
profile = Space.Profile
 +
profile.Authorize(onAuthSuccess)
 +
</pre>}}
 +
 
 +
{{ScriptFunction|string|Country|{ get; }|Get player profile's Country|5= <pre>onAuthSuccess = function()
 +
profile.LoadProfile(onProfileLoad)
 +
 
 +
end
 +
 
 +
 
 +
onProfileLoad = function(SUserProfile)
 +
Space.Log(profile.ActivePlayerProfile.Country)
 +
Space.Log(SUserProfile.Country)
 +
--both ways work
 +
end
 +
 
 +
 
 +
profile = Space.Profile
 +
profile.Authorize(onAuthSuccess)
 +
</pre>}}
 +
 
 +
{{ScriptFunction|string|Gender|{ get; }|Get player profile's Gender|5= <pre>onAuthSuccess = function()
 +
profile.LoadProfile(onProfileLoad)
 +
 
 +
end
 +
 
 +
 
 +
onProfileLoad = function(SUserProfile)
 +
Space.Log(profile.ActivePlayerProfile.Gender)
 +
Space.Log(SUserProfile.Gender)
 +
--both ways work
 +
end
 +
 
 +
 
 +
profile = Space.Profile
 +
profile.Authorize(onAuthSuccess)
 +
</pre>}}
 +
 
 +
{{ScriptFunction|string|Interests|{ get; }|Get player profile's Interests|5= <pre>onAuthSuccess = function()
 +
profile.LoadProfile(onProfileLoad)
 +
 
 +
end
 +
 
 +
 
 +
onProfileLoad = function(SUserProfile)
 +
Space.Log(profile.ActivePlayerProfile.Interests)
 +
Space.Log(SUserProfile.Interests)
 +
--both ways work
 +
end
 +
 
 +
 
 +
profile = Space.Profile
 +
profile.Authorize(onAuthSuccess)
 +
</pre>}}
 +
 
 +
{{ScriptFunction|string|RealName|{ get; }|Get player profile's Real Name|5= <pre>onAuthSuccess = function()
 +
profile.LoadProfile(onProfileLoad)
 +
 
 +
end
 +
 
 +
 
 +
onProfileLoad = function(SUserProfile)
 +
Space.Log(profile.ActivePlayerProfile.RealName)
 +
Space.Log(SUserProfile.RealName)
 +
 
 +
end
 +
 
 +
 
 +
profile = Space.Profile
 +
profile.Authorize(onAuthSuccess)
 +
</pre>}}
 +
 
 +
{{ScriptFunction|string|Since|{ get; }|Get player profile's Since|5= <pre>onAuthSuccess = function()
 +
profile.LoadProfile(onProfileLoad)
 +
 
 +
end
 +
 
 +
 
 +
onProfileLoad = function(SUserProfile)
 +
Space.Log(profile.ActivePlayerProfile.Since)
 +
Space.Log(SUserProfile.Since)
 +
--both ways work
 +
end
 +
 
 +
 
 +
profile = Space.Profile
 +
profile.Authorize(onAuthSuccess)
 +
</pre>}}
 +
 
 +
{{ScriptFunction|int|SocialFlower|{ get; }|Get player profile's Flower count|5= <pre>onAuthSuccess = function()
 +
profile.LoadProfile(onProfileLoad)
 +
 
 +
end
 +
 
 +
 
 +
onProfileLoad = function(SUserProfile)
 +
Space.Log(profile.ActivePlayerProfile.SocialFlower)
 +
Space.Log(SUserProfile.SocialFlower)
 +
--both ways work
 +
end
 +
 
 +
 
 +
profile = Space.Profile
 +
profile.Authorize(onAuthSuccess)
 +
</pre>}}
 +
 
 +
{{ScriptFunction|int|SocialGold|{ get; }|Get player profile's Gold Badge count|5= <pre>onAuthSuccess = function()
 +
profile.LoadProfile(onProfileLoad)
 +
 
 +
end
 +
 
 +
 
 +
onProfileLoad = function(SUserProfile)
 +
Space.Log(profile.ActivePlayerProfile.SocialGold)
 +
Space.Log(SUserProfile.SocialGold)
 +
--both ways work
 +
end
 +
 
 +
 
 +
profile = Space.Profile
 +
profile.Authorize(onAuthSuccess)
 +
</pre>}}
  
 
{{ScriptFunction|SSocialMedia|SocialMediaProfiles|{ get; }|Get player profile's Social Media Profiles|5= <pre></pre>}}
 
{{ScriptFunction|SSocialMedia|SocialMediaProfiles|{ get; }|Get player profile's Social Media Profiles|5= <pre></pre>}}
  
{{ScriptFunction|int|SocialSilver|{ get; }|Get player profile's Silver Badge count|5= <pre></pre>}}
+
{{ScriptFunction|int|SocialSilver|{ get; }|Get player profile's Silver Badge count|5= <pre>onAuthSuccess = function()
 +
profile.LoadProfile(onProfileLoad)
 +
 
 +
end
 +
 
 +
 
 +
onProfileLoad = function(SUserProfile)
 +
Space.Log(profile.ActivePlayerProfile.SocialSilver)
 +
Space.Log(SUserProfile.SocialSilver)
 +
--both ways work
 +
end
 +
 
 +
 
 +
profile = Space.Profile
 +
profile.Authorize(onAuthSuccess)
 +
</pre>}}
 +
 
 +
{{ScriptFunction|string|Title|{ get; }|Get player profile's Title|5= <pre>onAuthSuccess = function()
 +
profile.LoadProfile(onProfileLoad)
 +
 
 +
end
 +
 
 +
 
 +
onProfileLoad = function(SUserProfile)
 +
Space.Log(profile.ActivePlayerProfile.Title)
 +
Space.Log(SUserProfile.Title)
 +
--both ways work
 +
end
 +
 
 +
 
 +
profile = Space.Profile
 +
profile.Authorize(onAuthSuccess)
 +
</pre>}}
 +
 
 +
{{ScriptFunction|string|UserName|{ get; }|Get player profile's Username|5= <pre>onAuthSuccess = function()
 +
profile.LoadProfile(onProfileLoad)
 +
 
 +
end
 +
 
 +
 
 +
onProfileLoad = function(SUserProfile)
 +
Space.Log(profile.ActivePlayerProfile.UserName)
 +
Space.Log(SUserProfile.UserName)
 +
--both ways work
 +
end
  
{{ScriptFunction|string|Title|{ get; }|Get player profile's Title|5= <pre></pre>}}
 
  
{{ScriptFunction|string|UserName|{ get; }|Get player profile's Username|5= <pre></pre>}}
+
profile = Space.Profile
 +
profile.Authorize(onAuthSuccess)
 +
</pre>}}
  
  

Revision as of 00:54, 7 March 2021

Properties

About

string About { get; }

Get player profile's About

onAuthSuccess = function()
profile.LoadProfile(onProfileLoad)

end


onProfileLoad = function(SUserProfile)
Space.Log(profile.ActivePlayerProfile.About)
Space.Log(SUserProfile.About)
--both ways work
end


profile = Space.Profile
profile.Authorize(onAuthSuccess)


City

string City { get; }

Get player profile's City

onAuthSuccess = function()
profile.LoadProfile(onProfileLoad)

end


onProfileLoad = function(SUserProfile)
Space.Log(profile.ActivePlayerProfile.City)
Space.Log(SUserProfile.City)
--both ways work
end


profile = Space.Profile
profile.Authorize(onAuthSuccess)


Country

string Country { get; }

Get player profile's Country

onAuthSuccess = function()
profile.LoadProfile(onProfileLoad)

end


onProfileLoad = function(SUserProfile)
Space.Log(profile.ActivePlayerProfile.Country)
Space.Log(SUserProfile.Country)
--both ways work
end


profile = Space.Profile
profile.Authorize(onAuthSuccess)


Gender

string Gender { get; }

Get player profile's Gender

onAuthSuccess = function()
profile.LoadProfile(onProfileLoad)

end


onProfileLoad = function(SUserProfile)
Space.Log(profile.ActivePlayerProfile.Gender)
Space.Log(SUserProfile.Gender)
--both ways work
end


profile = Space.Profile
profile.Authorize(onAuthSuccess)


Interests

string Interests { get; }

Get player profile's Interests

onAuthSuccess = function()
profile.LoadProfile(onProfileLoad)

end


onProfileLoad = function(SUserProfile)
Space.Log(profile.ActivePlayerProfile.Interests)
Space.Log(SUserProfile.Interests)
--both ways work
end


profile = Space.Profile
profile.Authorize(onAuthSuccess)


RealName

string RealName { get; }

Get player profile's Real Name

onAuthSuccess = function()
profile.LoadProfile(onProfileLoad)

end


onProfileLoad = function(SUserProfile)
Space.Log(profile.ActivePlayerProfile.RealName)
Space.Log(SUserProfile.RealName)

end


profile = Space.Profile
profile.Authorize(onAuthSuccess)


Since

string Since { get; }

Get player profile's Since

onAuthSuccess = function()
profile.LoadProfile(onProfileLoad)

end


onProfileLoad = function(SUserProfile)
Space.Log(profile.ActivePlayerProfile.Since)
Space.Log(SUserProfile.Since)
--both ways work
end


profile = Space.Profile
profile.Authorize(onAuthSuccess)


SocialFlower

int SocialFlower { get; }

Get player profile's Flower count

onAuthSuccess = function()
profile.LoadProfile(onProfileLoad)

end


onProfileLoad = function(SUserProfile)
Space.Log(profile.ActivePlayerProfile.SocialFlower)
Space.Log(SUserProfile.SocialFlower)
--both ways work
end


profile = Space.Profile
profile.Authorize(onAuthSuccess)


SocialGold

int SocialGold { get; }

Get player profile's Gold Badge count

onAuthSuccess = function()
profile.LoadProfile(onProfileLoad)

end


onProfileLoad = function(SUserProfile)
Space.Log(profile.ActivePlayerProfile.SocialGold)
Space.Log(SUserProfile.SocialGold)
--both ways work
end


profile = Space.Profile
profile.Authorize(onAuthSuccess)


SocialMediaProfiles

SSocialMedia SocialMediaProfiles { get; }

Get player profile's Social Media Profiles


SocialSilver

int SocialSilver { get; }

Get player profile's Silver Badge count

onAuthSuccess = function()
profile.LoadProfile(onProfileLoad)

end


onProfileLoad = function(SUserProfile)
Space.Log(profile.ActivePlayerProfile.SocialSilver)
Space.Log(SUserProfile.SocialSilver)
--both ways work
end


profile = Space.Profile
profile.Authorize(onAuthSuccess)


Title

string Title { get; }

Get player profile's Title

onAuthSuccess = function()
profile.LoadProfile(onProfileLoad)

end


onProfileLoad = function(SUserProfile)
Space.Log(profile.ActivePlayerProfile.Title)
Space.Log(SUserProfile.Title)
--both ways work
end


profile = Space.Profile
profile.Authorize(onAuthSuccess)


UserName

string UserName { get; }

Get player profile's Username

onAuthSuccess = function()
profile.LoadProfile(onProfileLoad)

end


onProfileLoad = function(SUserProfile)
Space.Log(profile.ActivePlayerProfile.UserName)
Space.Log(SUserProfile.UserName)
--both ways work
end


profile = Space.Profile
profile.Authorize(onAuthSuccess)