Skip to content

Commit

Permalink
script
Browse files Browse the repository at this point in the history
  • Loading branch information
ehsankamrani committed Dec 23, 2023
1 parent f972f97 commit 877a5e4
Show file tree
Hide file tree
Showing 12 changed files with 234 additions and 0 deletions.
20 changes: 20 additions & 0 deletions Sample Scripts/APIs/GetPrefabInstanceAmbient1.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
--Copyright (C) 2023 Ehsan Kamrani
--This file is licensed and distributed under MIT license

--Explanations: https://vanda3d.org/getprefabinstanceambient/

r = 0.0
g = 0.0
b = 0.0

function Init()
r, g, b = GetPrefabInstanceAmbient("1_VandaEngine17-SamplePack1_wood_pile")

message = string.format("\nAmbient color is : (%.2f, %.2f, %.2f)", r, g, b)
PrintConsole(message)
end

function Update()

end

22 changes: 22 additions & 0 deletions Sample Scripts/APIs/GetPrefabInstanceAmbient2.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
--Copyright (C) 2023 Ehsan Kamrani
--This file is licensed and distributed under MIT license

--Explanations: https://vanda3d.org/getprefabinstanceambient/

--Name of script is GetPrefabInstanceAmbient2.lua

r = 0.0
g = 0.0
b = 0.0

function Init()
r, g, b = GetPrefabInstanceAmbient("this")

message = string.format("\nAmbient color is : (%.2f, %.2f, %.2f)", r, g, b)
PrintConsole(message)
end

function Update()

end

19 changes: 19 additions & 0 deletions Sample Scripts/APIs/GetPrefabInstanceDiffuse1.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
--Copyright (C) 2023 Ehsan Kamrani
--This file is licensed and distributed under MIT license

--Explanations: https://vanda3d.org/getprefabinstancediffuse/

r = 0.0
g = 0.0
b = 0.0

function Init()
r, g, b = GetPrefabInstanceDiffuse("1_VandaEngine17-SamplePack1_wood_pile")

message = string.format("\nDiffuse color is : (%.2f, %.2f, %.2f)", r, g, b)
PrintConsole(message)
end

function Update()

end
21 changes: 21 additions & 0 deletions Sample Scripts/APIs/GetPrefabInstanceDiffuse2.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
--Copyright (C) 2023 Ehsan Kamrani
--This file is licensed and distributed under MIT license

--Explanations: https://vanda3d.org/getprefabinstancediffuse/

-- Name of script is GetPrefabInstanceDiffuse2.lua

r = 0.0
g = 0.0
b = 0.0

function Init()
r, g, b = GetPrefabInstanceDiffuse("this")

message = string.format("\nDiffuse color is : (%.2f, %.2f, %.2f)", r, g, b)
PrintConsole(message)
end

function Update()

end
19 changes: 19 additions & 0 deletions Sample Scripts/APIs/GetPrefabInstanceEmission1.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
--Copyright (C) 2023 Ehsan Kamrani
--This file is licensed and distributed under MIT license

--Explanations: https://vanda3d.org/getprefabinstanceemission/

r = 0.0
g = 0.0
b = 0.0

function Init()
r, g, b = GetPrefabInstanceEmission("1_VandaEngine17-SamplePack1_wood_pile")

message = string.format("\nEmission color is : (%.2f, %.2f, %.2f)", r, g, b)
PrintConsole(message)
end

function Update()

end
21 changes: 21 additions & 0 deletions Sample Scripts/APIs/GetPrefabInstanceEmission2.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
--Copyright (C) 2023 Ehsan Kamrani
--This file is licensed and distributed under MIT license

--Explanations: https://vanda3d.org/getprefabinstanceemission/

--Name of script is GetPrefabInstanceEmission2.lua

r = 0.0
g = 0.0
b = 0.0

function Init()
r, g, b = GetPrefabInstanceEmission("this")

message = string.format("\nEmission color is : (%.2f, %.2f, %.2f)", r, g, b)
PrintConsole(message)
end

function Update()

end
17 changes: 17 additions & 0 deletions Sample Scripts/APIs/GetPrefabInstanceShininess1.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
--Copyright (C) 2023 Ehsan Kamrani
--This file is licensed and distributed under MIT license

--Explanations: https://vanda3d.org/getprefabinstanceshininess/

value = 0.0

function Init()
value = GetPrefabInstanceShininess("1_VandaEngine17-SamplePack1_wood_pile")

message = string.format("\nShininess is : (%.2f)", value)
PrintConsole(message)
end

function Update()

end
19 changes: 19 additions & 0 deletions Sample Scripts/APIs/GetPrefabInstanceShininess2.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
--Copyright (C) 2023 Ehsan Kamrani
--This file is licensed and distributed under MIT license

--Explanations: https://vanda3d.org/getprefabinstanceshininess/

--Name of script is GetPrefabInstanceShininess2.lua

value = 0.0

function Init()
value = GetPrefabInstanceShininess("this")

message = string.format("\nShininess is : (%.2f)", value)
PrintConsole(message)
end

function Update()

end
19 changes: 19 additions & 0 deletions Sample Scripts/APIs/GetPrefabInstanceSpecular1.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
--Copyright (C) 2023 Ehsan Kamrani
--This file is licensed and distributed under MIT license

--Explanations: https://vanda3d.org/getprefabinstancespecular/

r = 0.0
g = 0.0
b = 0.0

function Init()
r, g, b = GetPrefabInstanceSpecular("1_VandaEngine17-SamplePack1_wood_pile")

message = string.format("\nSpecular color is : (%.2f, %.2f, %.2f)", r, g, b)
PrintConsole(message)
end

function Update()

end
21 changes: 21 additions & 0 deletions Sample Scripts/APIs/GetPrefabInstanceSpecular2.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
--Copyright (C) 2023 Ehsan Kamrani
--This file is licensed and distributed under MIT license

--Explanations: https://vanda3d.org/getprefabinstancespecular/

--Name of script is GetPrefabInstanceSpecular2.lua

r = 0.0
g = 0.0
b = 0.0

function Init()
r, g, b = GetPrefabInstanceSpecular("this")

message = string.format("\nSpecular color is : (%.2f, %.2f, %.2f)", r, g, b)
PrintConsole(message)
end

function Update()

end
17 changes: 17 additions & 0 deletions Sample Scripts/APIs/GetPrefabInstanceTransparency1.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
--Copyright (C) 2023 Ehsan Kamrani
--This file is licensed and distributed under MIT license

--Explanations: https://vanda3d.org/getprefabinstancetransparency/

value = 0.0

function Init()
value = GetPrefabInstanceTransparency("1_VandaEngine17-SamplePack1_wood_pile")

message = string.format("\nTransparency is : (%.2f)", value)
PrintConsole(message)
end

function Update()

end
19 changes: 19 additions & 0 deletions Sample Scripts/APIs/GetPrefabInstanceTransparency2.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
--Copyright (C) 2023 Ehsan Kamrani
--This file is licensed and distributed under MIT license

--Explanations: https://vanda3d.org/getprefabinstancetransparency/

--Name of script is GetPrefabInstanceTransparency2.lua

value = 0.0

function Init()
value = GetPrefabInstanceTransparency("this")

message = string.format("\nTransparency is : (%.2f)", value)
PrintConsole(message)
end

function Update()

end

0 comments on commit 877a5e4

Please sign in to comment.