File tree 3 files changed +70
-0
lines changed
3 files changed +70
-0
lines changed Original file line number Diff line number Diff line change
1
+
2
+ Microsoft Visual Studio Solution File, Format Version 12.00
3
+ # Visual Studio Version 17
4
+ VisualStudioVersion = 17.2.32516.85
5
+ MinimumVisualStudioVersion = 10.0.40219.1
6
+ Project ("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}" ) = "PMTG" , "PMTG\PMTG.csproj" , "{D05961F5-C9C9-4EAB-8ADD-5DA484BFF792}"
7
+ EndProject
8
+ Global
9
+ GlobalSection (SolutionConfigurationPlatforms ) = preSolution
10
+ Debug| Any CPU = Debug| Any CPU
11
+ Release| Any CPU = Release| Any CPU
12
+ EndGlobalSection
13
+ GlobalSection (ProjectConfigurationPlatforms ) = postSolution
14
+ {D05961F5-C9C9-4EAB-8ADD-5DA484BFF792} .Debug| Any CPU .ActiveCfg = Debug| Any CPU
15
+ {D05961F5-C9C9-4EAB-8ADD-5DA484BFF792} .Debug| Any CPU .Build .0 = Debug| Any CPU
16
+ {D05961F5-C9C9-4EAB-8ADD-5DA484BFF792} .Release| Any CPU .ActiveCfg = Release| Any CPU
17
+ {D05961F5-C9C9-4EAB-8ADD-5DA484BFF792} .Release| Any CPU .Build .0 = Release| Any CPU
18
+ EndGlobalSection
19
+ GlobalSection (SolutionProperties ) = preSolution
20
+ HideSolutionNode = FALSE
21
+ EndGlobalSection
22
+ GlobalSection (ExtensibilityGlobals ) = postSolution
23
+ SolutionGuid = {5893A42D-E67E-425B-8D2E-DC8C661CA953}
24
+ EndGlobalSection
25
+ EndGlobal
Original file line number Diff line number Diff line change
1
+ <Project Sdk =" Microsoft.NET.Sdk" >
2
+
3
+ <PropertyGroup >
4
+ <OutputType >Exe</OutputType >
5
+ <TargetFramework >net6.0</TargetFramework >
6
+ <ImplicitUsings >enable</ImplicitUsings >
7
+ <Nullable >enable</Nullable >
8
+ </PropertyGroup >
9
+
10
+ </Project >
Original file line number Diff line number Diff line change
1
+ Console . Write ( "What do you want the plugin to be named?: " ) ;
2
+ string ? name = Console . ReadLine ( ) ;
3
+ if ( name == null || name == "" ) name = "PluginName" ;
4
+
5
+ Console . Write ( "Who is gonna be the author of this plugin?: " ) ;
6
+ string ? author = Console . ReadLine ( ) ;
7
+ if ( author == null || author == "" ) author = "AuthorName" ;
8
+
9
+ Console . Write ( "What is the main class/file gonna be called?: " ) ;
10
+ string ? main = Console . ReadLine ( ) ;
11
+ if ( main == null || main == "" )
12
+ {
13
+ main = "Main" ;
14
+ }
15
+
16
+ Console . Write ( "Where do you want the files and folders to be outputed?: " ) ;
17
+ string ? path = Console . ReadLine ( ) ;
18
+ if ( ! Directory . Exists ( path ) )
19
+ {
20
+ Console . WriteLine ( "Directory given does not exist or is wrong" ) ;
21
+ Console . ReadKey ( ) ;
22
+ return ;
23
+ }
24
+ else
25
+ {
26
+ string yamltext = "name: " + name + "\n author: " + author + "\n version: 0.0.1\n api: 4.0.0\n main: " + author + @"\" + name + @"\" + main ;
27
+ path = path + @"\" + name ;
28
+ Directory . CreateDirectory ( path ) ;
29
+ File . WriteAllText ( path + @"\plugin.yml" , yamltext ) ;
30
+
31
+ string maintext = "<?php\n \n namespace " + author + @"\" + name + ";\n \n " + @"use pocketmine\plugin\PluginBase;" + "\n \n class " + main + " extends PluginBase {\n \n public function onEnable():void\n {\n \n }\n \n public function onDisable():void\n {\n \n }\n }" ;
32
+ path = path + @"\src\" + author + @"\" + name + @"\" ;
33
+ Directory . CreateDirectory ( path ) ;
34
+ File . WriteAllText ( path + main + ".php" , maintext ) ;
35
+ }
You can’t perform that action at this time.
0 commit comments