MS.D->P = MS0;
- MF[MFselectedRow+1].MS = MS;
+ MF[MFselectedRow+1].MS.D = MS.D;
[eventWindow makeKeyAndOrderFront:nil];
-(void)doubleClickEL:(id)sender{
MAPSCRIPT MS = MF[MFselectedRow+1].MS;
-
+ MAPSCRIPTD *mdTop = MS.D;
for (int i = 0;i < eventListRow;i++) {
if(!MS.D->next){
[self didChangeValueForKey:@"eventListMA"];
[eventListAC setSelectionIndex:[eventListMA count]-2];
- MAPSCRIPTD *mdTop = MS.D;
-
if(!MS.D){
MS.D = calloc(1, sizeof(MAPSCRIPTD));
mdTop = MS.D;
[EDnameTF setStringValue:[MS.SCRPTname objectAtIndex:[eventListTV clickedRow]]];
- MF[MFselectedRow+1].MS = MS;
+ MF[MFselectedRow+1].MS.D = MS.D;
[self initEDlist];
[eventDetailWindow makeKeyAndOrderFront:nil];
}
- MF[MFselectedRow+1].MS = MS;
+ MF[MFselectedRow+1].MS.D = mdTop;
EDproceedFlag = true;
}
MAPSCRIPT MS = MF[MFselectedRow+1].MS;
+ MS.D = msdtop;
if([eventDetailListTV clickedRow] >= 0){
[self initEDappear];
//NSLog(@"%d", MS.D->type);
[EDAppearWindow makeKeyAndOrderFront:nil];
+ }if([[MS.D->SCRPT objectAtIndex:EDrow] isEqualToString:@"◆ウェイト"]){
+ editFlag = true;
+ [self initWait];
+ //NSLog(@"%d", MS.D->type);
+ [EDWaitWindow makeKeyAndOrderFront:nil];
}
}
}
- MF[MFselectedRow+1].MS = MS;
+ MF[MFselectedRow+1].MS.D = MS.D;
MS.D = mdTop;
- MF[MFselectedRow+1].MS = MS;
+ MF[MFselectedRow+1].MS.D = MS.D;
NSMutableDictionary* dict = [NSMutableDictionary new];
[dict setValue:[NSString stringWithFormat:@"●"] forKey:@"value"];
[self willChangeValueForKey:@"eventListMA"];
}
MS.D = mdTop;
}
- MF[MFselectedRow+1].MS = MS;
+ MF[MFselectedRow+1].MS.D = MS.D;
MSDTOP = MF[MFselectedRow+1].MS.D;
}
MS.D = mdTop;
- MF[MFselectedRow+1].MS = MS;
+ MF[MFselectedRow+1].MS.D = MS.D;
}
MAPSCRIPTD *mdTop = MS.D;
+ MS.D = msdtop;
if(MS.D)
for(int i = 0;i < [MS.D->SCRPT count];i++){
else
[EDswitch2Btn setState:NO];
MS.D = mdTop;
- MF[MFselectedRow+1].MS = MS;
+ MF[MFselectedRow+1].MS.D = MS.D;
}
MS.D = mdTop;
- MF[MFselectedRow+1].MS = MS;
+ MF[MFselectedRow+1].MS.D = MS.D;
}
[self EDdeleteFunc:MS msd:MSD];
}else if([[MS.D->SCRPT objectAtIndex:EDrow] isEqualToString:@"◆ユニット出現"]){
[self EDdeleteFunc:MS msd:MSD];
+ }else if([[MS.D->SCRPT objectAtIndex:EDrow] isEqualToString:@"◆ウェイト"]){
+ [self EDdeleteFunc:MS msd:MSD];
}
}
MS.D = mdTop;
- MF[MFselectedRow+1].MS = MS;
+ MF[MFselectedRow+1].MS.D = MS.D;
}
}
- MF[MFselectedRow+1].MS = MS;
+ MF[MFselectedRow+1].MS.D = MS.D;
editFlag = false;
insertFlag = false;
}
MS0 = m0Top;
- msdtop->P = MS0;
+ //msdtop->P = MS0;
- msdtop = MSD;
+ //msdtop = MSD;
- MF[MFselectedRow+1].MS.D = MSDTOP;
- *MF[MFselectedRow+1].MS.D = *msdtop;
- *MF[MFselectedRow+1].MS.D->P = *(msdtop->P);
- MF[MFselectedRow+1].MS.D = MSDTOP;
+ //*MF[MFselectedRow+1].MS.D = *msdtop;
+ //*MF[MFselectedRow+1].MS.D->P = *(msdtop->P);
+ MF[MFselectedRow+1].MS.D->P = MS0;
+ MF[MFselectedRow+1].MS.D = msdtop;
editFlag = false;
insertFlag = false;
[EDtextWindow close];
MS0 = m0Top;
- msdtop->P = MS0;
- msdtop = MSD;
+ //msdtop->P = MS0;
+ //msdtop = MSD;
MS.D->P = MS0;
MS.D->P = MSDPt;
+ /*
MF[MFselectedRow+1].MS.D = MSDTOP;
*MF[MFselectedRow+1].MS.D = *msdtop;
*MF[MFselectedRow+1].MS.D->P = *(msdtop->P);
MF[MFselectedRow+1].MS.D = MSDTOP;
+ */
+
+ MF[MFselectedRow+1].MS.D->P = MS0;
+ MF[MFselectedRow+1].MS.D = msdtop;
selectionDBLclickFlag = false;
editFlag = false;
//追加予定
MAPSCRIPT MS = MF[MFselectedRow+1].MS;
-
MS.D = msdtop;
MAPSCRIPTD *MSDt = MS.D;
[self didChangeValueForKey:@"EDswitch2MA"];
}
}
-
-
+ // NSLog(@"%@", MS);
[EDswitchWindow close];
}
MS0 = m0Top;
- msdtop->P = MS0;
- msdtop = MSD;
+ //msdtop->P = MS0;
+ //msdtop = MSD;
MS.D->P = MS0;
MS.D->P = MSDPt;
MS.D->P = MS0;
MS.D->P = MSDPt;
+ /*
MF[MFselectedRow+1].MS.D = MSDTOP;
*MF[MFselectedRow+1].MS.D = *msdtop;
*MF[MFselectedRow+1].MS.D->P = *(msdtop->P);
MF[MFselectedRow+1].MS.D = MSDTOP;
+ */
+
+ MF[MFselectedRow+1].MS.D->P = MS0;
+ MF[MFselectedRow+1].MS.D = msdtop;
labelDBLclickFlag = false;
editFlag = false;
[self didChangeValueForKey:@"eventDetailListMA"];
MS0 = m0Top;
- msdtop->P = MS0;
- msdtop = MSD;
+ //msdtop->P = MS0;
+ //msdtop = MSD;
MS.D->P = MS0;
MS.D->P = MSDPt;
+ /*
MF[MFselectedRow+1].MS.D = MSDTOP;
*MF[MFselectedRow+1].MS.D = *msdtop;
*MF[MFselectedRow+1].MS.D->P = *(msdtop->P);
MF[MFselectedRow+1].MS.D = MSDTOP;
+ */
+
+ MF[MFselectedRow+1].MS.D->P = MS0;
+ MF[MFselectedRow+1].MS.D = msdtop;
labelDBLclickFlag = false;
editFlag = false;
MS0 = m0Top;
- msdtop->P = MS0;
- msdtop = MSD;
+ //msdtop->P = MS0;
+ //msdtop = MSD;
MS.D->P = MS0;
MS.D->P = MSDPt;
MS.D->P = MS0;
MS.D->P = MSDPt;
+ /*
MF[MFselectedRow+1].MS.D = MSDTOP;
*MF[MFselectedRow+1].MS.D = *msdtop;
*MF[MFselectedRow+1].MS.D->P = *(msdtop->P);
MF[MFselectedRow+1].MS.D = MSDTOP;
+ */
+
+ MF[MFselectedRow+1].MS.D->P = MS0;
+ MF[MFselectedRow+1].MS.D = msdtop;
labelDBLclickFlag = false;
editFlag = false;
[self initEDlist];
MS0 = m0Top;
- msdtop->P = MS0;
- msdtop = MSD;
+ //msdtop->P = MS0;
+ //msdtop = MSD;
MS.D->P = MS0;
MS.D->P = MSDPt;
MS.D->P = MS0;
MS.D->P = MSDPt;
+ /*
MF[MFselectedRow+1].MS.D = MSDTOP;
*MF[MFselectedRow+1].MS.D = *msdtop;
*MF[MFselectedRow+1].MS.D->P = *(msdtop->P);
MF[MFselectedRow+1].MS.D = MSDTOP;
+ */
+
+ MF[MFselectedRow+1].MS.D->P = MS0;
+ MF[MFselectedRow+1].MS.D = msdtop;
labelDBLclickFlag = false;
editFlag = false;
-(IBAction)EDdissapear:(id)sender{}
-(IBAction)EDplace:(id)sender{}
--(IBAction)EDwait:(id)sender{}
+-(IBAction)EDwait:(id)sender{
+
+ [EDWaitWindow makeKeyAndOrderFront:nil];
+}
-(IBAction)EDpilot:(id)sender{}
-(IBAction)EDunit:(id)sender{}
-(IBAction)EDbgm:(id)sender{}
}
-
-
- MF[MFselectedRow+1].MS = MS;
+ MF[MFselectedRow+1].MS.D = MS.D;
[MapEditorWindow setFrame:NSMakeRect(scCenter.origin.x,scCenter.origin.y,640,480+headerFrame) display:YES];
MS0 = MSDPt;
- MF[MFselectedRow+1].MS = MS;
+ MF[MFselectedRow+1].MS.D = MS.D;
}
}
}
+-(IBAction)EDwaitSubmit:(id)sender{
+
+ MAPSCRIPT MS = MF[MFselectedRow+1].MS;
+ MS.D = msdtop;
+ MS0T = MS.D->P;
+ MAPSCRIPT0 *MS0 = MS.D->P;
+ MAPSCRIPT0 *MS0T = MS0;
+ if(!MS.D->P) return;
+
+ for(int i = 0;i < squareCnt-1;i++){
+ MS0 = MS0->next;
+ }
+
+
+ MS0->wait = [EDWaitTF doubleValue];
+ MS0->type = 23;
+
+ MS0 = MS0T;
+
+ int cnt = 0;
+ if(editFlag){
+ int instantCnt = 0;
+ int instantCnt2 = 0;
+ for (int i = 0;i < [MS.D->SCRPT count];i++) {
+ NSArray *array = [[MS.D->SCRPT objectAtIndex:i] componentsSeparatedByString:@"◆"];
+ if([array count] >= 2){
+ instantCnt++;
+ }
+
+ if(instantCnt == squareCnt){
+ instantCnt2++;
+ cnt--;
+ }
+ if(instantCnt == squareCnt + 1){
+ break;
+ }
+ cnt++;
+ }
+
+ for(int i = 0;i < instantCnt2;i++){
+
+ [MS.D->SCRPT removeObjectAtIndex:cnt];
+
+ }
+
+ [MS.D->SCRPT insertObject:@"◆ウェイト" atIndex:cnt];
+
+ NSString *string = [NSString stringWithFormat:@"%g秒", MS0->wait];
+
+ [MS.D->SCRPT insertObject:string atIndex:cnt+1];
+
+ }else if(insertFlag){
+ int instantCnt = 0;
+ int instantCnt2 = 0;
+ for (int i = 0;i < [MS.D->SCRPT count];i++) {
+ NSArray *array = [[MS.D->SCRPT objectAtIndex:i] componentsSeparatedByString:@"◆"];
+ if([array count] >= 2){
+ instantCnt++;
+ }
+
+ if(instantCnt == squareCnt){
+ instantCnt2++;
+ cnt--;
+ }
+ if(instantCnt == squareCnt + 1){
+ break;
+ }
+ cnt++;
+ }
+
+ [MS.D->SCRPT insertObject:@"◆ウェイト" atIndex:cnt];
+
+ NSString *string = [NSString stringWithFormat:@"%g秒", MS0->wait];
+
+ [MS.D->SCRPT insertObject:string atIndex:cnt+1];
+
+
+ }else{
+ [MS.D->SCRPT addObject:@"◆ウェイト"];
+
+ NSString *string = [NSString stringWithFormat:@"%g秒", MS0->wait];
+
+ [MS.D->SCRPT addObject:string];
+
+
+ }
+
+
+ MS.D->P = MS0;
+
+ MF[MFselectedRow+1].MS.D = MS.D;
+
+ [EDWaitWindow close];
+ [eventDetailSelectionWindow close];
+}
+
+-(void)initWait{
+
+
+ MAPSCRIPT MS = MF[MFselectedRow+1].MS;
+ MS.D = msdtop;
+ MS0T = MS.D->P;
+ MAPSCRIPT0 *MS0 = MS.D->P;
+ MAPSCRIPT0 *MS0T = MS0;
+ if(!MS.D->P) return;
+
+ for(int i = 0;i < squareCnt-1;i++){
+ MS0 = MS0->next;
+ }
+
+ [EDWaitTF setStringValue:[NSString stringWithFormat:@"%g", MS0->wait]];
+ MS0 = MS0T;
+
+}
+
+
+-(IBAction)EDwaitClost:(id)sender{
+
+ [EDWaitWindow close];
+
+}
<outlet property="EDTimerSet3B" destination="veb-h0-8PW" id="3aU-a4-Rid"/>
<outlet property="EDTimerTF1" destination="NcS-6r-bj5" id="Wp9-W1-j1f"/>
<outlet property="EDTimerTF2" destination="gmG-4C-wSf" id="DVd-oK-1EK"/>
+ <outlet property="EDWaitTF" destination="wei-np-Col" id="UFg-Gj-qsP"/>
+ <outlet property="EDWaitWindow" destination="PKC-k4-dLW" id="N9v-bG-TG0"/>
<outlet property="EDhp1AC" destination="fEW-Dh-30u" id="yTW-ra-ZxX"/>
<outlet property="EDhp1TV" destination="Xwe-1P-CYg" id="Erx-4l-IiR"/>
<outlet property="EDhp2AC" destination="3IQ-ze-3zY" id="lwS-FX-wEM"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<tableView verticalHuggingPriority="750" allowsExpansionToolTips="YES" columnAutoresizingStyle="none" columnReordering="NO" columnSelection="YES" columnResizing="NO" multipleSelection="NO" autosaveColumns="NO" headerView="14194" id="14196">
- <rect key="frame" x="0.0" y="0.0" width="199" height="19"/>
+ <rect key="frame" x="0.0" y="0.0" width="199" height="82"/>
<autoresizingMask key="autoresizingMask"/>
<size key="intercellSpacing" width="3" height="2"/>
<color key="backgroundColor" name="controlBackgroundColor" catalog="System" colorSpace="catalog"/>
<window title="Window" allowsToolTipsWhenApplicationIsInactive="NO" autorecalculatesKeyViewLoop="NO" oneShot="NO" releasedWhenClosed="NO" showsToolbarButton="NO" visibleAtLaunch="NO" animationBehavior="default" id="d50-mX-eQ4" userLabel="入力ウィンドウ">
<windowStyleMask key="styleMask" titled="YES"/>
<rect key="contentRect" x="196" y="207" width="300" height="150"/>
- <rect key="screenRect" x="0.0" y="0.0" width="1920" height="1058"/>
+ <rect key="screenRect" x="0.0" y="0.0" width="1920" height="1057"/>
<view key="contentView" id="AFo-1U-ck0">
<rect key="frame" x="0.0" y="0.0" width="300" height="150"/>
<autoresizingMask key="autoresizingMask"/>
</button>
</subviews>
</view>
- <point key="canvasLocation" x="1125" y="1917"/>
+ <point key="canvasLocation" x="1210" y="1863"/>
</window>
<window title="Window" allowsToolTipsWhenApplicationIsInactive="NO" autorecalculatesKeyViewLoop="NO" oneShot="NO" releasedWhenClosed="NO" showsToolbarButton="NO" visibleAtLaunch="NO" animationBehavior="default" id="Mpe-WF-JbB" userLabel="選択肢ウィンドウ">
<rect key="contentRect" x="196" y="207" width="400" height="300"/>
</view>
<point key="canvasLocation" x="3345.5" y="2637.5"/>
</window>
+ <window allowsToolTipsWhenApplicationIsInactive="NO" autorecalculatesKeyViewLoop="NO" oneShot="NO" releasedWhenClosed="NO" showsToolbarButton="NO" visibleAtLaunch="NO" animationBehavior="default" id="PKC-k4-dLW" userLabel="ウェイト時間">
+ <windowStyleMask key="styleMask" titled="YES"/>
+ <rect key="contentRect" x="196" y="207" width="300" height="150"/>
+ <rect key="screenRect" x="0.0" y="0.0" width="1920" height="1057"/>
+ <view key="contentView" id="BbH-hY-xnu">
+ <rect key="frame" x="0.0" y="0.0" width="300" height="150"/>
+ <autoresizingMask key="autoresizingMask"/>
+ <subviews>
+ <textField verticalHuggingPriority="750" id="wei-np-Col">
+ <rect key="frame" x="93" y="74" width="50" height="22"/>
+ <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
+ <textFieldCell key="cell" scrollable="YES" lineBreakMode="clipping" selectable="YES" editable="YES" sendsActionOnEndEditing="YES" state="on" borderStyle="bezel" drawsBackground="YES" id="flZ-hZ-ZYV">
+ <font key="font" metaFont="system"/>
+ <color key="textColor" name="textColor" catalog="System" colorSpace="catalog"/>
+ <color key="backgroundColor" name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
+ </textFieldCell>
+ </textField>
+ <textField horizontalHuggingPriority="251" verticalHuggingPriority="750" id="vDE-0D-0dp">
+ <rect key="frame" x="23" y="113" width="199" height="17"/>
+ <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
+ <textFieldCell key="cell" scrollable="YES" lineBreakMode="clipping" sendsActionOnEndEditing="YES" title="ウェイト時間決定(小数点も可)" id="Yli-LZ-qwe">
+ <font key="font" size="13" name="HiraKakuProN-W3"/>
+ <color key="textColor" name="labelColor" catalog="System" colorSpace="catalog"/>
+ <color key="backgroundColor" name="controlColor" catalog="System" colorSpace="catalog"/>
+ </textFieldCell>
+ </textField>
+ <textField horizontalHuggingPriority="251" verticalHuggingPriority="750" id="JeB-4v-HC9">
+ <rect key="frame" x="149" y="77" width="17" height="17"/>
+ <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
+ <textFieldCell key="cell" scrollable="YES" lineBreakMode="clipping" sendsActionOnEndEditing="YES" title="秒" id="WfC-3M-AJq">
+ <font key="font" size="13" name="HiraKakuProN-W3"/>
+ <color key="textColor" name="labelColor" catalog="System" colorSpace="catalog"/>
+ <color key="backgroundColor" name="controlColor" catalog="System" colorSpace="catalog"/>
+ </textFieldCell>
+ </textField>
+ <button verticalHuggingPriority="750" id="Dba-bb-jCM">
+ <rect key="frame" x="192" y="13" width="105" height="32"/>
+ <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
+ <buttonCell key="cell" type="push" title="キャンセル" bezelStyle="rounded" alignment="center" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="rPy-yD-f32">
+ <behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
+ <font key="font" size="13" name="AquaKana"/>
+ </buttonCell>
+ <connections>
+ <action selector="EDwaitClost:" target="3826" id="900-YS-9bX"/>
+ </connections>
+ </button>
+ <button verticalHuggingPriority="750" id="cLD-C5-P9t">
+ <rect key="frame" x="126" y="13" width="66" height="32"/>
+ <autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMinY="YES"/>
+ <buttonCell key="cell" type="push" title="決定" bezelStyle="rounded" alignment="center" borderStyle="border" imageScaling="proportionallyDown" inset="2" id="KcA-tJ-M4Y">
+ <behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
+ <font key="font" size="13" name="AquaKana"/>
+ </buttonCell>
+ <connections>
+ <action selector="EDwaitSubmit:" target="3826" id="2lW-7T-rVT"/>
+ </connections>
+ </button>
+ </subviews>
+ </view>
+ <point key="canvasLocation" x="962" y="2518"/>
+ </window>
</objects>
<resources>
<image name="BackGround" width="32" height="32"/>